Просмотр исходного кода

Split LS and GS. Dont forget update start scripts. DP update required.

JIV 15 лет назад
Родитель
Сommit
a61bc89828
60 измененных файлов с 126 добавлено и 133 удалено
  1. 11 2
      L2_GameServer/build.xml
  2. BIN
      L2_GameServer/dist/GSRegister.exe
  3. BIN
      L2_GameServer/dist/L2JConfig.exe
  4. 1 1
      L2_GameServer/dist/LoginServer_loop.sh
  5. 1 1
      L2_GameServer/dist/RegisterGameServer.bat
  6. 1 1
      L2_GameServer/dist/RegisterGameServer.sh
  7. 1 1
      L2_GameServer/dist/startLoginServer.bat
  8. 1 1
      L2_GameServer/dist/startSQLAccountManager.bat
  9. 1 1
      L2_GameServer/dist/startSQLAccountManager.sh
  10. 1 1
      L2_GameServer/java/com/l2jserver/Base64.java
  11. 50 25
      L2_GameServer/java/com/l2jserver/Config.java
  12. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/Announcements.java
  13. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/LoginServerThread.java
  14. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/Territory.java
  15. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/ThreadPoolManager.java
  16. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/ClanBBSManager.java
  17. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/PostBBSManager.java
  18. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/RegionBBSManager.java
  19. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/TopicBBSManager.java
  20. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/instancemanager/DimensionalRiftManager.java
  21. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/instancemanager/PetitionManager.java
  22. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/MacroList.java
  23. 2 2
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/L2Npc.java
  24. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2CastleChamberlainInstance.java
  25. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2ClassMasterInstance.java
  26. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2FestivalGuideInstance.java
  27. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2NpcInstance.java
  28. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2VillageMasterInstance.java
  29. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/actor/stat/PlayableStat.java
  30. 6 6
      L2_GameServer/java/com/l2jserver/gameserver/model/entity/DimensionalRift.java
  31. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/entity/L2Event.java
  32. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/entity/TvTEvent.java
  33. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/model/zone/type/L2PoisonZone.java
  34. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/network/serverpackets/ShowBoard.java
  35. 1 2
      L2_GameServer/java/com/l2jserver/gameserver/skills/conditions/ConditionPlayerServitorNpcId.java
  36. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/templates/item/L2Armor.java
  37. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/templates/item/L2EtcItem.java
  38. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/templates/item/L2Weapon.java
  39. 1 0
      L2_GameServer/java/com/l2jserver/gameserver/util/FloodProtectorAction.java
  40. 1 1
      L2_GameServer/java/com/l2jserver/gameserver/util/GMAudit.java
  41. 1 1
      L2_GameServer/java/com/l2jserver/log/AccountingFormatter.java
  42. 1 1
      L2_GameServer/java/com/l2jserver/log/AuditFormatter.java
  43. 1 1
      L2_GameServer/java/com/l2jserver/log/ChatLogFormatter.java
  44. 1 1
      L2_GameServer/java/com/l2jserver/log/ConsoleLogFormatter.java
  45. 1 1
      L2_GameServer/java/com/l2jserver/log/DamageFormatter.java
  46. 1 1
      L2_GameServer/java/com/l2jserver/log/EnchantFormatter.java
  47. 1 1
      L2_GameServer/java/com/l2jserver/log/FileLogFormatter.java
  48. 1 1
      L2_GameServer/java/com/l2jserver/log/ItemLogFormatter.java
  49. 1 1
      L2_GameServer/java/com/l2jserver/log/OlympiadFormatter.java
  50. 1 1
      L2_GameServer/java/com/l2jserver/loginserver/GameServerThread.java
  51. 2 2
      L2_GameServer/java/com/l2jserver/loginserver/L2LoginClient.java
  52. 2 2
      L2_GameServer/java/com/l2jserver/loginserver/LoginController.java
  53. 1 1
      L2_GameServer/java/com/l2jserver/util/StringUtil.java
  54. 1 1
      L2_GameServer/java/com/l2jserver/util/crypt/BlowfishEngine.java
  55. 1 1
      L2_GameServer/java/com/l2jserver/util/crypt/LoginCrypt.java
  56. 1 1
      L2_GameServer/java/com/l2jserver/util/crypt/NewCrypt.java
  57. 1 1
      L2_GameServer/java/com/l2jserver/util/crypt/ScrambledKeyPair.java
  58. 2 43
      L2_GameServer/java/com/l2jserver/util/lib/Log.java
  59. 1 1
      L2_GameServer/java/com/l2jserver/util/lib/SqlUtils.java
  60. 1 1
      L2_GameServer/java/com/l2jserver/util/lib/memcache.java

+ 11 - 2
L2_GameServer/build.xml

@@ -67,11 +67,20 @@
 
 	<target name="jar" depends="compile" description="Create the jar file">
 		<jar destfile="${build}/l2jserver.jar">
-			<fileset dir="${build.classes}" />
+			<fileset dir="${build.classes}" >
+				<exclude name="**/loginserver/**"/>
+				<exclude name="**/accountmanager/**"/>
+				<exclude name="**/gsregistering/**"/>
+			</fileset>
+		</jar>
+		<jar destfile="${build}/l2jlogin.jar">
+			<fileset dir="${build.classes}" >
+				<exclude name="**/gameserver/**"/>
+			</fileset>
 		</jar>
 		<copy todir="${build.dist.login}">
 			<fileset dir="${build}">
-				<include name="l2jserver.jar" />
+				<include name="l2jlogin.jar" />
 			</fileset>
 		</copy>
 		<copy todir="${build.dist.game}">

BIN
L2_GameServer/dist/GSRegister.exe


BIN
L2_GameServer/dist/L2JConfig.exe


+ 1 - 1
L2_GameServer/dist/LoginServer_loop.sh

@@ -5,7 +5,7 @@ until [ $err == 0 ];
 do
 	[ -f log/java0.log.0 ] && mv log/java0.log.0 "log/`date +%Y-%m-%d_%H-%M-%S`_java.log"
 	[ -f log/stdout.log ] && mv log/stdout.log "log/`date +%Y-%m-%d_%H-%M-%S`_stdout.log"
-	nice -n -2 java -Xms128m -Xmx128m -cp ./../libs/*:l2jserver.jar com.l2jserver.loginserver.L2LoginServer > log/stdout.log 2>&1
+	nice -n -2 java -Xms128m -Xmx128m -cp ./../libs/*:l2jlogin.jar com.l2jserver.loginserver.L2LoginServer > log/stdout.log 2>&1
 	err=$?
 #	/etc/init.d/mysql restart
 	sleep 10;

+ 1 - 1
L2_GameServer/dist/RegisterGameServer.bat

@@ -1,5 +1,5 @@
 @echo off
 color 17
 cls
-java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*;l2jserver.jar com.l2jserver.gsregistering.BaseGameServerRegister -c
+java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*;l2jlogin.jar com.l2jserver.gsregistering.BaseGameServerRegister -c
 exit

+ 1 - 1
L2_GameServer/dist/RegisterGameServer.sh

@@ -1,2 +1,2 @@
 #!/bin/sh
-java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*:l2jserver.jar com.l2jserver.gsregistering.GameServerRegister -c
+java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*:l2jlogin.jar com.l2jserver.gsregistering.GameServerRegister -c

+ 1 - 1
L2_GameServer/dist/startLoginServer.bat

@@ -3,7 +3,7 @@ title Login Server Console
 :start
 echo Starting L2J Login Server.
 echo.
-java -Xms128m -Xmx128m  -cp ./../libs/*;l2jserver.jar com.l2jserver.loginserver.L2LoginServer
+java -Xms128m -Xmx128m  -cp ./../libs/*;l2jlogin.jar com.l2jserver.loginserver.L2LoginServer
 if ERRORLEVEL 2 goto restart
 if ERRORLEVEL 1 goto error
 goto end

+ 1 - 1
L2_GameServer/dist/startSQLAccountManager.bat

@@ -2,7 +2,7 @@
 cls
 title L2J - SQL Account Manager
 color 17
-java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*;l2jserver.jar com.l2jserver.accountmanager.SQLAccountManager 2> NUL
+java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*;l2jlogin.jar com.l2jserver.accountmanager.SQLAccountManager 2> NUL
 if %errorlevel% == 0 (
 echo.
 echo Execution succesful

+ 1 - 1
L2_GameServer/dist/startSQLAccountManager.sh

@@ -1,2 +1,2 @@
 #!/bin/sh
-java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*:l2jserver.jar com.l2jserver.accountmanager.SQLAccountManager
+java -Djava.util.logging.config.file=console.cfg -cp ./../libs/*:l2jlogin.jar com.l2jserver.accountmanager.SQLAccountManager

+ 1 - 1
L2_GameServer/java/com/l2jserver/Base64.java

@@ -18,7 +18,7 @@ import java.io.BufferedReader;
 import java.io.IOException;
 import java.io.InputStreamReader;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * Encodes and decodes to and from Base64 notation.

+ 50 - 25
L2_GameServer/java/com/l2jserver/Config.java

@@ -37,8 +37,8 @@ import java.util.logging.Logger;
 import javolution.util.FastList;
 
 import com.l2jserver.gameserver.util.FloodProtectorConfig;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.util.L2Properties;
+import com.l2jserver.util.StringUtil;
 
 public final class Config
 {
@@ -554,30 +554,30 @@ public final class Config
 	//--------------------------------------------------
 	// FloodProtector Settings
 	//--------------------------------------------------
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_USE_ITEM =
-		new FloodProtectorConfig("UseItemFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_ROLL_DICE =
-		new FloodProtectorConfig("RollDiceFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_FIREWORK =
-		new FloodProtectorConfig("FireworkFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_ITEM_PET_SUMMON =
-		new FloodProtectorConfig("ItemPetSummonFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_HERO_VOICE =
-		new FloodProtectorConfig("HeroVoiceFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_GLOBAL_CHAT =
-		new FloodProtectorConfig("GlobalChatFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_SUBCLASS =
-		new FloodProtectorConfig("SubclassFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_DROP_ITEM =
-		new FloodProtectorConfig("DropItemFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_SERVER_BYPASS =
-		new FloodProtectorConfig("ServerBypassFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_MULTISELL =
-		new FloodProtectorConfig("MultiSellFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_TRANSACTION =
-		new FloodProtectorConfig("TransactionFloodProtector");
-	public static final FloodProtectorConfig FLOOD_PROTECTOR_SENDMAIL =
-		new FloodProtectorConfig("SendMailFloodProtector");
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_USE_ITEM;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_ROLL_DICE;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_FIREWORK;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_ITEM_PET_SUMMON;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_HERO_VOICE;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_GLOBAL_CHAT;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_SUBCLASS;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_DROP_ITEM;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_SERVER_BYPASS;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_MULTISELL;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_TRANSACTION;
+		
+	public static  FloodProtectorConfig FLOOD_PROTECTOR_SENDMAIL;
+		
 
 
 	//--------------------------------------------------
@@ -962,6 +962,31 @@ public final class Config
 	{
 		if(Server.serverMode == Server.MODE_GAMESERVER)
 		{
+			FLOOD_PROTECTOR_USE_ITEM =
+				new FloodProtectorConfig("UseItemFloodProtector");
+			FLOOD_PROTECTOR_ROLL_DICE =
+				new FloodProtectorConfig("RollDiceFloodProtector");
+			FLOOD_PROTECTOR_FIREWORK =
+				new FloodProtectorConfig("FireworkFloodProtector");
+			FLOOD_PROTECTOR_ITEM_PET_SUMMON =
+				new FloodProtectorConfig("ItemPetSummonFloodProtector");
+			FLOOD_PROTECTOR_HERO_VOICE =
+				new FloodProtectorConfig("HeroVoiceFloodProtector");
+			FLOOD_PROTECTOR_GLOBAL_CHAT =
+				new FloodProtectorConfig("GlobalChatFloodProtector");
+			FLOOD_PROTECTOR_SUBCLASS =
+				new FloodProtectorConfig("SubclassFloodProtector");
+			FLOOD_PROTECTOR_DROP_ITEM =
+				new FloodProtectorConfig("DropItemFloodProtector");
+			FLOOD_PROTECTOR_SERVER_BYPASS =
+				new FloodProtectorConfig("ServerBypassFloodProtector");
+			FLOOD_PROTECTOR_MULTISELL =
+				new FloodProtectorConfig("MultiSellFloodProtector");
+			FLOOD_PROTECTOR_TRANSACTION =
+				new FloodProtectorConfig("TransactionFloodProtector");
+			FLOOD_PROTECTOR_SENDMAIL =
+				new FloodProtectorConfig("SendMailFloodProtector");
+			
 			_log.info("Loading GameServer Configuration Files...");
 			InputStream is = null;
 			try

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/Announcements.java

@@ -35,7 +35,7 @@ import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
 import com.l2jserver.gameserver.script.DateRange;
 import com.l2jserver.gameserver.util.Broadcast;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastList;
 

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/LoginServerThread.java

@@ -57,9 +57,9 @@ import com.l2jserver.gameserver.network.loginserverpackets.LoginServerFail;
 import com.l2jserver.gameserver.network.loginserverpackets.PlayerAuthResponse;
 import com.l2jserver.gameserver.network.serverpackets.CharSelectionInfo;
 import com.l2jserver.gameserver.network.serverpackets.LoginFail;
-import com.l2jserver.loginserver.crypt.NewCrypt;
 import com.l2jserver.util.Rnd;
 import com.l2jserver.util.Util;
+import com.l2jserver.util.crypt.NewCrypt;
 import com.l2jserver.util.network.BaseSendablePacket;
 
 public class LoginServerThread extends Thread

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/Territory.java

@@ -27,8 +27,8 @@ package com.l2jserver.gameserver;
 import java.util.Map;
 import java.util.logging.Logger;
 
-import com.l2jserver.gameserver.lib.SqlUtils;
 import com.l2jserver.gameserver.model.L2Territory;
+import com.l2jserver.util.lib.SqlUtils;
 
 import javolution.util.FastMap;
 

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/ThreadPoolManager.java

@@ -29,7 +29,7 @@ import org.mmocore.network.ReceivablePacket;
 
 import com.l2jserver.Config;
 import com.l2jserver.gameserver.network.L2GameClient;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * <p>This class is made to handle all the ThreadPools used in L2j.</p>

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/ClanBBSManager.java

@@ -21,7 +21,7 @@ import com.l2jserver.gameserver.model.L2Clan;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.network.SystemMessageId;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 
 public class ClanBBSManager extends BaseBBSManager

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/PostBBSManager.java

@@ -26,7 +26,7 @@ import com.l2jserver.gameserver.communitybbs.BB.Topic;
 import com.l2jserver.gameserver.communitybbs.BB.Post.CPost;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.network.serverpackets.ShowBoard;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastMap;
 

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/RegionBBSManager.java

@@ -35,7 +35,7 @@ import com.l2jserver.gameserver.network.clientpackets.Say2;
 import com.l2jserver.gameserver.network.serverpackets.CreatureSay;
 import com.l2jserver.gameserver.network.serverpackets.ShowBoard;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 public class RegionBBSManager extends BaseBBSManager
 {

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/communitybbs/Manager/TopicBBSManager.java

@@ -27,7 +27,7 @@ import com.l2jserver.gameserver.communitybbs.BB.Topic;
 import com.l2jserver.gameserver.datatables.ClanTable;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.network.serverpackets.ShowBoard;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastList;
 import javolution.util.FastMap;

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/instancemanager/DimensionalRiftManager.java

@@ -500,7 +500,7 @@ public class DimensionalRiftManager
 			return _partyInside;
 		}
 
-		public void setpartyInside(boolean partyInside)
+		public void setPartyInside(boolean partyInside)
 		{
 			_partyInside = partyInside;
 		}

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/instancemanager/PetitionManager.java

@@ -30,7 +30,7 @@ import com.l2jserver.gameserver.network.serverpackets.CreatureSay;
 import com.l2jserver.gameserver.network.serverpackets.L2GameServerPacket;
 import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastList;
 import javolution.util.FastMap;

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/MacroList.java

@@ -27,7 +27,7 @@ import com.l2jserver.L2DatabaseFactory;
 import com.l2jserver.gameserver.model.L2Macro.L2MacroCmd;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.network.serverpackets.SendMacroList;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastList;
 import javolution.util.FastMap;

+ 2 - 2
L2_GameServer/java/com/l2jserver/gameserver/model/actor/L2Npc.java

@@ -72,8 +72,8 @@ import com.l2jserver.gameserver.templates.chars.L2NpcTemplate.AIType;
 import com.l2jserver.gameserver.templates.item.L2Item;
 import com.l2jserver.gameserver.templates.item.L2Weapon;
 import com.l2jserver.gameserver.util.Broadcast;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.util.Rnd;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class represents a Non-Player-Character in the world. It can be a monster or a friendly character.
@@ -1631,7 +1631,7 @@ public class L2Npc extends L2Character
 				L2PcInstance player = target.getActingPlayer();
 				for (Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_SPELL_FINISHED))
 				{
-					quest.notifySpellFinished(((L2Npc) this), player, skill);
+					quest.notifySpellFinished(this, player, skill);
 				}
 			}
 		}

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2CastleChamberlainInstance.java

@@ -45,8 +45,8 @@ import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
 import com.l2jserver.gameserver.templates.skills.L2SkillType;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.gameserver.util.Util;
+import com.l2jserver.util.StringUtil;
 
 /**
  * Castle Chamberlains implementation used for: - tax rate control - regional

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2ClassMasterInstance.java

@@ -28,7 +28,7 @@ import com.l2jserver.gameserver.network.serverpackets.TutorialCloseHtml;
 import com.l2jserver.gameserver.network.serverpackets.TutorialShowHtml;
 import com.l2jserver.gameserver.network.serverpackets.TutorialShowQuestionMark;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class ...

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2FestivalGuideInstance.java

@@ -29,7 +29,7 @@ import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
 import com.l2jserver.gameserver.templates.StatsSet;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 
 /**

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2NpcInstance.java

@@ -31,7 +31,7 @@ import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
 import com.l2jserver.gameserver.skills.effects.EffectBuff;
 import com.l2jserver.gameserver.skills.effects.EffectDebuff;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 public class L2NpcInstance extends L2Npc
 {

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/actor/instance/L2VillageMasterInstance.java

@@ -47,8 +47,8 @@ import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
 import com.l2jserver.gameserver.network.serverpackets.UserInfo;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.gameserver.util.Util;
+import com.l2jserver.util.StringUtil;
 
 
 /**

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/actor/stat/PlayableStat.java

@@ -191,7 +191,7 @@ public class PlayableStat extends CharStat
 			L2ZoneType zone = ZoneManager.getInstance().getZone(getActiveChar(), L2SwampZone.class);
 			int bonus = zone == null ? 0 : ((L2SwampZone) zone).getMoveBonus();
 			double dbonus = bonus / 100.0; //%
-			val += (int) val * dbonus;
+			val += val * dbonus;
 		}
 		
 		return val;

+ 6 - 6
L2_GameServer/java/com/l2jserver/gameserver/model/entity/DimensionalRift.java

@@ -61,7 +61,7 @@ public class DimensionalRift
 	
 	public DimensionalRift(L2Party party, byte type, byte room)
 	{
-		DimensionalRiftManager.getInstance().getRoom(type, room).setpartyInside(true);
+		DimensionalRiftManager.getInstance().getRoom(type, room).setPartyInside(true);
 		_type = type;
 		_party = party;
 		_choosenRoom = room;
@@ -120,7 +120,7 @@ public class DimensionalRift
 			public void run()
 			{
 				if (_choosenRoom > -1)
-					DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).unspawn().setpartyInside(false);
+					DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).unspawn().setPartyInside(false);
 				
 				if (reasonTP && jumps_current < getMaxJumps() && _party.getMemberCount() > deadPlayers.size())
 				{
@@ -231,14 +231,14 @@ public class DimensionalRift
 		else
 			_hasJumped = true;
 		
-		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).unspawn().setpartyInside(false);
+		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).unspawn().setPartyInside(false);
 		_completedRooms.add(_choosenRoom);
 		_choosenRoom = -1;
 		
 		for (L2PcInstance p : _party.getPartyMembers())
 			teleportToNextRoom(p);
 		
-		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).setpartyInside(true);
+		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).setPartyInside(true);
 		
 		createSpawnTimer(_choosenRoom);
 		createTeleporterTimer(true);
@@ -279,7 +279,7 @@ public class DimensionalRift
 			while (DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).ispartyInside());
 		}
 		
-		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).setpartyInside(true);
+		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).setPartyInside(true);
 		checkBossRoom(_choosenRoom);
 		int[] coords = getRoomCoord(_choosenRoom);
 		player.teleToLocation(coords[0], coords[1], coords[2]);
@@ -314,7 +314,7 @@ public class DimensionalRift
 			earthQuakeTask = null;
 		}
 		
-		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).unspawn().setpartyInside(false);
+		DimensionalRiftManager.getInstance().getRoom(_type, _choosenRoom).unspawn().setPartyInside(false);
 		DimensionalRiftManager.getInstance().killRift(this);
 	}
 	

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/entity/L2Event.java

@@ -33,8 +33,8 @@ import com.l2jserver.gameserver.network.serverpackets.MagicSkillUse;
 import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
 import com.l2jserver.gameserver.util.Broadcast;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.util.EventData;
+import com.l2jserver.util.StringUtil;
 
 
 /**

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/entity/TvTEvent.java

@@ -45,8 +45,8 @@ import com.l2jserver.gameserver.network.serverpackets.NpcHtmlMessage;
 import com.l2jserver.gameserver.network.serverpackets.StatusUpdate;
 import com.l2jserver.gameserver.network.serverpackets.SystemMessage;
 import com.l2jserver.gameserver.templates.chars.L2NpcTemplate;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.util.Rnd;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastMap;
 

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/model/zone/type/L2PoisonZone.java

@@ -29,8 +29,8 @@ import com.l2jserver.gameserver.model.actor.instance.L2MonsterInstance;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.model.zone.L2ZoneType;
 import com.l2jserver.gameserver.network.serverpackets.EtcStatusUpdate;
-import com.l2jserver.gameserver.util.StringUtil;
 import com.l2jserver.util.Rnd;
+import com.l2jserver.util.StringUtil;
 
 
 /**

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/network/serverpackets/ShowBoard.java

@@ -16,7 +16,7 @@ package com.l2jserver.gameserver.network.serverpackets;
 
 import java.util.List;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 public class ShowBoard extends L2GameServerPacket
 {

+ 1 - 2
L2_GameServer/java/com/l2jserver/gameserver/skills/conditions/ConditionPlayerServitorNpcId.java

@@ -16,7 +16,6 @@ package com.l2jserver.gameserver.skills.conditions;
 
 import java.util.ArrayList;
 
-import com.l2jserver.gameserver.model.actor.L2Summon;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.skills.Env;
 
@@ -38,7 +37,7 @@ public class ConditionPlayerServitorNpcId extends Condition
 		if (!(env.player instanceof L2PcInstance))
 			return false;
 
-		if (!(env.player.getPet() instanceof L2Summon))
+		if ((env.player.getPet() == null))
 			return false;
 
 		return _npcIds == null || _npcIds.contains(env.player.getPet().getNpcId());

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/templates/item/L2Armor.java

@@ -25,7 +25,7 @@ import com.l2jserver.gameserver.skills.SkillHolder;
 import com.l2jserver.gameserver.skills.funcs.Func;
 import com.l2jserver.gameserver.skills.funcs.FuncTemplate;
 import com.l2jserver.gameserver.templates.StatsSet;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class is dedicated to the management of armors.

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/templates/item/L2EtcItem.java

@@ -16,7 +16,7 @@ package com.l2jserver.gameserver.templates.item;
 
 import com.l2jserver.gameserver.skills.SkillHolder;
 import com.l2jserver.gameserver.templates.StatsSet;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class is dedicated to the management of EtcItem.

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/templates/item/L2Weapon.java

@@ -39,7 +39,7 @@ import com.l2jserver.gameserver.skills.funcs.Func;
 import com.l2jserver.gameserver.skills.funcs.FuncTemplate;
 import com.l2jserver.gameserver.templates.StatsSet;
 import com.l2jserver.gameserver.templates.skills.L2SkillType;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 import javolution.util.FastList;
 

+ 1 - 0
L2_GameServer/java/com/l2jserver/gameserver/util/FloodProtectorAction.java

@@ -18,6 +18,7 @@ import java.util.logging.Logger;
 
 import com.l2jserver.gameserver.GameTimeController;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
+import com.l2jserver.util.StringUtil;
 
 /**
  * Flood protector implementation.

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/util/GMAudit.java

@@ -22,7 +22,7 @@ import java.util.Date;
 import java.util.logging.Level;
 import java.util.logging.Logger;
 
-import com.l2jserver.gameserver.lib.Log;
+import com.l2jserver.util.lib.Log;
 
 
 public class GMAudit

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/AccountingFormatter.java

@@ -21,7 +21,7 @@ import java.util.logging.LogRecord;
 
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
 import com.l2jserver.gameserver.network.L2GameClient;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 public class AccountingFormatter extends Formatter
 {

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/AuditFormatter.java

@@ -19,7 +19,7 @@ import java.util.Date;
 import java.util.logging.Formatter;
 import java.util.logging.LogRecord;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * @author zabbix

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/ChatLogFormatter.java

@@ -19,7 +19,7 @@ import java.util.Date;
 import java.util.logging.Formatter;
 import java.util.logging.LogRecord;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class ...

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/ConsoleLogFormatter.java

@@ -19,7 +19,7 @@ import java.io.StringWriter;
 import java.util.logging.Formatter;
 import java.util.logging.LogRecord;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class ...

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/DamageFormatter.java

@@ -24,7 +24,7 @@ import com.l2jserver.gameserver.model.actor.L2Attackable;
 import com.l2jserver.gameserver.model.actor.L2Character;
 import com.l2jserver.gameserver.model.actor.L2Summon;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 
 public class DamageFormatter extends Formatter

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/EnchantFormatter.java

@@ -22,7 +22,7 @@ import java.util.logging.LogRecord;
 import com.l2jserver.gameserver.model.L2ItemInstance;
 import com.l2jserver.gameserver.model.L2Skill;
 import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 
 public class EnchantFormatter extends Formatter

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/FileLogFormatter.java

@@ -19,7 +19,7 @@ import java.util.Date;
 import java.util.logging.Formatter;
 import java.util.logging.LogRecord;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 /**
  * This class ...

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/ItemLogFormatter.java

@@ -20,7 +20,7 @@ import java.util.logging.Formatter;
 import java.util.logging.LogRecord;
 
 import com.l2jserver.gameserver.model.L2ItemInstance;
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 
 /**

+ 1 - 1
L2_GameServer/java/com/l2jserver/log/OlympiadFormatter.java

@@ -19,7 +19,7 @@ import java.util.Date;
 import java.util.logging.Formatter;
 import java.util.logging.LogRecord;
 
-import com.l2jserver.gameserver.util.StringUtil;
+import com.l2jserver.util.StringUtil;
 
 public class OlympiadFormatter extends Formatter
 {

+ 1 - 1
L2_GameServer/java/com/l2jserver/loginserver/GameServerThread.java

@@ -31,7 +31,6 @@ import java.util.logging.Logger;
 
 import com.l2jserver.Config;
 import com.l2jserver.loginserver.GameServerTable.GameServerInfo;
-import com.l2jserver.loginserver.crypt.NewCrypt;
 import com.l2jserver.loginserver.gameserverpackets.BlowFishKey;
 import com.l2jserver.loginserver.gameserverpackets.ChangeAccessLevel;
 import com.l2jserver.loginserver.gameserverpackets.GameServerAuth;
@@ -46,6 +45,7 @@ import com.l2jserver.loginserver.loginserverpackets.KickPlayer;
 import com.l2jserver.loginserver.loginserverpackets.LoginServerFail;
 import com.l2jserver.loginserver.loginserverpackets.PlayerAuthResponse;
 import com.l2jserver.util.Util;
+import com.l2jserver.util.crypt.NewCrypt;
 import com.l2jserver.util.network.BaseSendablePacket;
 
 import javolution.util.FastSet;

+ 2 - 2
L2_GameServer/java/com/l2jserver/loginserver/L2LoginClient.java

@@ -25,8 +25,6 @@ import org.mmocore.network.MMOClient;
 import org.mmocore.network.MMOConnection;
 
 import com.l2jserver.Config;
-import com.l2jserver.loginserver.crypt.LoginCrypt;
-import com.l2jserver.loginserver.crypt.ScrambledKeyPair;
 import com.l2jserver.loginserver.serverpackets.L2LoginServerPacket;
 import com.l2jserver.loginserver.serverpackets.LoginFail;
 import com.l2jserver.loginserver.serverpackets.PlayFail;
@@ -34,6 +32,8 @@ import com.l2jserver.loginserver.serverpackets.LoginFail.LoginFailReason;
 import com.l2jserver.loginserver.serverpackets.PlayFail.PlayFailReason;
 import com.l2jserver.util.Rnd;
 import com.l2jserver.util.Util;
+import com.l2jserver.util.crypt.LoginCrypt;
+import com.l2jserver.util.crypt.ScrambledKeyPair;
 
 /**
  * Represents a client connected into the LoginServer

+ 2 - 2
L2_GameServer/java/com/l2jserver/loginserver/LoginController.java

@@ -33,12 +33,12 @@ import javax.crypto.Cipher;
 import com.l2jserver.Base64;
 import com.l2jserver.Config;
 import com.l2jserver.L2DatabaseFactory;
-import com.l2jserver.gameserver.lib.Log;
 import com.l2jserver.loginserver.GameServerTable.GameServerInfo;
-import com.l2jserver.loginserver.crypt.ScrambledKeyPair;
 import com.l2jserver.loginserver.gameserverpackets.ServerStatus;
 import com.l2jserver.loginserver.serverpackets.LoginFail.LoginFailReason;
 import com.l2jserver.util.Rnd;
+import com.l2jserver.util.crypt.ScrambledKeyPair;
+import com.l2jserver.util.lib.Log;
 
 import javolution.util.FastMap;
 import javolution.util.FastSet;

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/util/StringUtil.java → L2_GameServer/java/com/l2jserver/util/StringUtil.java

@@ -17,7 +17,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.gameserver.util;
+package com.l2jserver.util;
 
 /**
  * String utilities optimized for the best performance.

+ 1 - 1
L2_GameServer/java/com/l2jserver/loginserver/crypt/BlowfishEngine.java → L2_GameServer/java/com/l2jserver/util/crypt/BlowfishEngine.java

@@ -12,7 +12,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.loginserver.crypt;
+package com.l2jserver.util.crypt;
 
 import java.io.IOException;
 

+ 1 - 1
L2_GameServer/java/com/l2jserver/loginserver/crypt/LoginCrypt.java → L2_GameServer/java/com/l2jserver/util/crypt/LoginCrypt.java

@@ -12,7 +12,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.loginserver.crypt;
+package com.l2jserver.util.crypt;
 
 import java.io.IOException;
 

+ 1 - 1
L2_GameServer/java/com/l2jserver/loginserver/crypt/NewCrypt.java → L2_GameServer/java/com/l2jserver/util/crypt/NewCrypt.java

@@ -12,7 +12,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.loginserver.crypt;
+package com.l2jserver.util.crypt;
 
 import java.io.IOException;
 import java.util.logging.Logger;

+ 1 - 1
L2_GameServer/java/com/l2jserver/loginserver/crypt/ScrambledKeyPair.java → L2_GameServer/java/com/l2jserver/util/crypt/ScrambledKeyPair.java

@@ -12,7 +12,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.loginserver.crypt;
+package com.l2jserver.util.crypt;
 
 import java.math.BigInteger;
 import java.security.KeyPair;

+ 2 - 43
L2_GameServer/java/com/l2jserver/gameserver/lib/Log.java → L2_GameServer/java/com/l2jserver/util/lib/Log.java

@@ -20,7 +20,7 @@
 	version 0.1, 2005-06-06
 */
 
-package com.l2jserver.gameserver.lib;
+package com.l2jserver.util.lib;
 
 import java.io.File;
 import java.io.FileWriter;
@@ -29,9 +29,6 @@ import java.text.SimpleDateFormat;
 import java.util.Date;
 import java.util.logging.Logger;
 
-import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
-
-
 public class Log
 {
 	private static final Logger _log = Logger.getLogger(Log.class.getName());
@@ -73,45 +70,7 @@ public class Log
 		}
 	}
 	
-	@Deprecated
-	public static final void addEvent(L2PcInstance pc, String text)
-	{
-		String date = (new SimpleDateFormat("yy.MM.dd H:mm:ss")).format(new Date());
-		String filedate = (new SimpleDateFormat("yyMMdd_H")).format(new Date());
-		
-		new File("log/game").mkdirs();
-		File file = new File("log/game/actions_" + filedate + ".txt");
-		FileWriter save = null;
-		
-		try
-		{
-			save = new FileWriter(file, true);
-			String out = "[" + date + "] '<" + pc.getName() + ">': " + text + "\n"; // "+char_name()+"
-			save.write(out);
-		}
-		catch (IOException e)
-		{
-			_log.warning("saving actions log failed: " + e);
-			e.printStackTrace();
-		}
-		finally
-		{
-			try
-			{
-				save.close();
-			}
-			catch (Exception e1)
-			{
-			}
-		}
-	}
-	
-	@Deprecated
-	public static final void Assert(boolean exp)
-	{
-		Assert(exp, "");
-	}
-	
+
 	public static final void Assert(boolean exp, String cmt)
 	{
 		if (exp)

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/lib/SqlUtils.java → L2_GameServer/java/com/l2jserver/util/lib/SqlUtils.java

@@ -12,7 +12,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.gameserver.lib;
+package com.l2jserver.util.lib;
 
 import java.sql.Connection;
 import java.sql.PreparedStatement;

+ 1 - 1
L2_GameServer/java/com/l2jserver/gameserver/lib/memcache.java → L2_GameServer/java/com/l2jserver/util/lib/memcache.java

@@ -12,7 +12,7 @@
  * You should have received a copy of the GNU General Public License along with
  * this program. If not, see <http://www.gnu.org/licenses/>.
  */
-package com.l2jserver.gameserver.lib;
+package com.l2jserver.util.lib;
 
 import java.util.HashMap;
 import java.util.logging.Logger;