Set last server position when player is restored.
This commit is contained in:
@ -6655,7 +6655,11 @@ public final class L2PcInstance extends L2Playable
|
||||
CursedWeaponsManager.getInstance().checkPlayer(player);
|
||||
|
||||
// Set the x,y,z position of the L2PcInstance and make it invisible
|
||||
player.setXYZInvisible(rset.getInt("x"), rset.getInt("y"), rset.getInt("z"));
|
||||
final int x = rset.getInt("x");
|
||||
final int y = rset.getInt("y");
|
||||
final int z = rset.getInt("z");
|
||||
player.setXYZInvisible(x, y, z);
|
||||
player.setLastServerPosition(x, y, z);
|
||||
|
||||
// Set Teleport Bookmark Slot
|
||||
player.setBookMarkSlot(rset.getInt("BookmarkSlot"));
|
||||
|
@ -84,6 +84,7 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
||||
if ((_targetX == _originX) && (_targetY == _originY) && (_targetZ == _originZ))
|
||||
{
|
||||
activeChar.sendPacket(new StopMove(activeChar));
|
||||
activeChar.sendPacket(ActionFailed.STATIC_PACKET);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -91,6 +92,7 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
||||
if (DoorData.getInstance().checkIfDoorsBetween(activeChar.getX(), activeChar.getY(), activeChar.getZ(), _targetX, _targetY, _targetZ, activeChar.getInstanceWorld(), false))
|
||||
{
|
||||
activeChar.stopMove(activeChar.getLastServerPosition());
|
||||
activeChar.sendPacket(ActionFailed.STATIC_PACKET);
|
||||
return;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user