kusanagy

Limit of Gold

May 23rd, 2017
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 0.74 KB | None | 0 0
  1. First of all go in Player.cpp and search for this
  2.  
  3.  
  4. -if (GetMoney() < MAX_MONEY_AMOUNT - static_cast<uint32>(amount))
  5. -            SetMoney(GetMoney() + amount);
  6. -        else
  7. -        {
  8. -            if (sendError)
  9. -                SendEquipError(EQUIP_ERR_TOO_MUCH_GOLD, NULL, NULL);
  10. -            return false;
  11. -        }
  12.  
  13.  
  14.  
  15.        
  16. and replace it with this one
  17.  
  18.  
  19.  
  20.  
  21. +if (GetMoney() < MAX_MONEY_AMOUNT - static_cast<uint32>(amount))
  22. +            SetMoney(GetMoney() + amount);
  23. +        else
  24. +        {
  25. +            if (sendError)
  26. +{
  27. +AddItem(60156, 4);
  28. +SetMoney(0);
  29. +GetSession()->SendNotification("You have reached gold limit you have been rewarded with 4 |cFFFFCC00Gold Bars|r!");
  30. +   }
  31. +            return false;
  32. +        }
Advertisement
Add Comment
Please, Sign In to add comment