37{
38 for (auto& thisOrder : sortOrder)
39 {
40 switch (thisOrder.sortOrder)
41 {
43 {
44 if (left->
bid == right->
bid)
45 {
46 if (checkMinBidBuyout)
47 {
49 {
51 {
52 continue;
53 }
54
56 }
57
59 }
60
61 continue;
62 }
63
64 return thisOrder.isDesc ? left->
bid > right->
bid : left->
bid < right->
bid;
65 }
68 {
70 {
71 continue;
72 }
73
75 }
77 {
80 if (!protoLeft || !protoRight)
81 {
82 continue;
83 }
84
85 std::string leftName = protoLeft->
Name1;
86 std::string rightName = protoRight->
Name1;
87 if (leftName.empty() || rightName.empty())
88 {
89 continue;
90 }
91
94 {
96 }
97
99 {
101 {
103 }
104
106 {
108 }
109 }
110
111 int result = leftName.compare(rightName);
112 if (result == 0)
113 {
114 continue;
115 }
116
117 return thisOrder.isDesc ? result > 0 : result < 0;
118 }
120 {
123 if (!protoLeft || !protoRight)
124 {
125 continue;
126 }
127
129 {
130 continue;
131 }
132
134 }
136 {
137 std::string leftName;
139
140 std::string rightName;
142
143 int result = leftName.compare(rightName);
144 if (result == 0)
145 {
146 continue;
147 }
148
149 return thisOrder.isDesc ? result > 0 : result < 0;
150 }
152 {
155 if (!protoLeft || !protoRight)
156 {
157 continue;
158 }
159
161 {
162 continue;
163 }
164
166 }
168 {
170 {
171 continue;
172 }
173
174 if (!thisOrder.isDesc)
175 {
177 }
178
180 }
182 {
184 {
185 continue;
186 }
187
189 }
191 {
193 {
195 {
196 continue;
197 }
198
200 }
201
203 }
205
207 default:
208 break;
209 }
210 }
211
212 return false;
213}
LocaleConstant
Definition: Common.h:65
@ LOCALE_enUS
Definition: Common.h:66
#define sObjectMgr
Definition: ObjectMgr.h:1635
@ AUCTION_SORT_TIMELEFT
Definition: AuctionHouseMgr.h:78
@ AUCTION_SORT_BID
Definition: AuctionHouseMgr.h:83
@ AUCTION_SORT_BUYOUT
Definition: AuctionHouseMgr.h:77
@ AUCTION_SORT_MINLEVEL
Definition: AuctionHouseMgr.h:75
@ AUCTION_SORT_UNK4
Definition: AuctionHouseMgr.h:79
@ AUCTION_SORT_MAX
Definition: AuctionHouseMgr.h:87
@ AUCTION_SORT_MINBIDBUY
Definition: AuctionHouseMgr.h:81
@ AUCTION_SORT_OWNER
Definition: AuctionHouseMgr.h:82
@ AUCTION_SORT_ITEM
Definition: AuctionHouseMgr.h:80
@ AUCTION_SORT_STACK
Definition: AuctionHouseMgr.h:84
@ AUCTION_SORT_RARITY
Definition: AuctionHouseMgr.h:76
@ AUCTION_SORT_BUYOUT_2
Definition: AuctionHouseMgr.h:85
#define sCharacterCache
Definition: CharacterCache.h:83
uint32 bid
Definition: AuctionHouseMgr.h:109
time_t expire_time
Definition: AuctionHouseMgr.h:111
uint32 startbid
Definition: AuctionHouseMgr.h:108
uint32 itemCount
Definition: AuctionHouseMgr.h:106
uint32 buyout
Definition: AuctionHouseMgr.h:110
uint32 item_template
Definition: AuctionHouseMgr.h:105
ObjectGuid owner
Definition: AuctionHouseMgr.h:107
Definition: ItemTemplate.h:619
uint32 Quality
Definition: ItemTemplate.h:626
uint32 RequiredLevel
Definition: ItemTemplate.h:636
std::string Name1
Definition: ItemTemplate.h:624
uint32 ItemId
Definition: ItemTemplate.h:620
Definition: ItemTemplate.h:838
WorldSession * GetSession() const
Definition: Player.h:1998
static std::string_view GetLocaleString(std::vector< std::string > const &data, std::size_t locale)
Definition: ObjectMgr.h:1407
LocaleConstant GetSessionDbLocaleIndex() const
Definition: WorldSession.h:498