Creature X and Y coordinates should not be both set to 0.

This commit is contained in:
MobiusDevelopment
2022-06-16 12:55:51 +00:00
parent 5ddfd00226
commit 4e80b14780
26 changed files with 156 additions and 0 deletions

View File

@@ -5403,6 +5403,12 @@ public abstract class Creature extends WorldObject implements ISkillsHolder, IDe
@Override
public void setXYZ(int newX, int newY, int newZ)
{
// 0, 0 is not a valid location.
if ((newX == 0) && (newY == 0))
{
return;
}
final ZoneRegion oldZoneRegion = ZoneManager.getInstance().getRegion(this);
final ZoneRegion newZoneRegion = ZoneManager.getInstance().getRegion(newX, newY);