Guest User

Untitled

a guest
Aug 10th, 2011
175
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ### Eclipse Workspace Patch 1.0
  2. #P aCis_gameserver
  3. Index: java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java
  4. ===================================================================
  5. --- java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java (revision 173)
  6. +++ java/net/sf/l2j/gameserver/network/clientpackets/EnterWorld.java (working copy)
  7. @@ -27,6 +27,7 @@
  8. import net.sf.l2j.gameserver.datatables.AdminCommandAccessRights;
  9. import net.sf.l2j.gameserver.datatables.MapRegionTable;
  10. import net.sf.l2j.gameserver.datatables.SkillTable;
  11. +import net.sf.l2j.gameserver.instancemanager.CastleManager;
  12. import net.sf.l2j.gameserver.instancemanager.ClanHallManager;
  13. import net.sf.l2j.gameserver.instancemanager.CoupleManager;
  14. import net.sf.l2j.gameserver.instancemanager.DimensionalRiftManager;
  15. @@ -38,6 +39,7 @@
  16. import net.sf.l2j.gameserver.model.L2World;
  17. import net.sf.l2j.gameserver.model.actor.L2Character;
  18. import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
  19. +import net.sf.l2j.gameserver.model.entity.Castle;
  20. import net.sf.l2j.gameserver.model.entity.ClanHall;
  21. import net.sf.l2j.gameserver.model.entity.Couple;
  22. import net.sf.l2j.gameserver.model.entity.Siege;
  23. @@ -223,6 +225,11 @@
  24. if (serverNews != null)
  25. sendPacket(new NpcHtmlMessage(1, serverNews));
  26. }
  27. +
  28. + if (Config.ANNOUNCE_CASTLE_LORDS)
  29. + {
  30. + notifyCastleOwner(activeChar);
  31. + }
  32.  
  33. PetitionManager.getInstance().checkPetitionMessages(activeChar);
  34.  
  35. @@ -321,4 +328,18 @@
  36. {
  37. return "[C] 03 EnterWorld";
  38. }
  39. + private void notifyCastleOwner(L2PcInstance activeChar)
  40. + {
  41. + L2Clan clan = activeChar.getClan();
  42. +
  43. + if (clan != null)
  44. + {
  45. + if (clan.getHasCastle() > 0)
  46. + {
  47. + Castle castle = CastleManager.getInstance().getCastleById(clan.getHasCastle());
  48. + if ((castle != null) && (activeChar.getObjectId() == clan.getLeaderId()))
  49. + Announcements.getInstance().announceToAll("Lord " + activeChar.getName() + " Of " + castle.getName() + " Castle is now online!");
  50. + }
  51. + }
  52. + }
  53. }
  54. \ No newline at end of file
  55. Index: java/net/sf/l2j/Config.java
  56. ===================================================================
  57. --- java/net/sf/l2j/Config.java (revision 173)
  58. +++ java/net/sf/l2j/Config.java (working copy)
  59. @@ -80,6 +80,7 @@
  60. public static boolean ALT_GAME_NEW_CHAR_ALWAYS_IS_NEWBIE;
  61. public static boolean ALT_MEMBERS_CAN_WITHDRAW_FROM_CLANWH;
  62. public static boolean REMOVE_CASTLE_CIRCLETS;
  63. + public static boolean ANNOUNCE_CASTLE_LORDS;
  64.  
  65. /** Manor */
  66. public static int ALT_MANOR_REFRESH_TIME;
  67. @@ -717,6 +718,7 @@
  68. ALT_GAME_NEW_CHAR_ALWAYS_IS_NEWBIE = Boolean.parseBoolean(clans.getProperty("AltNewCharAlwaysIsNewbie", "False"));
  69. ALT_MEMBERS_CAN_WITHDRAW_FROM_CLANWH = Boolean.parseBoolean(clans.getProperty("AltMembersCanWithdrawFromClanWH", "False"));
  70. REMOVE_CASTLE_CIRCLETS = Boolean.parseBoolean(clans.getProperty("RemoveCastleCirclets", "True"));
  71. + ANNOUNCE_CASTLE_LORDS = Boolean.parseBoolean(clans.getProperty("AnnounceCastleLords", "false"));
  72.  
  73. ALT_MANOR_REFRESH_TIME = Integer.parseInt(clans.getProperty("AltManorRefreshTime", "20"));
  74. ALT_MANOR_REFRESH_MIN = Integer.parseInt(clans.getProperty("AltManorRefreshMin", "00"));
  75. Index: config/clans.properties
  76. ===================================================================
  77. --- config/clans.properties (revision 173)
  78. +++ config/clans.properties (working copy)
  79. @@ -37,6 +37,9 @@
  80. #Remove Castle circlets after a clan lose its castle or a player leaves a clan? - default true
  81. RemoveCastleCirclets = True
  82.  
  83. +# Announce castle lords on enter game? - default false
  84. +AnnounceCastleLords = False
  85. +
  86. #=============================================================
  87. # Manor Config
  88. #=============================================================
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×