Guest User

Fakoykas

a guest
Jul 21st, 2010
265
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.17 KB | None | 0 0
  1. Index: I:/workspace/L2_GameServer/java/com/l2jserver/gameserver/network/clientpackets/UseItem.java
  2. ===================================================================
  3. --- I:/workspace/L2_GameServer/java/com/l2jserver/gameserver/network/clientpackets/UseItem.java (revision 4167)
  4. +++ I:/workspace/L2_GameServer/java/com/l2jserver/gameserver/network/clientpackets/UseItem.java (working copy)
  5. @@ -97,6 +97,14 @@
  6.  
  7. if (activeChar.getActiveTradeList() != null)
  8. activeChar.cancelActiveTrade();
  9. +
  10. + int weaponGrade = activeChar.getActiveWeaponItem().getCrystalType();
  11. + int armorGrade = activeChar.getActiveChestArmorItem().getCrystalType();
  12. + if (activeChar.isInOlympiadMode() && (weaponGrade == L2Item.CRYSTAL_S || armorGrade == L2Item.CRYSTAL_S))
  13. + {
  14. + activeChar.sendMessage("You cannot use S grade equipment at the Grand Olympiad games.");
  15. + return;
  16. + }
  17.  
  18. // NOTE: disabled due to deadlocks
  19. // synchronized (activeChar.getInventory())
  20. Index: I:/workspace/L2_GameServer/java/com/l2jserver/gameserver/model/olympiad/Olympiad.java
  21. ===================================================================
  22. --- I:/workspace/L2_GameServer/java/com/l2jserver/gameserver/model/olympiad/Olympiad.java (revision 4167)
  23. +++ I:/workspace/L2_GameServer/java/com/l2jserver/gameserver/model/olympiad/Olympiad.java (working copy)
  24. @@ -50,6 +50,7 @@
  25. import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
  26. import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
  27. import com.l2jserver.gameserver.templates.StatsSet;
  28. +import com.l2jserver.gameserver.templates.item.L2Item;
  29. import com.l2jserver.util.L2FastList;
  30.  
  31. import javolution.util.FastMap;
  32. @@ -482,6 +483,14 @@
  33. * return false; }
  34. */
  35.  
  36. + int weaponGrade = noble.getActiveWeaponItem().getCrystalType();
  37. + int armorGrade = noble.getActiveChestArmorItem().getCrystalType();
  38. + if (weaponGrade == L2Item.CRYSTAL_S || armorGrade == L2Item.CRYSTAL_S)
  39. + {
  40. + noble.sendMessage("You cannot join the grand olympiad games using S grade equipment.");
  41. + return false;
  42. + }
  43. +
  44. if (!_inCompPeriod)
  45. {
  46. sm = new SystemMessage(SystemMessageId.THE_OLYMPIAD_GAME_IS_NOT_CURRENTLY_IN_PROGRESS);
Advertisement
Add Comment
Please, Sign In to add comment