Advertisement
tensador125

autofarm title aura red l2jmega

Oct 29th, 2023 (edited)
1,256
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 4.65 KB | Gaming | 0 0
  1. ### Eclipse Workspace Patch 1.0
  2. #P L2jMega_Interlude
  3. diff --git java/com/l2jmega/Config.java java/com/l2jmega/Config.java
  4. index 973b099..2e5b4aa 100644
  5. --- java/com/l2jmega/Config.java
  6. +++ java/com/l2jmega/Config.java
  7. @@ -202,7 +202,8 @@
  8.     public static double SKILLS_MIN_CHANCE;
  9.    
  10.     public static boolean ENABLE_AIO_SYSTEM;
  11. -   public static String AIO_TITLE;
  12. +   public static String AIO_TITLE;
  13. +   public static String AUTO_FARM_TITLE;
  14.     public static boolean CHANGE_AIO_NAME;
  15.     public static Map<Integer, Integer> AIO_SKILLS;
  16.     public static boolean ALLOW_AIO_NCOLOR;  
  17. @@ -4273,6 +4274,7 @@
  18.         CMD_SKIN = Boolean.parseBoolean(l2jmega.getProperty("EnableSkinCMD", "True"));
  19.         ENABLE_AIO_SYSTEM = Boolean.parseBoolean(l2jmega.getProperty("EnableAioSystem", "True"));
  20.         AIO_TITLE = l2jmega.getProperty("AioTitle", "Aio");
  21. +       AUTO_FARM_TITLE = l2jmega.getProperty("AutoFarmTitle", "[Auto Farm]");
  22.         CHANGE_AIO_NAME = Boolean.parseBoolean(l2jmega.getProperty("ChangeAioName", "True"));
  23.         ALLOW_AIO_NCOLOR = Boolean.parseBoolean(l2jmega.getProperty("AllowAioNameColor", "True"));
  24.         AIO_NCOLOR = Integer.decode("0x" + l2jmega.getProperty("AioNameColor", "88AA88")).intValue();
  25. diff --git java/com/l2jmega/gameserver/handler/voicedcommandhandlers/VoicedAutoFarm.java java/com/l2jmega/gameserver/handler/voicedcommandhandlers/VoicedAutoFarm.java
  26. index a2c1c4a..7663194 100644
  27. --- java/com/l2jmega/gameserver/handler/voicedcommandhandlers/VoicedAutoFarm.java
  28. +++ java/com/l2jmega/gameserver/handler/voicedcommandhandlers/VoicedAutoFarm.java
  29. @@ -183,11 +184,15 @@
  30.             {
  31.                 bot.stop();
  32.                 activeChar.setAutoFarm(false);
  33. +               activeChar.broadcastUserInfo();
  34. +               activeChar.broadcastCharInfo();
  35.             }
  36.             else
  37.             {
  38.                 bot.start();
  39.                 activeChar.setAutoFarm(true);
  40. +               activeChar.broadcastUserInfo();
  41. +               activeChar.broadcastCharInfo();        
  42.             }
  43.  
  44.             showAutoFarm(activeChar);
  45. diff --git java/com/l2jmega/gameserver/network/clientpackets/RequestBypassToServer.java java/com/l2jmega/gameserver/network/clientpackets/RequestBypassToServer.java
  46. index 9564401..47c8af5 100644
  47. --- java/com/l2jmega/gameserver/network/clientpackets/RequestBypassToServer.java
  48. +++ java/com/l2jmega/gameserver/network/clientpackets/RequestBypassToServer.java
  49. @@ -129,11 +129,15 @@
  50.                 {
  51.                     bot.stop();
  52.                     activeChar.setAutoFarm(false);
  53. +                   activeChar.broadcastUserInfo();
  54. +                   activeChar.broadcastCharInfo();
  55.                 }
  56.                 else
  57.                 {
  58.                     bot.start();
  59.                     activeChar.setAutoFarm(true);
  60. +                   activeChar.broadcastUserInfo();
  61. +                   activeChar.broadcastCharInfo();
  62.                 }
  63.                
  64.             }
  65. diff --git java/com/l2jmega/gameserver/network/serverpackets/CharInfo.java java/com/l2jmega/gameserver/network/serverpackets/CharInfo.java
  66. index 6405dca..9e34c21 100644
  67. --- java/com/l2jmega/gameserver/network/serverpackets/CharInfo.java
  68. +++ java/com/l2jmega/gameserver/network/serverpackets/CharInfo.java
  69. @@ -232,6 +232,8 @@
  70.             writeS("");
  71.         else if(AioManager.getInstance().hasAioPrivileges(this._activeChar.getObjectId()) || _activeChar.isAio())
  72.             writeS(Config.AIO_TITLE);
  73. +       else if(_activeChar.isAutoFarm())
  74. +           writeS(Config.AUTO_FARM_TITLE);
  75.         else
  76.             writeS(_activeChar.getTitle());
  77.        
  78. @@ -300,7 +302,9 @@
  79.         if (_activeChar.getTeam() == 1 || _activeChar.getTeamTour() == 1)
  80.             writeC(0x01); // team circle around feet 1= Blue, 2 = red
  81.         else if (_activeChar.getTeam() == 2 || _activeChar.getTeamTour() == 2)
  82. -           writeC(0x02); // team circle around feet 1= Blue, 2 = red
  83. +           writeC(0x02);
  84. +       else if(_activeChar.isAutoFarm())
  85. +           writeC(0x02);
  86.         else
  87.             writeC(0x00); // team circle around feet 1= Blue, 2 = red
  88.        
  89. diff --git java/com/l2jmega/gameserver/network/serverpackets/UserInfo.java java/com/l2jmega/gameserver/network/serverpackets/UserInfo.java
  90. index 919712c..96e1b72 100644
  91. --- java/com/l2jmega/gameserver/network/serverpackets/UserInfo.java
  92. +++ java/com/l2jmega/gameserver/network/serverpackets/UserInfo.java
  93. @@ -191,6 +191,8 @@
  94.             writeS("Invisible");
  95.         else if(AioManager.getInstance().hasAioPrivileges(this._activeChar.getObjectId()) || _activeChar.isAio())
  96.             writeS(Config.AIO_TITLE);
  97. +       else if(_activeChar.isAutoFarm())
  98. +           writeS(Config.AUTO_FARM_TITLE);
  99.         else
  100.             writeS((_activeChar.getPolyType() != PolyType.DEFAULT) ? "Morphed" : _activeChar.getTitle());
  101.        
  102. @@ -243,6 +245,8 @@
  103.             writeC(0x01); // team circle around feet 1= Blue, 2 = red
  104.         else if (_activeChar.getTeam() == 2 || _activeChar.getTeamTour() == 2)
  105.             writeC(0x02); // team circle around feet 1= Blue, 2 = red
  106. +       else if(_activeChar.isAutoFarm())
  107. +           writeC(0x02);
  108.         else
  109.             writeC(0x00); // team circle around feet 1= Blue, 2 = red
  110.        
  111.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement