#69 - Range Issue Debugging

This commit is contained in:
Rodgerwilco 2012-04-28 13:15:30 -07:00
parent f9b2b0c0aa
commit 1511831b0d
2 changed files with 9 additions and 13 deletions

View File

@ -232,25 +232,17 @@ public class RangeEvent extends DelayedEvent {
if (owner instanceof Player) { if (owner instanceof Player) {
if (affectedMob instanceof Npc) { if (affectedMob instanceof Npc) {
Npc npc = (Npc) affectedMob; Npc npc = (Npc) affectedMob;
npc.getSyndicate().distributeExp(npc); npc.getSyndicate().distributeExp(npc);
} }
} }
} else { } else {
if (owner instanceof Player && affectedMob instanceof Npc) // We're // We're ranging an NPC, so make it chase the player.
// ranging if (owner instanceof Player && affectedMob instanceof Npc) {
// an
// NPC,
// so
// make
// it
// chase
// the
// player.
{
final Npc npc = (Npc) affectedMob; final Npc npc = (Npc) affectedMob;
final Player player = (Player) owner; final Player player = (Player) owner;
player.getActionSender().sendMessage("affectedMob = npc");
if (npc.isBusy() || npc.getChasing() != null) if (npc.isBusy() || npc.getChasing() != null)
return; return;
@ -268,6 +260,7 @@ public class RangeEvent extends DelayedEvent {
this.stop(); this.stop();
return; return;
} }
player.getActionSender().sendMessage("WalkMobToMobEvent finish");
npc.resetPath(); npc.resetPath();
player.setBusy(true); player.setBusy(true);

View File

@ -233,6 +233,9 @@ public class PlayerLogin implements PacketHandler {
player.getInventory().add(new InvItem(156)); player.getInventory().add(new InvItem(156));
player.getInventory().add(new InvItem(87)); player.getInventory().add(new InvItem(87));
player.getInventory().add(new InvItem(1263)); player.getInventory().add(new InvItem(1263));
//189 + 11 = Range Testing.
player.getInventory().add(new InvItem(189));
player.getInventory().add(new InvItem(11, 100));
player.getActionSender().sendInventory(); player.getActionSender().sendInventory();
player.setChangingAppearance(true); player.setChangingAppearance(true);
sender.sendAppearanceScreen(); sender.sendAppearanceScreen();