diff options
| author | Spp- <u84280@epreinf21.(none)> | 2011-07-29 14:18:28 +0200 |
|---|---|---|
| committer | Spp- <u84280@epreinf21.(none)> | 2011-07-29 14:18:28 +0200 |
| commit | e47b96af3e3a41eae71e3e3da7eeee8bd3de86bc (patch) | |
| tree | 07d5ff1e6e39d792dbe1a89cc373c06702817787 /src/server/game/AuctionHouse/AuctionHouseMgr.cpp | |
| parent | 06b46ba203d30cc5e2abc9741b2fc737ebdd7c38 (diff) | |
Core: Append single character to stream as character, not as a string
Diffstat (limited to 'src/server/game/AuctionHouse/AuctionHouseMgr.cpp')
| -rw-r--r-- | src/server/game/AuctionHouse/AuctionHouseMgr.cpp | 28 |
1 files changed, 10 insertions, 18 deletions
diff --git a/src/server/game/AuctionHouse/AuctionHouseMgr.cpp b/src/server/game/AuctionHouse/AuctionHouseMgr.cpp index 26a6ced5cf0..44392e6b3b2 100644 --- a/src/server/game/AuctionHouse/AuctionHouseMgr.cpp +++ b/src/server/game/AuctionHouse/AuctionHouseMgr.cpp @@ -140,7 +140,7 @@ void AuctionHouseMgr::SendAuctionWonMail(AuctionEntry *auction, SQLTransaction& std::ostringstream msgAuctionWonBody; msgAuctionWonBody.width(16); msgAuctionWonBody << std::right << std::hex << auction->owner; - msgAuctionWonBody << std::dec << ":" << auction->bid << ":" << auction->buyout; + msgAuctionWonBody << std::dec << ':' << auction->bid << ':' << auction->buyout; sLog->outDebug(LOG_FILTER_AUCTIONHOUSE, "AuctionWon body string : %s", msgAuctionWonBody.str().c_str()); // set owner to bidder (to prevent delete item with sender char deleting) @@ -181,8 +181,8 @@ void AuctionHouseMgr::SendAuctionSalePendingMail(AuctionEntry * auction, SQLTran msgAuctionSalePendingBody.width(16); msgAuctionSalePendingBody << std::right << std::hex << auction->bidder; - msgAuctionSalePendingBody << std::dec << ":" << auction->bid << ":" << auction->buyout; - msgAuctionSalePendingBody << ":" << auction->deposit << ":" << auctionCut << ":0:"; + msgAuctionSalePendingBody << std::dec << ':' << auction->bid << ':' << auction->buyout; + msgAuctionSalePendingBody << ':' << auction->deposit << ':' << auctionCut << ":0:"; msgAuctionSalePendingBody << secsToTimeBitFields(distrTime); sLog->outDebug(LOG_FILTER_AUCTIONHOUSE, "AuctionSalePending body string : %s", msgAuctionSalePendingBody.str().c_str()); @@ -209,8 +209,8 @@ void AuctionHouseMgr::SendAuctionSuccessfulMail(AuctionEntry * auction, SQLTrans auctionSuccessfulBody.width(16); auctionSuccessfulBody << std::right << std::hex << auction->bidder; - auctionSuccessfulBody << std::dec << ":" << auction->bid << ":" << auction->buyout; - auctionSuccessfulBody << ":" << auction->deposit << ":" << auctionCut; + auctionSuccessfulBody << std::dec << ':' << auction->bid << ':' << auction->buyout; + auctionSuccessfulBody << ':' << auction->deposit << ':' << auctionCut; sLog->outDebug(LOG_FILTER_AUCTIONHOUSE, "AuctionSuccessful body string : %s", auctionSuccessfulBody.str().c_str()); @@ -624,18 +624,10 @@ void AuctionHouseObject::BuildListAuctionItems(WorldPacket& data, Player* player // dbc local name if (temp) { - if (locdbc_idx >= 0) - { - // Append the suffix (ie: of the Monkey) to the name using localization - name += " "; - name += temp[locdbc_idx]; - } - else - { - // Invalid localization? Append the suffix using default enUS - name += " "; - name += temp[LOCALE_enUS]; - } + // Append the suffix (ie: of the Monkey) to the name using localization + // or default enUS if localization is invalid + name += ' '; + name += temp[locdbc_idx >= 0 ? locdbc_idx : LOCALE_enUS]; } } } @@ -885,4 +877,4 @@ bool AuctionEntry::LoadFromFieldList(Field* fields) } return true; -}
\ No newline at end of file +} |
