Protection for ship launches (#355)
In case where ship is too big for a dock and can't be launched.master
parent
58349ee0c1
commit
95ab3d4a39
|
@ -2361,7 +2361,11 @@ this._addShips = function(role,num,pos,spread)
|
|||
var result = [];
|
||||
for (var i = 0 ; i < num ; i++)
|
||||
{
|
||||
result.push(pos.launchShipWithRole(role));
|
||||
let ship = pos.launchShipWithRole(role);
|
||||
if( ship )
|
||||
{
|
||||
result.push(ship);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue