فهرست منبع

BETA: Moving reloadNpc call to saveNpc in order to compare changes and reload only things we've modified.

Rumen Nikiforov 12 سال پیش
والد
کامیت
d6d3d79307
1فایلهای تغییر یافته به همراه5 افزوده شده و 0 حذف شده
  1. 5 0
      L2J_Server_BETA/java/com/l2jserver/gameserver/datatables/NpcTable.java

+ 5 - 0
L2J_Server_BETA/java/com/l2jserver/gameserver/datatables/NpcTable.java

@@ -373,6 +373,11 @@ public class NpcTable
 				updated += performUpdate(npcaidataAttributes, "npcaidata", "npcId", npcaidataAttributeValues, npcId, con);
 				updated += performUpdate(npcElementAttributes, "npc_elementals", "npc_id", npcElementAttributeValues, npcId, con);
 			}
+			
+			if (updated > 0)
+			{
+				reloadNpc(npcId, !npcAttributeValues.isEmpty(), !npcaidataAttributeValues.isEmpty(), !npcElementAttributeValues.isEmpty(), false, false, false);
+			}
 		}
 		catch (Exception e)
 		{