Fixed #2662
This commit is contained in:
@@ -98,7 +98,11 @@ abstract class PayloadComp implements Posc, Rotc, Hitboxc, Unitc{
|
|||||||
Unit u = payload.unit;
|
Unit u = payload.unit;
|
||||||
|
|
||||||
//can't drop ground units
|
//can't drop ground units
|
||||||
if(((tileOn() == null || tileOn().solid()) && u.elevation < 0.1f) || (!floorOn().isLiquid && u instanceof WaterMovec)){
|
//TODO bad code, solidity should not be handled this way
|
||||||
|
if(
|
||||||
|
((tileOn() == null || tileOn().solid()) && u.elevation < 0.1f && !u.type().allowLegStep) ||
|
||||||
|
(!floorOn().isLiquid && u instanceof WaterMovec) ||
|
||||||
|
(u.type().allowLegStep && EntityCollisions.legsSolid(u.tileX(), u.tileY()))){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -105,7 +105,7 @@ public class Build{
|
|||||||
int wx = dx + offsetx + x, wy = dy + offsety + y;
|
int wx = dx + offsetx + x, wy = dy + offsety + y;
|
||||||
|
|
||||||
Tile check = world.tile(wx, wy);
|
Tile check = world.tile(wx, wy);
|
||||||
if(check == null || (!check.block.alwaysReplace && check.block != tile.block && !(check.block.size == 1 && type.canReplace(check.block)))) return false;
|
if(check == null || !check.interactable(team) || (!check.block.alwaysReplace && check.block != tile.block && !(check.block.size == 1 && type.canReplace(check.block)))) return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user