Advertisement
stoneharry

Untitled

Apr 11th, 2014
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.50 KB | None | 0 0
  1. // Send: GAMES-icon-gamename...
  2. std::stringstream str;
  3.  
  4. str << "GAMES";
  5.  
  6. // Oh god this code
  7. for (std::map<uint32, Battleground*>::iterator iterator =
  8.     sBattlegroundMgr->bgDataStore[BATTLEGROUND_HG_1].m_Battlegrounds.begin();
  9.     iterator != sBattlegroundMgr->bgDataStore[BATTLEGROUND_HG_1].m_Battlegrounds.end();
  10.     iterator++)
  11. {
  12.     HG_Game* temp = (HG_Game*)iterator->second;
  13.     str << (temp->HasGameStarted() ? "-2-" : "-1");
  14.     str << temp->GetGameName();
  15. }
  16.  
  17. SendAddonMessage(sender, str.str().c_str());
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement