will prevent messing with ship's dimensions

This commit is contained in:
drpepper240 2014-07-13 21:59:49 +04:00
parent 2f9735c428
commit 3cb47ff6b2

View file

@ -472,10 +472,11 @@ System.out.println("ZLO7");
this.shipSize = this.shipDown + this.shipUp;
break;
}
// Ship side is too big
if (shipLength > WarpDriveConfig.i.WC_MAX_SHIP_SIDE || shipWidth > WarpDriveConfig.i.WC_MAX_SHIP_SIDE || shipHeight > WarpDriveConfig.i.WC_MAX_SHIP_SIDE)
// Ship size is too big
if (this.shipSize + 1 > WarpDriveConfig.i.WC_MAX_SHIP_SIDE)
{
messageToAllPlayersOnShip("Ship is too long. Cannot jump.");
this.controller.setJumpFlag(false);
return false;
}