Changed L2Character setIsRunning visibility to private.
This commit is contained in:
@@ -155,7 +155,7 @@ public final class PlainsOfLizardman extends AbstractNpcAI
|
||||
final L2Attackable monster = (L2Attackable) target;
|
||||
if ((monster.getId() == TANTA_MAGICIAN) || (monster.getId() == TANTA_SCOUT))
|
||||
{
|
||||
target.setIsRunning(true);
|
||||
target.setRunning();
|
||||
target.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(npc.getX(), npc.getY(), npc.getZ(), 0));
|
||||
}
|
||||
}
|
||||
|
@@ -142,7 +142,7 @@ public final class PrimevalIsle extends AbstractNpcAI
|
||||
if ((target != null))
|
||||
{
|
||||
npc.setTarget(target);
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(target, 0, 555);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, target);
|
||||
}
|
||||
@@ -156,7 +156,7 @@ public final class PrimevalIsle extends AbstractNpcAI
|
||||
if ((target != null))
|
||||
{
|
||||
npc.setTarget(target);
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(target, 0, 555);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, target);
|
||||
}
|
||||
@@ -167,7 +167,7 @@ public final class PrimevalIsle extends AbstractNpcAI
|
||||
if ((target != null))
|
||||
{
|
||||
npc.setTarget(target);
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(target, 0, 555);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, target);
|
||||
}
|
||||
@@ -297,7 +297,7 @@ public final class PrimevalIsle extends AbstractNpcAI
|
||||
{
|
||||
npc.setTarget(creature);
|
||||
npc.doCast(CREW_SKILL.getSkill());
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||
}
|
||||
return super.onSeeCreature(npc, creature, isSummon);
|
||||
@@ -424,7 +424,7 @@ public final class PrimevalIsle extends AbstractNpcAI
|
||||
{
|
||||
npc.getVariables().set("SELFBUFF_USED", 1);
|
||||
npc.doCast(selfRangeBuff1.getSkill());
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, target);
|
||||
}
|
||||
}
|
||||
|
@@ -250,7 +250,7 @@ public final class SelMahumDrill extends AbstractNpcAI
|
||||
}
|
||||
receiver.disableCoreAI(true);
|
||||
receiver.getVariables().set("BUSY_STATE", 1);
|
||||
receiver.setIsRunning(true);
|
||||
receiver.setRunning();
|
||||
receiver.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location((receiver.getX() + getRandom(-800, 800)), (receiver.getY() + getRandom(-800, 800)), receiver.getZ(), receiver.getHeading()));
|
||||
startQuestTimer("reset_busy_state", 5000, receiver, null);
|
||||
}
|
||||
|
@@ -140,7 +140,7 @@ public final class SelMahumSquad extends AbstractNpcAI
|
||||
case "fire_arrived":
|
||||
{
|
||||
// myself.i_quest0 = 1;
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
npc.setTarget(npc);
|
||||
|
||||
if (npc.isNoRndWalk())
|
||||
@@ -165,7 +165,7 @@ public final class SelMahumSquad extends AbstractNpcAI
|
||||
case "remove_effects":
|
||||
{
|
||||
// myself.i_quest0 = 0;
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.setDisplayEffect(MAHUM_EFFECT_NONE);
|
||||
break;
|
||||
}
|
||||
@@ -237,7 +237,7 @@ public final class SelMahumSquad extends AbstractNpcAI
|
||||
if (!receiver.isNoRndWalk() && !receiver.isDead() && (receiver.getAI().getIntention() != CtrlIntention.AI_INTENTION_ATTACK) && Util.contains(SQUAD_LEADERS, receiver.getId()))
|
||||
{
|
||||
receiver.setIsNoRndWalk(true); // Moving to fire - i_ai0 = 1
|
||||
receiver.setIsRunning(true);
|
||||
receiver.setRunning();
|
||||
final Location loc = sender.getPointInRange(100, 200);
|
||||
loc.setHeading(receiver.getHeading());
|
||||
receiver.stopMove(null);
|
||||
@@ -272,7 +272,7 @@ public final class SelMahumSquad extends AbstractNpcAI
|
||||
}
|
||||
receiver.setIsNoRndWalk(true); // Moving to fire - i_ai0 = 1
|
||||
receiver.getVariables().set("BUSY_STATE", 1); // Eating - i_ai3 = 1
|
||||
receiver.setIsRunning(true);
|
||||
receiver.setRunning();
|
||||
receiver.broadcastSay(ChatType.NPC_GENERAL, (getRandom(3) < 1) ? NpcStringId.LOOKS_DELICIOUS : NpcStringId.LET_S_GO_EAT);
|
||||
final Location loc = sender.getPointInRange(100, 200);
|
||||
loc.setHeading(receiver.getHeading());
|
||||
@@ -379,7 +379,7 @@ public final class SelMahumSquad extends AbstractNpcAI
|
||||
cancelQuestTimer("chef_set_invul", npc, null);
|
||||
npc.getVariables().remove("BUSY_STATE");
|
||||
npc.getVariables().remove("INVUL_REMOVE_TIMER_STARTED");
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -84,7 +84,7 @@ public final class TurekOrcs extends AbstractNpcAI
|
||||
// Say and flee
|
||||
npc.broadcastSay(ChatType.GENERAL, NpcStringId.getNpcStringId(getRandom(1000007, 1000027)));
|
||||
npc.disableCoreAI(true); // to avoid attacking behaviour, while flee
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(npc.getAIValue("fleeX"), npc.getAIValue("fleeY"), npc.getAIValue("fleeZ")));
|
||||
npc.getVariables().set("state", 1);
|
||||
npc.getVariables().set("attacker", attacker.getObjectId());
|
||||
@@ -98,7 +98,7 @@ public final class TurekOrcs extends AbstractNpcAI
|
||||
if (eventName.equals("WARNING") && !receiver.isDead() && (receiver.getAI().getIntention() != CtrlIntention.AI_INTENTION_ATTACK) && (reference != null) && (reference.getActingPlayer() != null) && !reference.getActingPlayer().isDead())
|
||||
{
|
||||
receiver.getVariables().set("state", 3);
|
||||
receiver.setIsRunning(true);
|
||||
receiver.setRunning();
|
||||
((L2Attackable) receiver).addDamageHate(reference.getActingPlayer(), 0, 99999);
|
||||
receiver.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, reference.getActingPlayer());
|
||||
}
|
||||
|
@@ -58,7 +58,7 @@ public final class Anais extends AbstractNpcAI
|
||||
{
|
||||
final L2Npc npc = _divineBurners.get(pot);
|
||||
npc.setDisplayEffect(1);
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
if (pot < 4)
|
||||
{
|
||||
_current = npc;
|
||||
@@ -96,10 +96,10 @@ public final class Anais extends AbstractNpcAI
|
||||
final L2Npc b = _divineBurners.get(_pot);
|
||||
_pot = _pot + 1;
|
||||
b.setDisplayEffect(1);
|
||||
b.setIsRunning(false);
|
||||
b.setWalking();
|
||||
final L2Npc ward = addSpawn(GRAIL_WARD, new Location(b.getX(), b.getY(), b.getZ()), true, 0);
|
||||
((L2Attackable) ward).addDamageHate(_nextTarget, 0, 999);
|
||||
ward.setIsRunning(true);
|
||||
ward.setRunning();
|
||||
ward.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, _nextTarget, null);
|
||||
startQuestTimer("GUARD_ATTACK", 1000, ward, _nextTarget, true);
|
||||
startQuestTimer("SUICIDE", 20000, ward, null);
|
||||
@@ -131,7 +131,7 @@ public final class Anais extends AbstractNpcAI
|
||||
if (_current != null)
|
||||
{
|
||||
_current.setDisplayEffect(2);
|
||||
_current.setIsRunning(false);
|
||||
_current.setWalking();
|
||||
_current = null;
|
||||
}
|
||||
npc.doDie(null);
|
||||
@@ -179,7 +179,7 @@ public final class Anais extends AbstractNpcAI
|
||||
if (_current != null)
|
||||
{
|
||||
_current.setDisplayEffect(2);
|
||||
_current.setIsRunning(false);
|
||||
_current.setWalking();
|
||||
_current = null;
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
|
@@ -111,14 +111,14 @@ public final class Minigame extends AbstractNpcAI
|
||||
if (npc.getId() == BURNER)
|
||||
{
|
||||
npc.setDisplayEffect(2);
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
}
|
||||
else
|
||||
{
|
||||
for (L2Npc burner : room.getBurners())
|
||||
{
|
||||
burner.setDisplayEffect(2);
|
||||
burner.setIsRunning(false);
|
||||
burner.setWalking();
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -146,7 +146,7 @@ public final class Minigame extends AbstractNpcAI
|
||||
{
|
||||
final L2Npc b = room.getBurners()[room.getOrder()[room.getCurrentPot()]];
|
||||
b.setDisplayEffect(1);
|
||||
b.setIsRunning(false);
|
||||
b.setWalking();
|
||||
startQuestTimer("off", 2000, b, null); // Stopping burning each pot 2s after
|
||||
startQuestTimer("timer", TIMER_INTERVAL * 1000, npc, null);
|
||||
room.setCurrentPot(room.getCurrentPot() + 1);
|
||||
@@ -277,7 +277,7 @@ public final class Minigame extends AbstractNpcAI
|
||||
if (room.getCurrentPot() < 8)
|
||||
{
|
||||
npc.setDisplayEffect(1);
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
startQuestTimer("off", 2000, npc, null);
|
||||
room.setCurrentPot(room.getCurrentPot() + 1);
|
||||
}
|
||||
@@ -422,7 +422,7 @@ public final class Minigame extends AbstractNpcAI
|
||||
for (L2Npc burner : _burners)
|
||||
{
|
||||
burner.setDisplayEffect(1);
|
||||
burner.setIsRunning(false);
|
||||
burner.setWalking();
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -95,7 +95,7 @@ public final class Maguen extends AbstractNpcAI
|
||||
final L2Npc maguen = addSpawn(MAGUEN, npc.getLocation(), true, 60000, true);
|
||||
maguen.getVariables().set("SUMMON_PLAYER", player);
|
||||
maguen.setTitle(player.getName());
|
||||
maguen.setIsRunning(true);
|
||||
maguen.setRunning();
|
||||
maguen.getAI().setIntention(CtrlIntention.AI_INTENTION_FOLLOW, player);
|
||||
maguen.broadcastStatusUpdate();
|
||||
showOnScreenMsg(player, NpcStringId.MAGUEN_APPEARANCE, 2, 4000);
|
||||
|
@@ -86,7 +86,7 @@ public final class Nemo extends AbstractNpcAI
|
||||
maguen.getVariables().set("TEST_MAGUEN", 1);
|
||||
player.getVariables().set("TEST_MAGUEN", 1);
|
||||
maguen.setTitle(player.getName());
|
||||
maguen.setIsRunning(true);
|
||||
maguen.setRunning();
|
||||
maguen.getAI().setIntention(CtrlIntention.AI_INTENTION_FOLLOW, player);
|
||||
maguen.broadcastStatusUpdate();
|
||||
showOnScreenMsg(player, NpcStringId.MAGUEN_APPEARANCE, 2, 4000);
|
||||
|
@@ -173,7 +173,7 @@ public final class SummonNpc extends AbstractEffect
|
||||
{
|
||||
npc.scheduleDespawn(_despawnDelay);
|
||||
}
|
||||
npc.setIsRunning(false); // TODO: Fix broadcast info.
|
||||
npc.setWalking(); // TODO: Fix broadcast info.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -744,7 +744,7 @@ public final class TowerOfNaia extends AbstractNpcAI
|
||||
else if (((npcId == SPORE_BASIC) || ((npcId >= SPORE_FIRE) && (npcId <= SPORE_EARTH))) && (_challengeState == STATE_SPORE_CHALLENGE_IN_PROGRESS))
|
||||
{
|
||||
_sporeSpawn.add(npc);
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
final int[] coord = SPORES_MOVE_POINTS[getRandom(SPORES_MOVE_POINTS.length)];
|
||||
npc.getSpawn().setX(coord[0]);
|
||||
npc.getSpawn().setY(coord[1]);
|
||||
@@ -833,7 +833,7 @@ public final class TowerOfNaia extends AbstractNpcAI
|
||||
final double distance = npc.calculateDistance(coords[0], coords[1], coords[2], true, false);
|
||||
final int heading = Util.calculateHeadingFrom(npc.getX(), npc.getY(), coords[0], coords[1]);
|
||||
time = (int) ((distance / npc.getWalkSpeed()) * 1000);
|
||||
npc.setIsRunning(false);
|
||||
npc.setWalking();
|
||||
npc.disableCoreAI(true);
|
||||
npc.setIsNoRndWalk(true);
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(coords[0], coords[1], coords[2], heading));
|
||||
|
@@ -84,7 +84,7 @@ public final class IceQueensCastle extends AbstractInstance
|
||||
{
|
||||
if ((character.getId() == ARCHERY_KNIGHT) && !character.isDead() && !((L2Attackable) character).isDecayed())
|
||||
{
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, character);
|
||||
((L2Attackable) npc).addDamageHate(character, 0, 999999);
|
||||
}
|
||||
@@ -145,7 +145,7 @@ public final class IceQueensCastle extends AbstractInstance
|
||||
{
|
||||
if ((character.getId() == ARCHERY_KNIGHT) && !character.isDead() && !((L2Attackable) character).isDecayed())
|
||||
{
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, character);
|
||||
((L2Attackable) npc).addDamageHate(character, 0, 999999);
|
||||
npc.setScriptValue(1);
|
||||
|
@@ -408,7 +408,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
if (npc.getVariables().getInt("FREYA_MOVE") == 0)
|
||||
{
|
||||
world.controller.getVariables().set("FREYA_MOVE", 1);
|
||||
world.freya.setIsRunning(true);
|
||||
world.freya.setRunning();
|
||||
world.freya.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, MIDDLE_POINT);
|
||||
}
|
||||
break;
|
||||
@@ -458,13 +458,13 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
world.freya.disableCoreAI(false);
|
||||
manageScreenMsg(world, NpcStringId.BEGIN_STAGE_4);
|
||||
world.supp_Jinia = (L2QuestGuardInstance) addSpawn(SUPP_JINIA, SUPP_JINIA_SPAWN, false, 0, true, world.getInstanceId());
|
||||
world.supp_Jinia.setIsRunning(true);
|
||||
world.supp_Jinia.setRunning();
|
||||
world.supp_Jinia.setIsInvul(true);
|
||||
world.supp_Jinia.setCanReturnToSpawnPoint(false);
|
||||
world.supp_Jinia.reduceCurrentHp(1, world.freya, null); // TODO: Find better way for attack
|
||||
world.freya.reduceCurrentHp(1, world.supp_Jinia, null);
|
||||
world.supp_Kegor = (L2QuestGuardInstance) addSpawn(SUPP_KEGOR, SUPP_KEGOR_SPAWN, false, 0, true, world.getInstanceId());
|
||||
world.supp_Kegor.setIsRunning(true);
|
||||
world.supp_Kegor.setRunning();
|
||||
world.supp_Kegor.setIsInvul(true);
|
||||
world.supp_Kegor.setCanReturnToSpawnPoint(false);
|
||||
world.supp_Kegor.reduceCurrentHp(1, world.freya, null); // TODO: Find better way for attack
|
||||
@@ -707,7 +707,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
final L2Attackable breath = (L2Attackable) addSpawn(BREATH, npc.getLocation(), true, 0, false, world.getInstanceId());
|
||||
breath.setIsRunning(true);
|
||||
breath.setRunning();
|
||||
breath.addDamageHate(mob.getMostHated(), 0, 999);
|
||||
breath.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, mob.getMostHated());
|
||||
startQuestTimer("BLIZZARD", 20000, breath, null);
|
||||
@@ -795,7 +795,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
{
|
||||
world.controller.getVariables().set("FREYA_MOVE", 1);
|
||||
manageScreenMsg(world, NpcStringId.FREYA_HAS_STARTED_TO_MOVE);
|
||||
world.freya.setIsRunning(true);
|
||||
world.freya.setRunning();
|
||||
world.freya.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, MIDDLE_POINT);
|
||||
}
|
||||
|
||||
@@ -873,7 +873,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
if (world.controller.getVariables().getInt("FREYA_MOVE") == 0)
|
||||
{
|
||||
world.controller.getVariables().set("FREYA_MOVE", 1);
|
||||
world.freya.setIsRunning(true);
|
||||
world.freya.setRunning();
|
||||
world.freya.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, MIDDLE_POINT);
|
||||
}
|
||||
|
||||
@@ -1099,7 +1099,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
final L2Attackable breath = (L2Attackable) addSpawn(BREATH, npc.getLocation(), false, 0, false, world.getInstanceId());
|
||||
if (player != null)
|
||||
{
|
||||
breath.setIsRunning(true);
|
||||
breath.setRunning();
|
||||
breath.addDamageHate(player, 0, 999);
|
||||
breath.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, player);
|
||||
}
|
||||
@@ -1172,7 +1172,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
{
|
||||
var.set("FREYA_MOVE", 1);
|
||||
manageScreenMsg(world, NpcStringId.FREYA_HAS_STARTED_TO_MOVE);
|
||||
world.freya.setIsRunning(true);
|
||||
world.freya.setRunning();
|
||||
world.freya.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, MIDDLE_POINT);
|
||||
}
|
||||
|
||||
@@ -1346,7 +1346,7 @@ public final class IceQueensCastleNormalBattle extends AbstractInstance
|
||||
if (target != null)
|
||||
{
|
||||
mob.addDamageHate(target, 0, 999);
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, target);
|
||||
}
|
||||
else
|
||||
|
@@ -94,7 +94,7 @@ public final class LibraryOfSages extends AbstractInstance
|
||||
}
|
||||
case "FOLLOW":
|
||||
{
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().startFollow(player);
|
||||
npc.broadcastSay(ChatType.NPC_GENERAL, ELCADIA_DIALOGS[getRandom(ELCADIA_DIALOGS.length)]);
|
||||
startQuestTimer("FOLLOW", 10000, npc, player);
|
||||
|
@@ -100,7 +100,7 @@ public final class MithrilMine extends AbstractInstance
|
||||
{
|
||||
final L2Attackable spawnedMob = (L2Attackable) addSpawn(MITHRIL_MILLIPEDE, loc, false, 0, false, world.getInstanceId());
|
||||
spawnedMob.setScriptValue(1);
|
||||
spawnedMob.setIsRunning(true);
|
||||
spawnedMob.setRunning();
|
||||
spawnedMob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, npc);
|
||||
spawnedMob.addDamageHate(npc, 0, 999999);
|
||||
}
|
||||
|
@@ -270,7 +270,7 @@ public final class MonasteryOfSilence1 extends AbstractInstance
|
||||
}
|
||||
case "FOLLOW":
|
||||
{
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().startFollow(player);
|
||||
if (player.isInCombat())
|
||||
{
|
||||
@@ -398,7 +398,7 @@ public final class MonasteryOfSilence1 extends AbstractInstance
|
||||
for (Location LOC : SLAVE_SPAWN_1_LOC)
|
||||
{
|
||||
L2Attackable mob = (L2Attackable) addSpawn(TRAINEE_OF_REST, LOC, false, 0, false, world.getInstanceId());
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(player, 0, 999);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, player);
|
||||
}
|
||||
@@ -408,7 +408,7 @@ public final class MonasteryOfSilence1 extends AbstractInstance
|
||||
for (Location LOC : SLAVE_SPAWN_2_LOC)
|
||||
{
|
||||
L2Attackable mob = (L2Attackable) addSpawn(TRAINEE_OF_REST, LOC, false, 0, false, world.getInstanceId());
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(player, 0, 999);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, player);
|
||||
}
|
||||
@@ -418,7 +418,7 @@ public final class MonasteryOfSilence1 extends AbstractInstance
|
||||
for (Location LOC : SLAVE_SPAWN_3_LOC)
|
||||
{
|
||||
L2Attackable mob = (L2Attackable) addSpawn(SUPPLICANT_OF_REST, LOC, false, 0, false, world.getInstanceId());
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(player, 0, 999);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, player);
|
||||
}
|
||||
@@ -428,7 +428,7 @@ public final class MonasteryOfSilence1 extends AbstractInstance
|
||||
for (Location LOC : SLAVE_SPAWN_4_LOC)
|
||||
{
|
||||
L2Attackable mob = (L2Attackable) addSpawn(SUPPLICANT_OF_REST, LOC, false, 0, false, world.getInstanceId());
|
||||
mob.setIsRunning(true);
|
||||
mob.setRunning();
|
||||
mob.addDamageHate(player, 0, 999);
|
||||
mob.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, player);
|
||||
}
|
||||
|
@@ -207,7 +207,7 @@ public final class PailakaDevilsLegacy extends AbstractInstance
|
||||
{
|
||||
npc.disableCoreAI(true);
|
||||
npc.setScriptValue(1);
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, LEMATAN_PORT_POINT);
|
||||
}
|
||||
break;
|
||||
|
@@ -737,7 +737,7 @@ public final class Q00065_CertifiedSoulBreaker extends Quest
|
||||
{
|
||||
startQuestTimer("DESPAWN_5", 5000, npc, null);
|
||||
npc.broadcastPacket(new NpcSay(npc, ChatType.NPC_GENERAL, NpcStringId.DRATS_HOW_COULD_I_BE_SO_WRONG));
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, MOVE_TO);
|
||||
}
|
||||
else if (npc.getId() == GUARDIAN_ANGEL)
|
||||
|
@@ -683,7 +683,7 @@ public final class Q00227_TestOfTheReformer extends Quest
|
||||
case OL_MAHUM_BETRAYER:
|
||||
{
|
||||
startQuestTimer("DESPAWN", 5000, npc, null, true);
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, MOVE_TO);
|
||||
npc.getVariables().set("SPAWNED", 0);
|
||||
break;
|
||||
|
@@ -269,7 +269,14 @@ public final class WalkingManager implements IXmlReader
|
||||
}
|
||||
|
||||
npc.sendDebugMessage("Starting to move at route '" + routeName + "'");
|
||||
npc.setIsRunning(node.runToLocation());
|
||||
if (node.runToLocation())
|
||||
{
|
||||
npc.setRunning();
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.setWalking();
|
||||
}
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, node);
|
||||
walk.setWalkCheckTask(ThreadPoolManager.scheduleAtFixedRate(new StartMovingTask(npc, routeName), 60000, 60000)); // start walk check task, for resuming walk after fight
|
||||
|
||||
@@ -302,7 +309,14 @@ public final class WalkingManager implements IXmlReader
|
||||
walk.setBlocked(true);
|
||||
final L2NpcWalkerNode node = walk.getCurrentNode();
|
||||
npc.sendDebugMessage("Route '" + routeName + "', continuing to node " + walk.getCurrentNodeId());
|
||||
npc.setIsRunning(node.runToLocation());
|
||||
if (node.runToLocation())
|
||||
{
|
||||
npc.setRunning();
|
||||
}
|
||||
else
|
||||
{
|
||||
npc.setWalking();
|
||||
}
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, node);
|
||||
walk.setBlocked(false);
|
||||
walk.setStoppedByAttack(false);
|
||||
|
@@ -2875,7 +2875,7 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe
|
||||
return _isRunning;
|
||||
}
|
||||
|
||||
public final void setIsRunning(boolean value)
|
||||
private final void setIsRunning(boolean value)
|
||||
{
|
||||
if (_isRunning == value)
|
||||
{
|
||||
@@ -2919,10 +2919,7 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe
|
||||
/** Set the L2Character movement type to run and send Server->Client packet ChangeMoveType to all others L2PcInstance. */
|
||||
public final void setRunning()
|
||||
{
|
||||
if (!isRunning())
|
||||
{
|
||||
setIsRunning(true);
|
||||
}
|
||||
setIsRunning(true);
|
||||
}
|
||||
|
||||
public final boolean isSleeping()
|
||||
@@ -3088,10 +3085,7 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe
|
||||
*/
|
||||
public final void setWalking()
|
||||
{
|
||||
if (isRunning())
|
||||
{
|
||||
setIsRunning(false);
|
||||
}
|
||||
setIsRunning(false);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -2780,7 +2780,7 @@ public abstract class AbstractScript extends ManagedScript
|
||||
{
|
||||
((L2Attackable) npc).addDamageHate(target, 0, desire);
|
||||
}
|
||||
npc.setIsRunning(true);
|
||||
npc.setRunning();
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, target);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user