Added Croamis door logic to Isabella AI.
This commit is contained in:
@@ -17512,28 +17512,26 @@
|
||||
<status showHp="false" />
|
||||
<openStatus default="close" />
|
||||
</door>
|
||||
<door id="18200102" name="Oren_ancient_S.TofA_center_door001">
|
||||
<!-- AUTO GENERATED DOOR -->
|
||||
<nodes nodeZ="-4839">
|
||||
<node x="-48851" y="81506" />
|
||||
<node x="-48566" y="81541" />
|
||||
<node x="-48573" y="81590" />
|
||||
<node x="-48859" y="81559" />
|
||||
<door id="18200001" name="Oren_ancient_S.TofA_center_door_01">
|
||||
<nodes nodeZ="-4904">
|
||||
<node x="-50939" y="82304" />
|
||||
<node x="-50924" y="82294" />
|
||||
<node x="-50861" y="82407" />
|
||||
<node x="-50879" y="82415" />
|
||||
</nodes>
|
||||
<location x="-48712" y="81548" z="-4830" />
|
||||
<location x="-50895" y="82351" z="-4900" />
|
||||
<stats basePDef="644" baseMDef="518" baseHpMax="169710" />
|
||||
<status showHp="false" />
|
||||
<openStatus default="close" />
|
||||
</door>
|
||||
<door id="18200101" name="Oren_ancient_S.TofA_center_door001">
|
||||
<!-- AUTO GENERATED DOOR -->
|
||||
<nodes nodeZ="-4887">
|
||||
<node x="-52784" y="82768" />
|
||||
<node x="-52504" y="82832" />
|
||||
<node x="-52513" y="82874" />
|
||||
<node x="-52798" y="82824" />
|
||||
<door id="18200002" name="Oren_ancient_S.TofA_center_door_01">
|
||||
<nodes nodeZ="-4904">
|
||||
<node x="-51188" y="82436" />
|
||||
<node x="-51172" y="82427" />
|
||||
<node x="-51113" y="82539" />
|
||||
<node x="-51126" y="82550" />
|
||||
</nodes>
|
||||
<location x="-52649" y="82824" z="-4878" />
|
||||
<location x="-51155" y="82490" z="-4900" />
|
||||
<stats basePDef="644" baseMDef="518" baseHpMax="169710" />
|
||||
<status showHp="false" />
|
||||
<openStatus default="close" />
|
||||
|
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
package ai.areas.GardenOfSpirits;
|
||||
|
||||
import org.l2jmobius.gameserver.model.Location;
|
||||
import org.l2jmobius.gameserver.model.World;
|
||||
import org.l2jmobius.gameserver.model.actor.Npc;
|
||||
import org.l2jmobius.gameserver.model.actor.Player;
|
||||
@@ -26,20 +27,26 @@ import ai.AbstractNpcAI;
|
||||
/**
|
||||
* Isabella Raid Boss AI
|
||||
* @URL https://www.youtube.com/watch?v=3M73b6Kre6Y
|
||||
* @author Gigi
|
||||
* @author Gigi, Mobius
|
||||
*/
|
||||
public class Isabella extends AbstractNpcAI
|
||||
{
|
||||
// NPC
|
||||
private static final int ISABELLA = 26131;
|
||||
// Minions
|
||||
private static final int CROA = 26132;
|
||||
private static final int AMIS = 26133;
|
||||
private static final int CROAMIS = 23563;
|
||||
// Doors
|
||||
private static final int DOOR1 = 18200001;
|
||||
private static final int DOOR2 = 18200002;
|
||||
// Location
|
||||
private static final Location CROAMIS_SPAWN_LOCATION = new Location(-51033, 82405, -4882, 44107);
|
||||
|
||||
public Isabella()
|
||||
{
|
||||
addAttackId(ISABELLA);
|
||||
addKillId(ISABELLA);
|
||||
addSpawnId(ISABELLA, CROAMIS);
|
||||
addKillId(ISABELLA, CROAMIS);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -59,9 +66,8 @@ public class Isabella extends AbstractNpcAI
|
||||
addAttackPlayerDesire(minion5, player);
|
||||
final Npc minion6 = addSpawn(AMIS, -51157, 83298, -5112, 64987, true, 300000, false);
|
||||
addAttackPlayerDesire(minion6, player);
|
||||
return null;
|
||||
}
|
||||
return event;
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -88,16 +94,41 @@ public class Isabella extends AbstractNpcAI
|
||||
return super.onAttack(npc, attacker, damage, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onSpawn(Npc npc)
|
||||
{
|
||||
if (npc.getId() == ISABELLA)
|
||||
{
|
||||
addSpawn(CROAMIS, CROAMIS_SPAWN_LOCATION, false, 0);
|
||||
}
|
||||
else // CROAMIS
|
||||
{
|
||||
npc.setRandomWalking(false);
|
||||
npc.teleToLocation(CROAMIS_SPAWN_LOCATION); // No random spawn.
|
||||
closeDoor(DOOR1, 0);
|
||||
closeDoor(DOOR2, 0);
|
||||
}
|
||||
return super.onSpawn(npc);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(Npc npc, Player killer, boolean isSummon)
|
||||
{
|
||||
World.getInstance().forEachVisibleObjectInRange(npc, Monster.class, 1500, minion ->
|
||||
if (npc.getId() == ISABELLA)
|
||||
{
|
||||
if ((minion != null) && !minion.isAlikeDead() && ((minion.getId() == CROA) || (minion.getId() == AMIS)))
|
||||
World.getInstance().forEachVisibleObjectInRange(npc, Monster.class, 1500, minion ->
|
||||
{
|
||||
minion.deleteMe();
|
||||
}
|
||||
});
|
||||
if ((minion != null) && !minion.isAlikeDead() && ((minion.getId() == CROA) || (minion.getId() == AMIS)))
|
||||
{
|
||||
minion.deleteMe();
|
||||
}
|
||||
});
|
||||
}
|
||||
else // CROAMIS
|
||||
{
|
||||
openDoor(DOOR1, 0);
|
||||
openDoor(DOOR2, 0);
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user