Sync with L2jServer HighFive Feb 15th 2015.
This commit is contained in:
@ -27,9 +27,7 @@ import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import com.l2jserver.L2DatabaseFactory;
|
||||
import com.l2jserver.gameserver.data.xml.impl.NpcData;
|
||||
import com.l2jserver.gameserver.model.L2Spawn;
|
||||
import com.l2jserver.gameserver.model.actor.templates.L2NpcTemplate;
|
||||
import com.l2jserver.gameserver.model.entity.Fort;
|
||||
|
||||
public final class FortSiegeGuardManager
|
||||
@ -117,24 +115,16 @@ public final class FortSiegeGuardManager
|
||||
ArrayList<L2Spawn> siegeGuardSpawns = new ArrayList<>();
|
||||
while (rs.next())
|
||||
{
|
||||
L2NpcTemplate template = NpcData.getInstance().getTemplate(rs.getInt("npcId"));
|
||||
if (template != null)
|
||||
{
|
||||
L2Spawn spawn = new L2Spawn(template);
|
||||
spawn.setAmount(1);
|
||||
spawn.setX(rs.getInt("x"));
|
||||
spawn.setY(rs.getInt("y"));
|
||||
spawn.setZ(rs.getInt("z"));
|
||||
spawn.setHeading(rs.getInt("heading"));
|
||||
spawn.setRespawnDelay(rs.getInt("respawnDelay"));
|
||||
spawn.setLocationId(0);
|
||||
|
||||
siegeGuardSpawns.add(spawn);
|
||||
}
|
||||
else
|
||||
{
|
||||
_log.warning("Missing npc data in npc table for ID: " + rs.getInt("npcId"));
|
||||
}
|
||||
final L2Spawn spawn = new L2Spawn(rs.getInt("npcId"));
|
||||
spawn.setAmount(1);
|
||||
spawn.setX(rs.getInt("x"));
|
||||
spawn.setY(rs.getInt("y"));
|
||||
spawn.setZ(rs.getInt("z"));
|
||||
spawn.setHeading(rs.getInt("heading"));
|
||||
spawn.setRespawnDelay(rs.getInt("respawnDelay"));
|
||||
spawn.setLocationId(0);
|
||||
|
||||
siegeGuardSpawns.add(spawn);
|
||||
}
|
||||
_siegeGuards.put(fortId, siegeGuardSpawns);
|
||||
}
|
||||
|
Reference in New Issue
Block a user