megamek.common.actions
Class KickAttackAction

java.lang.Object
  extended by megamek.common.actions.AbstractEntityAction
      extended by megamek.common.actions.AbstractAttackAction
          extended by megamek.common.actions.PhysicalAttackAction
              extended by megamek.common.actions.KickAttackAction
All Implemented Interfaces:
java.io.Serializable, AttackAction, EntityAction

public class KickAttackAction
extends PhysicalAttackAction

The attacker kicks the target.

See Also:
Serialized Form

Field Summary
static int BOTH
           
static int LEFT
           
static int LEFTMULE
           
static int RIGHT
           
static int RIGHTMULE
           
 
Constructor Summary
KickAttackAction(int entityId, int targetId, int leg)
           
KickAttackAction(int entityId, int targetType, int targetId, int leg)
           
 
Method Summary
static int getDamageFor(Entity entity, int leg, boolean targetInfantry)
          Damage that the specified mech does with a kick
 int getLeg()
           
 void setLeg(int leg)
           
 ToHitData toHit(IGame game)
           
static ToHitData toHit(IGame game, int attackerId, Targetable target, int leg)
          To-hit number for the specified leg to kick
 
Methods inherited from class megamek.common.actions.PhysicalAttackAction
setCommonModifiers, toHitIsImpossible
 
Methods inherited from class megamek.common.actions.AbstractAttackAction
getEntity, getTarget, getTargetId, getTargetType, nightModifiers, setTargetId, setTargetType
 
Methods inherited from class megamek.common.actions.AbstractEntityAction
getEntityId, setEntityId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface megamek.common.actions.EntityAction
getEntityId, setEntityId
 

Field Detail

BOTH

public static final int BOTH
See Also:
Constant Field Values

LEFT

public static final int LEFT
See Also:
Constant Field Values

RIGHT

public static final int RIGHT
See Also:
Constant Field Values

LEFTMULE

public static final int LEFTMULE
See Also:
Constant Field Values

RIGHTMULE

public static final int RIGHTMULE
See Also:
Constant Field Values
Constructor Detail

KickAttackAction

public KickAttackAction(int entityId,
                        int targetId,
                        int leg)

KickAttackAction

public KickAttackAction(int entityId,
                        int targetType,
                        int targetId,
                        int leg)
Method Detail

getLeg

public int getLeg()

setLeg

public void setLeg(int leg)

getDamageFor

public static int getDamageFor(Entity entity,
                               int leg,
                               boolean targetInfantry)
Damage that the specified mech does with a kick


toHit

public ToHitData toHit(IGame game)

toHit

public static ToHitData toHit(IGame game,
                              int attackerId,
                              Targetable target,
                              int leg)
To-hit number for the specified leg to kick