for(int i = 0; i < 2; i++)
{
try
{
Location pos = GeoEngine.findPointToStay(actor.getX(), actor.getY(), actor.getZ(), 100, 120, actor.getReflection().getGeoIndex());
L2Spawn sp = new L2Spawn(NpcTable.getTemplate(22631));
sp.setLoc(pos);
L2NpcInstance npc = sp.doSpawn(true);
npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, killer, Rnd.get(1, 100));
}
catch(Exception e)
{
e.printStackTrace();
}
}
}
}
if(actor.getNpcId() == 22631)
{
if(Rnd.chance(80))
{
for(int i = 0; i < 3; i++)
{
try
{
Location pos = GeoEngine.findPointToStay(actor.getX(), actor.getY(), actor.getZ(), 100, 120, actor.getReflection().getGeoIndex());
L2Spawn sp = new L2Spawn(NpcTable.getTemplate(22619));
sp.setLoc(pos);
L2NpcInstance npc = sp.doSpawn(true);
npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, killer, Rnd.get(1, 100));
}
catch(Exception e)
{
e.printStackTrace();