Class TurretFacingDialog

All Implemented Interfaces:
ActionListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, RootPaneContainer, WindowConstants

public class TurretFacingDialog extends JDialog implements ActionListener
See Also:
  • Constructor Details

    • TurretFacingDialog

      public TurretFacingDialog(JFrame parent, Mek mek, Mounted<?> turret, ClientGUI clientgui)
    • TurretFacingDialog

      public TurretFacingDialog(JFrame parent, Tank tank, ClientGUI clientgui)
    • TurretFacingDialog

      public TurretFacingDialog(JFrame parent, Tank tank, ClientGUI clientgui, IntConsumer facingConsumer)
      Facing picker for a vehicle's main turret, whose rotation is a turret twist - the turret follows the unit's secondary facing. The dialog only picks the facing: the chosen facing is handed to facingConsumer, which declares the twist through the attack display (clearing pending attacks like any other twist). On a dual-turret vehicle this is the rear turret; the front turret uses TurretFacingDialog(JFrame, Tank, ClientGUI).
      Parameters:
      parent - the parent frame
      tank - the vehicle whose main turret is being rotated
      clientgui - the client GUI, used for the unit preview image
      facingConsumer - receives the chosen absolute facing (0-5) when the player confirms
    • TurretFacingDialog

      public TurretFacingDialog(JFrame parent, Mek mek, WeaponMounted directionalMountWeapon, ClientGUI clientgui, boolean isDirectionalMount)
      Facing picker for a Directional Torso Mount (BMM p.83). The 2-point mount allows only the forward and rear facings; the 3-point quad turret allows all six. Reuses the same six-facing layout as the turret dialogs.
      Parameters:
      parent - the parent frame
      mek - the unit carrying the mount
      directionalMountWeapon - the weapon whose mount facing is being set
      clientgui - the client GUI, used to send the facing change and refresh the firing arc
      isDirectionalMount - marker distinguishing this from the mek-turret constructor; always true
  • Method Details