Chase functionality (/c name) to warp to the exact location of the target

This commit is contained in:
RubenD96
2021-04-22 22:03:59 +02:00
parent f6452b2320
commit ade50bad5e
3 changed files with 23 additions and 3 deletions

View File

@@ -1037,7 +1037,12 @@ public class MaplePacketCreator {
mplew.writeInt(to.getId());
mplew.write(spawnPoint);
mplew.writeShort(chr.getHp());
mplew.writeBool(false);
mplew.writeBool(chr.isChasing());
if (chr.isChasing()) {
chr.setChasing(false);
mplew.writeInt(chr.getPosition().x);
mplew.writeInt(chr.getPosition().y);
}
mplew.writeLong(getTime(Server.getInstance().getCurrentTime()));
return mplew.getPacket();
}