cmd.addStep(MovePath.STEP_ACC, true);
}
cmd.addStep(MovePath.STEP_DOWN);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_CLIMB_MODE)) {
MoveStep ms = cmd.getLastStep();
if ((ms != null) && ((ms.getType() == MovePath.STEP_CLIMB_MODE_ON) || (ms.getType() == MovePath.STEP_CLIMB_MODE_OFF))) {
cmd.removeLastStep();
} else if (cmd.getFinalClimbMode()) {
cmd.addStep(MovePath.STEP_CLIMB_MODE_OFF);
} else {
cmd.addStep(MovePath.STEP_CLIMB_MODE_ON);
}
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_LAY_MINE)) {
int i = chooseMineToLay();
if (i != -1) {
Mounted m = ce().getEquipment(i);
if (m.getMineType() == Mounted.MINE_VIBRABOMB) {
VibrabombSettingDialog vsd = new VibrabombSettingDialog(clientgui.frame);
vsd.setVisible(true);
m.setVibraSetting(vsd.getSetting());
}
cmd.addStep(MovePath.STEP_LAY_MINE, i);
clientgui.bv.drawMovementData(ce, cmd);
}
} else if (ev.getActionCommand().equals(MOVE_DIG_IN)) {
cmd.addStep(MovePath.STEP_DIG_IN);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_FORTIFY)) {
cmd.addStep(MovePath.STEP_FORTIFY);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_SHAKE_OFF)) {
cmd.addStep(MovePath.STEP_SHAKE_OFF_SWARMERS);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_MODE_MECH)) {
clearAllMoves();
if (ce instanceof LandAirMech) {
final LandAirMech lam = (LandAirMech) client.getEntity(ce.getId());
lam.convertToMode(LandAirMech.MODE_MECH);
updateTransformationButtons(lam);
clientgui.mechD.displayEntity(lam);
}
} else if (ev.getActionCommand().equals(MOVE_MODE_AIRMECH)) {
clearAllMoves();
if (ce instanceof LandAirMech) {
final LandAirMech lam = (LandAirMech) client.getEntity(ce.getId());
lam.convertToMode(LandAirMech.MODE_AIRMECH);
updateTransformationButtons(lam);
clientgui.mechD.displayEntity(lam);
}
} else if (ev.getActionCommand().equals(MOVE_MODE_AIRCRAFT)) {
clearAllMoves();
if (ce instanceof LandAirMech) {
final LandAirMech lam = (LandAirMech) client.getEntity(ce.getId());
lam.convertToMode(LandAirMech.MODE_AIRCRAFT);
updateTransformationButtons(lam);
clientgui.mechD.displayEntity(lam);
}
} else if (ev.getActionCommand().equals(MOVE_RECKLESS)) {
cmd.setCareful(false);
} else if (ev.getActionCommand().equals(MOVE_ACCN)) {
cmd.addStep(MovePath.STEP_ACCN);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_DECN)) {
cmd.addStep(MovePath.STEP_DECN);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_ACC)) {
cmd.addStep(MovePath.STEP_ACC);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_DEC)) {
cmd.addStep(MovePath.STEP_DEC);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_EVADE)) {
cmd.addStep(MovePath.STEP_EVADE);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_EVADE_AERO)) {
cmd.addStep(MovePath.STEP_EVADE);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_ROLL)) {
cmd.addStep(MovePath.STEP_ROLL);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_HOVER)) {
cmd.addStep(MovePath.STEP_HOVER);
clientgui.bv.drawMovementData(ce, cmd);
} else if (ev.getActionCommand().equals(MOVE_MANEUVER)) {
ManeuverChoiceDialog choiceDialog = new ManeuverChoiceDialog(clientgui.frame, Messages.getString("MovementDisplay.ManeuverDialog.title"), //$NON-NLS-1$
"huh?");
Aero a = (Aero) ce;
MoveStep last = cmd.getLastStep();
int vel = a.getCurrentVelocity();
int elev = a.getElevation();
Coords pos = a.getPosition();
int distance = 0;
if (null != last) {
vel = last.getVelocityLeft();
elev = last.getElevation();
pos = last.getPosition();
distance = last.getDistance();
}
int ceil = client.game.getBoard().getHex(pos).ceiling();
choiceDialog.checkPerformability(vel, elev, ceil, a.isVSTOL(), distance);
choiceDialog.setVisible(true);
int manType = choiceDialog.getChoice();