Class SearchlightAttackAction

All Implemented Interfaces:
Serializable, AttackAction, EntityAction

public class SearchlightAttackAction extends AbstractAttackAction
Used for aiming a searchlight at a target.
See Also:
  • Constructor Details

    • SearchlightAttackAction

      public SearchlightAttackAction(int entityId, int targetId)
    • SearchlightAttackAction

      public SearchlightAttackAction(int entityId, int targetType, int targetId)
  • Method Details

    • isPossible

      public boolean isPossible(Game game)
    • isPossible

      public static boolean isPossible(Game game, int attackerId, Targetable target, SearchlightAttackAction exempt)
    • resolveAction

      public Vector<Report> resolveAction(Game game)
      illuminate an entity and all entities that are between us and the hex
    • setHexesIlluminated

      public boolean setHexesIlluminated(Game game)
      Updates the supplied Game's list of hexes illuminated.
      Parameters:
      game - The Game to update
      Returns:
      True if new hexes were added, else false.
    • willIlluminate

      public boolean willIlluminate(Game game, Entity who)
    • toSummaryString

      public String toSummaryString(Game game)
      Description copied from interface: EntityAction
      Returns a short one-line description of the action that is used in the UI, e.g. on attack arrows in the BoardView and in the action summary in TurnDetailsOverlay.
      Parameters:
      game - The game object to get information from
      Returns:
      A short String describing the action
      See Also: