Fixed #11690
This commit is contained in:
@@ -214,7 +214,9 @@ public class CommandAI extends AIController{
|
||||
}
|
||||
}
|
||||
|
||||
if(!net.client() && command == UnitCommand.enterPayloadCommand && unit.buildOn() != null && (targetPos == null || (world.buildWorld(targetPos.x, targetPos.y) != null && world.buildWorld(targetPos.x, targetPos.y) == unit.buildOn()))){
|
||||
if(!net.client() && command == UnitCommand.enterPayloadCommand && unit.type.allowedInPayloads && unit.buildOn() != null &&
|
||||
(targetPos == null || (world.buildWorld(targetPos.x, targetPos.y) != null && world.buildWorld(targetPos.x, targetPos.y) == unit.buildOn()))){
|
||||
|
||||
var build = unit.buildOn();
|
||||
tmpPayload.unit = unit;
|
||||
if(build.team == unit.team && build.acceptPayload(build, tmpPayload)){
|
||||
|
||||
@@ -1066,7 +1066,11 @@ public class UnitType extends UnlockableContent implements Senseable{
|
||||
//assign default commands.
|
||||
if(commands.size == 0){
|
||||
|
||||
commands.add(UnitCommand.moveCommand, UnitCommand.enterPayloadCommand);
|
||||
commands.add(UnitCommand.moveCommand);
|
||||
|
||||
if(allowedInPayloads){
|
||||
commands.add(UnitCommand.enterPayloadCommand);
|
||||
}
|
||||
|
||||
if(canBoost){
|
||||
commands.add(UnitCommand.boostCommand);
|
||||
|
||||
Reference in New Issue
Block a user