|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmegamek.common.TurnOrdered
megamek.common.Entity
public abstract class Entity
Entity is a master class for basically anything on the board except terrain.
| Nested Class Summary | |
|---|---|
class |
Entity.EntityFluff
|
| Field Summary | |
|---|---|
protected boolean |
_isEMId
|
protected int |
altitude
altitude is different from elevation. |
protected java.util.ArrayList<Mounted> |
ammoList
A list of all mounted ammo. |
protected int |
armorTechLevel
|
protected int |
armorType
|
protected boolean |
armsFlipped
|
ArtilleryTracker |
aTracker
|
protected java.lang.StringBuffer |
battleForceDebugString
|
static int |
BATTLEFORCEEXTREMERANGE
|
static int |
BATTLEFORCELONGRANGE
|
static int |
BATTLEFORCEMEDIUMRANGE
|
protected double[] |
battleForceMinRangeModifier
|
static int |
BATTLEFORCESHORTRANGE
|
protected double[] |
battleForceToHitModifier
|
protected java.util.ArrayList<Mounted> |
bombList
A list of all mounted bombs. |
protected java.lang.StringBuffer |
bvText
|
protected int |
c3CompanyMasterIndex
|
protected int |
c3Master
|
protected java.lang.String |
c3NetIdString
|
protected boolean |
canUnstickByJumping
|
protected boolean |
carcass
|
protected java.lang.String |
chassis
|
Pilot |
crew
The pilot of the entity. |
protected CriticalSlot[][] |
crits
This matrix stores critical slots in the format [location][slot #]. |
int |
damageThisPhase
|
int |
damageThisRound
|
protected boolean |
DEBUGBATTLEFORCE
|
int |
delta_distance
|
protected boolean |
designValid
|
protected boolean |
destroyed
|
protected DisplacementAttackAction |
displacementAttack
|
protected java.lang.String |
displayName
|
boolean |
dodging
|
protected boolean |
done
|
protected boolean |
doomed
|
int |
duplicateMarker
|
protected int |
elevation
this is the elevation of the Entity--with respect to the surface of the hex it's in. |
protected java.lang.String |
endColumn
|
protected java.lang.String |
endRow
|
protected java.lang.String |
endTable
|
protected Engine |
engine
|
int |
engineHitsThisRound
|
protected java.util.ArrayList<Mounted> |
equipmentList
A list of all mounted equipment. |
protected int |
externalId
ID settable by external sources (such as mm.net) |
protected int |
facing
|
protected java.util.ArrayList<java.lang.String> |
failedEquipmentList
|
protected boolean |
findingClub
|
protected Entity.EntityFluff |
fluff
|
protected IGame |
game
|
boolean |
gotPavementBonus
|
static int |
GRAPPLE_BOTH
|
static int |
GRAPPLE_LEFT
|
static int |
GRAPPLE_RIGHT
|
protected boolean |
hasSpotlight
|
int |
heat
|
int |
heatBuildup
|
int |
heatFromExternal
|
protected int |
heatSinkCoolantFailureFactor
|
boolean |
hitThisRoundByAntiTSM
|
protected boolean |
hullDown
|
protected int |
id
|
protected boolean |
illuminated
|
protected java.util.ArrayList<INarcPod> |
iNarcPods
|
InfernoTracker |
infernos
The object that tracks this unit's Inferno round hits. |
boolean |
inReverse
|
protected boolean |
isCarefulStanding
|
protected boolean |
isHidden
|
protected int |
jumpMP
|
protected int |
killerId
|
protected int |
lastTarget
|
protected boolean |
layingMines
|
static int |
LOC_DESTROYED
|
static int |
LOC_NONE
|
protected long |
m_lNarcedBy
|
protected long |
m_lPendingNarc
|
static int |
MAX_C3_NODES
|
protected java.util.ArrayList<Mounted> |
miscList
A list of all remaining equipment. |
protected boolean |
mixedTech
|
protected java.lang.String |
model
|
EntityMovementType |
moved
|
protected EntityMovementMode |
movementMode
Stores the current movement mode. |
int |
mpUsed
|
protected int |
mpUsedLastRound
|
protected java.util.ArrayList<NarcPod> |
narcPods
|
protected java.lang.String |
nl
|
static int |
NONE
|
protected boolean |
omni
|
protected Player |
owner
|
protected int |
ownerId
|
protected java.util.ArrayList<INarcPod> |
pendingINarcPods
|
protected java.util.ArrayList<NarcPod> |
pendingNarcPods
|
protected Coords |
position
|
protected boolean |
prone
|
boolean |
reckless
|
boolean |
rolledForEngineExplosion
|
protected int |
sec_facing
|
protected java.util.Map<java.lang.Integer,Coords> |
secondaryPositions
|
protected java.lang.String |
shortName
|
protected boolean |
shutDown
|
protected boolean |
shutdownByBATaser
|
protected boolean |
shutDownThisPhase
|
protected java.lang.String |
source
|
protected boolean |
spotlightIsActive
|
boolean |
spotting
|
protected java.lang.String |
startColumn
|
protected java.lang.String |
startRow
|
protected java.lang.String |
startTable
|
protected int |
structureType
|
protected boolean |
stuckInSwamp
|
protected int |
taggedBy
|
protected int |
taserFeedBackRounds
|
protected int |
taserInterference
|
protected int |
taserInterferenceRounds
|
protected int |
taserShutdownRounds
|
protected int |
techLevel
|
TeleMissileTracker |
tmTracker
|
protected java.util.ArrayList<Mounted> |
totalWeaponList
A list of every weapon mount, including bay mounts and weapon group mounts |
protected boolean |
unjammingRAC
|
protected boolean |
usedSearchlight
|
protected int[] |
vectors
|
protected int |
walkMP
|
protected java.util.ArrayList<Mounted> |
weaponBayList
A list of all mounted weapon bays |
protected java.util.ArrayList<Mounted> |
weaponGroupList
A list of all mounted weapon groups |
protected java.util.ArrayList<Mounted> |
weaponList
A list of all mounted weapons. |
protected float |
weight
|
protected int |
year
|
| Fields inherited from interface megamek.common.Targetable |
|---|
TYPE_BLDG_IGNITE, TYPE_BUILDING, TYPE_ENTITY, TYPE_FLARE_DELIVER, TYPE_FUEL_TANK, TYPE_FUEL_TANK_IGNITE, TYPE_HEX_AERO_BOMB, TYPE_HEX_ARTILLERY, TYPE_HEX_BOMB, TYPE_HEX_CLEAR, TYPE_HEX_EXTINGUISH, TYPE_HEX_IGNITE, TYPE_HEX_SCREEN, TYPE_INARC_POD, TYPE_MINEFIELD_CLEAR, TYPE_MINEFIELD_DELIVER, TYPE_SEARCHLIGHT |
| Constructor Summary | |
|---|---|
Entity()
Generates a new, blank, entity. |
|
| Method Summary | |
|---|---|
int |
absHeight()
Returns the absolute height of the entity |
Mounted |
addBomb(EquipmentType etype,
int loc)
indicate whether this is a bomb mount |
protected void |
addBomb(Mounted mounted,
int loc)
|
PilotingRollData |
addConditionBonuses(PilotingRollData roll,
EntityMovementType moveType)
Add in any modifiers due to global conditions like light/weather/etc. |
void |
addCoolantFailureAmount(int amount)
|
boolean |
addCritical(int loc,
CriticalSlot cs)
Adds a critical to the first available slot in the location. |
boolean |
addCritical(int loc,
int slot,
CriticalSlot cs)
Attempts to set the given slot to the given critical. |
abstract PilotingRollData |
addEntityBonuses(PilotingRollData roll)
Add in any piloting skill mods |
Mounted |
addEquipment(EquipmentType etype,
int loc)
Creates a new mount for this equipment and adds it in. |
Mounted |
addEquipment(EquipmentType etype,
int loc,
boolean rearMounted)
Creates a new mount for this equipment and adds it in. |
Mounted |
addEquipment(EquipmentType etype,
int loc,
boolean rearMounted,
boolean bodyMounted)
indicate whether this is bodymounted for BAs |
Mounted |
addEquipment(EquipmentType etype,
int loc,
boolean rearMounted,
boolean bodyMounted,
boolean isArmored)
Creates a new mount for this equipment and adds it in. |
Mounted |
addEquipment(EquipmentType etype,
int loc,
boolean rearMounted,
int nAmmo)
mounting weapons needs to take account of ammo |
protected void |
addEquipment(Mounted mounted,
int loc,
boolean rearMounted)
|
protected void |
addEquipment(Mounted mounted,
int loc,
boolean rearMounted,
boolean isWeaponGroup)
|
protected void |
addEquipment(Mounted mounted,
int loc,
boolean rearMounted,
int nAmmo)
|
void |
addFailedEquipment(java.lang.String s)
|
void |
addKill(Entity kill)
|
void |
addPassedThrough(Coords c)
|
void |
addPilotingModifierForTerrain(PilotingRollData roll)
Apply PSR modifier for difficult terrain in the current position |
void |
addPilotingModifierForTerrain(PilotingRollData roll,
Coords c)
Apply PSR modifier for difficult terrain at the specified coordinates |
void |
addPilotingModifierForTerrain(PilotingRollData roll,
MoveStep step)
Apply PSR modifier for difficult terrain at the move step position |
void |
addTargetedBySwarm(int entityId,
int weaponId)
Add a targeting by a swarm volley from a specified entity |
void |
addTransporter(Transporter component)
Add a transportation component to this Entity. |
Mounted |
addWeaponGroup(EquipmentType etype,
int loc)
|
void |
applyDamage()
Applies any damage that the entity has suffered. |
protected int |
applyGravityEffectsOnMP(int MP)
|
void |
applySantaAnna()
Apply any pending Santa Anna allocations to Killer Whale ammo bins effectively "splitting" the ammo bins in two This is a hack that I should really creat a general method of "splitting" ammo bins for |
static java.lang.String |
armorStringFor(int value)
Parses the game's internal armor representation into a human-readable string. |
void |
assignAMS(java.util.Vector<WeaponHandler> vAttacks)
Assign AMS systems to the most dangerous incoming missile attacks. |
void |
attachINarcPod(INarcPod pod)
attach an iNarcPod |
void |
attachNarcPod(NarcPod pod)
add a narc pod from this team to the mech. |
abstract void |
autoSetInternal()
Set the internal structure to the appropriate value for the mech's weight class |
void |
baTaserShutdown(int turns)
shut this unit down due to a BA Taser attack |
boolean |
C3MasterIs(Entity e)
Determines if the passed Entity is the C3 Master of this
unit. |
int |
calcElevation(IHex current,
IHex next)
|
int |
calcElevation(IHex current,
IHex next,
int assumedElevation,
boolean climb,
boolean wigeEndClimbPrevious)
A helper function for fiddling with elevation. |
abstract int |
calculateBattleValue()
Calculates the battle value of this entity |
int |
calculateBattleValue(boolean ignoreC3,
boolean ignorePilot)
Calculates the battle value of this mech. |
int |
calculateFreeC3MNodes()
Determine the remaining number of other C3 Master computers that can connect to this Entity. |
int |
calculateFreeC3Nodes()
Determine the remaining number of other C3 computers that can connect to this Entity. |
boolean |
canAssaultDrop()
|
boolean |
canAssist(IGame.Phase phase)
Determines if an entity is eligible for a phase. |
abstract boolean |
canChangeSecondaryFacing()
Can this entity change secondary facing at all? |
boolean |
canCharge()
Whether this type of unit can perform charges |
boolean |
canDFA()
Whether this type of unit can perform DFA attacks |
boolean |
canFlee()
Returns whether an entity can flee from its current position. |
boolean |
canFlipArms()
Returns true if the entity can flip its arms |
boolean |
canGoDown()
|
boolean |
canGoDown(int assumedElevation,
Coords assumedPos)
is it possible to go down, or are we landed/just above the water/treeline? |
boolean |
canGoHullDown()
|
boolean |
canGoUp(int assumedElevation,
Coords assumedPos)
is it possible to go up, or are we at maximum altitude? |
boolean |
canLayMine()
|
boolean |
canLoad(Entity unit)
Determines if this object can accept the given unit. |
boolean |
canLoad(Entity unit,
boolean checkElev)
Determines if this object can accept the given unit. |
boolean |
canRam()
Whether this type of unit can perform Ramming attacks |
boolean |
canSpot()
Um, basically everything can spot for LRM indirect fire. |
boolean |
canTransferCriticals(int loc)
Returns true if this location should transfer criticals to the next location inwards. |
boolean |
canUnjamRAC()
Returns true if the entity has an RAC which is jammed and not destroyed |
boolean |
canUnstickByJumping()
Is the Entity stuck in a swamp? |
PilotingRollData |
checkBogDown(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos,
int lastElev,
boolean isPavementStep)
Checks if the entity is moving into a hex that might cause it to bog down. |
PilotingRollData |
checkDislodgeSwarmers(MoveStep step)
Checks if the entity is being swarmed. |
PilotingRollData |
checkGetUp(MoveStep step)
Checks if the entity is getting up. |
PilotingRollData |
checkLandingInHeavyWoods(EntityMovementType overallMoveType,
IHex curHex)
Checks if an entity is landing (from a jump) in heavy woods. |
PilotingRollData |
checkLandingOnIce(EntityMovementType overallMoveType,
IHex curHex)
Checks if the entity is landing (from a jump) on ice-covered water. |
PilotingRollData |
checkLandingWithDamage(EntityMovementType overallMoveType)
Checks if the entity is landing (from a jump) with damage that would force a PSR. |
PilotingRollData |
checkMovedTooFast(MoveStep step)
return a PilotingRollData checking for wether this Entity
moved too fast due to low gravity |
int |
checkMovementInBuilding(MoveStep step,
MoveStep prevStep,
Coords curPos,
Coords prevPos)
Checks to see if an entity is moving through building walls. |
PilotingRollData |
checkRecklessMove(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos,
IHex prevHex)
Checks if an entity is passing through certain terrain while not moving carefully |
PilotingRollData |
checkRubbleMove(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos)
Checks if the entity is moving into rubble. |
PilotingRollData |
checkRunningWithDamage(EntityMovementType overallMoveType)
Checks if the entity is attempting to run with damage that would force a PSR. |
PilotingRollData |
checkSideSlip(EntityMovementType moveType,
IHex prevHex,
EntityMovementType overallMoveType,
MoveStep prevStep,
int prevFacing,
int curFacing,
Coords lastPos,
Coords curPos,
int distance)
|
PilotingRollData |
checkSkid(EntityMovementType moveType,
IHex prevHex,
EntityMovementType overallMoveType,
MoveStep prevStep,
int prevFacing,
int curFacing,
Coords lastPos,
Coords curPos,
boolean isInfantry,
int distance)
Checks if the entity might skid on pavement. |
PilotingRollData |
checkSprintingWithMASC(EntityMovementType overallMoveType,
int used)
Checks if the entity is attempting to sprint with MASC engaged. |
PilotingRollData |
checkSprintingWithSupercharger(EntityMovementType overallMoveType,
int used)
Checks if the entity is attempting to sprint with supercharger engaged. |
void |
checkUnstall(java.util.Vector<Report> vPhaseReport)
check for unstalling of this Entity's engine (only used for ICE industrial Mechs) |
PilotingRollData |
checkWaterMove(int waterLevel,
EntityMovementType overallMoveType)
Checks if the entity is moving into depth 1+ water. |
PilotingRollData |
checkWaterMove(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos,
boolean isPavementStep)
Checks if the entity is moving into depth 1+ water. |
int |
chooseSide(Coords attackPos,
boolean usePrior)
|
void |
clearQuirks()
|
boolean |
climbMode()
|
abstract int |
clipSecondaryFacing(int dir)
Returns the closest valid secondary facing to the given direction. |
int |
countQuirks()
count all the quirks for this unit, positive and negative |
int |
countQuirks(java.lang.String grpKey)
count the quirks for this unit, for a given group name |
int |
countWorkingMisc(java.math.BigInteger flag)
return how many misc equipments with the specified flag the unit has |
java.lang.String |
damageBayDoor()
Damages a randomly determined bay door on the entity, if one exists |
boolean |
damageDockCollar()
Damages a randomly determined docking collar on the entity, if one exists |
void |
damageDoorRecovery(Entity en)
damage the door of the first bay that can load this unit |
static void |
decodeTransporters(Entity entity,
java.lang.String transporters)
Set the Transporters for the given Entity. |
void |
deployOffBoard()
Deploy this offboard entity at the previously specified distance and direction. |
java.lang.String |
destroy(java.lang.String reason,
boolean survivable,
boolean canSalvage)
|
void |
destroyLocation(int loc)
Marks all equipment in a location on this entity as destroyed. |
void |
destroyRetractableBlade(int loc)
destroys the first retractable blade critical slot found |
java.util.Vector<Report> |
doCheckEngineStallRoll(java.util.Vector<Report> vPhaseReport)
possibly do a ICE-Engine stall PSR, only industrialmechs will actually do such a roll |
abstract boolean |
doomedInAtmosphere()
|
abstract boolean |
doomedInSpace()
|
abstract boolean |
doomedInVacuum()
|
abstract boolean |
doomedOnGround()
|
int |
elevationOccupied(IHex hex)
Returns the elevation that this entity would be on if it were placed into the specified hex. |
static java.lang.String |
encodeTransporters(Entity entity)
Get a list of the class names of the Transporters for the
given Entity. |
boolean |
entityIsBiped()
Helper function to determine if a entity is a biped |
boolean |
entityIsQuad()
Helper function to determine if a entity is a quad |
boolean |
equals(java.lang.Object object)
Two entities are equal if their ids are equal |
void |
extendBlade(int loc)
Set the retractable blade in the given location as extended Takes the first piece of appropriate equipment |
DisplacementAttackAction |
findTargetedDisplacement()
Returns any known displacement attacks (should only be one) that this entity is a target of. |
boolean |
fixElevation()
defensively check and correct elevation |
void |
generateDisplayName()
Generates the display name for this entity. |
void |
generateShortName()
Generate the short name for a unit Sub-classes are allowed to override this method. |
Sensor |
getActiveSensor()
|
int |
getActiveUMUCount()
This counts the number of UMU's a Mech has that are still viable |
int |
getActiveVibrobladeHeat(int location)
Checks to see if any heat is given off by an active vibro blade |
int |
getAllUMUCount()
This returns all UMU a mech has. |
int |
getAltitude()
|
java.util.ArrayList<Mounted> |
getAmmo()
|
int |
getArmor(HitData hit)
Returns the amount of armor in the location hit, or IArmorState.ARMOR_NA, or IArmorState.ARMOR_DESTROYED. |
int |
getArmor(int loc)
Returns the amount of armor in the location specified, or ARMOR_NA, or ARMOR_DESTROYED. |
int |
getArmor(int loc,
boolean rear)
Returns the amount of armor in the location specified, or IArmorState.ARMOR_NA, or IArmorState.ARMOR_DESTROYED. |
double |
getArmorRemainingPercent()
Returns the percent of the armor remaining |
java.lang.String |
getArmorString(int loc)
Returns a string representing the armor in the location |
java.lang.String |
getArmorString(int loc,
boolean rear)
Returns a string representing the armor in the location |
int |
getArmorTechLevel()
|
int |
getArmorType()
|
double |
getArmorWeight()
|
boolean |
getArmsFlipped()
Returns true if the mech's arms are flipped to the rear |
int |
getBadCriticals(int type,
int index,
int loc)
The number of critical slots that are destroyed in the component. |
int |
getBAPRange()
What's the range of the BAP equipment? |
int |
getBARRating()
Return the BAR-rating of this Entity's armor |
PilotingRollData |
getBasePilotingRoll()
Returns an entity's base piloting skill roll needed Only use this version if the entity is through processing movement |
PilotingRollData |
getBasePilotingRoll(EntityMovementType moveType)
Returns an entity's base piloting skill roll needed |
int |
getBattleForceArmorPoints()
|
java.lang.String |
getBattleForceDamageThresholdString()
only used for Aerospace and Dropships |
long |
getBattleForceJumpPoints()
|
java.lang.String |
getBattleForceMovement()
Returns the Battle Force Movement string this is used in a battle force game |
long |
getBattleForceMovementPoints()
|
java.lang.String |
getBattleForceOverHeatValue()
|
int |
getBattleForcePoints()
Start of Battle Force Conversion Methods |
int |
getBattleForceSize()
|
java.lang.String |
getBattleForceSpecialAbilites()
|
int |
getBattleForceStandardWeaponsDamage(int range)
|
int |
getBattleForceStandardWeaponsDamage(int range,
boolean ignoreHeat,
boolean ignoreSpecialAbilities)
|
int |
getBattleForceStandardWeaponsDamage(int range,
int ammoType)
|
int |
getBattleForceStandardWeaponsDamage(int range,
int ammoType,
boolean ignoreHeat,
boolean ignoreSpecialAbilities)
|
int |
getBattleForceStructurePoints()
this will be unit specific |
int |
getBattleForceTotalHeatGeneration(boolean allowRear)
|
Mounted |
getBayByAmmo(Mounted mammo)
get the bay that ammo is associated with |
java.util.Vector<Entity> |
getBayLoadedUnits()
only entities in Bays (for cargo damage to Aero units |
int |
getBlueShieldRounds()
|
int[] |
getBombLoadout()
produce an int array of the number of bombs of each type based on the current bomblist |
java.util.ArrayList<Mounted> |
getBombs()
|
java.util.Vector<Mounted> |
getBombs(java.math.BigInteger flag)
|
java.lang.String |
getBVText()
Return a HTML string that describes the BV calculations |
Entity |
getC3Master()
Return the unit that is current master of this unit's C3 network. |
int |
getC3MasterId()
Get the ID of the master unit in this unit's C3 network. |
java.lang.String |
getC3NetId()
|
Entity |
getC3Top()
|
int |
getCargoMpReduction()
|
java.lang.String |
getChassis()
Returns the chassis name for this entity. |
java.util.List<Mounted> |
getClubs()
|
int |
getCoolantFailureAmount()
|
abstract double |
getCost(boolean ignoreAmmo)
|
Pilot |
getCrew()
|
CriticalSlot |
getCritical(int loc,
int slot)
Returns a critical hit slot |
int |
getDamageReductionFromModularArmor(int loc,
int damage,
java.util.Vector<Report> vDesc)
|
abstract int |
getDependentLocation(int loc)
Gets the location that is destroyed recursively. |
int |
getDeployRound()
The round the unit will be deployed |
DisplacementAttackAction |
getDisplacementAttack()
|
java.lang.String |
getDisplayName()
Returns the display name for this entity. |
int |
getDocks()
|
java.util.Vector<Entity> |
getDroppableUnits()
|
double |
getECCMStrength()
|
int |
getECMRange()
What's the range of the ECM equipment? |
double |
getECMStrength()
|
int |
getElevation()
Returns the elevation of this entity. |
int |
getEmptyCriticals(int loc)
Returns the number of empty critical slots in a location |
Engine |
getEngine()
|
abstract int |
getEngineCritHeat()
Returns extra heat generated by engine crits |
java.util.ArrayList<Mounted> |
getEquipment()
Returns an enumeration of all equipment |
Mounted |
getEquipment(int index)
Returns the equipment, specified by number |
int |
getEquipmentNum(Mounted mounted)
Returns the equipment number of the specified equipment, or -1 if equipment is not present. |
EquipmentType |
getEquipmentType(CriticalSlot cs)
|
int |
getEvasionBonus()
|
Entity |
getExteriorUnitAt(int loc,
boolean isRear)
If a unit is being transported on the outside of the transporter, it can suffer damage when the transporter is hit by an attack. |
int |
getExternalId()
this returns the external ID. |
java.util.ArrayList<Entity> |
getExternalUnits()
|
int |
getExtraCommGearTons()
|
int |
getExtremeRangeModifier()
|
int |
getFacing()
Returns the primary facing, or -1 if n/a |
java.util.Iterator<java.lang.String> |
getFailedEquipment()
Returns an enumeration which contains the name of each piece of equipment that failed to load. |
java.util.Vector<Bay> |
getFighterBays()
|
int |
getFighterLaunchRate()
|
Mounted |
getFirstBay(WeaponType wtype,
int loc,
boolean rearMount)
return the first bay of the right type in the right location with enough damage to spare |
int |
getFirstWeapon()
Returns the first ready weapon |
Entity.EntityFluff |
getFluff()
Returns the fluff for this entity. |
int |
getForwardArc()
Returns the forward firing arc for this entity - overrided by some units |
IGame |
getGame()
This returns the game this Entity belongs to. |
boolean |
getGaveKillCredit()
|
int |
getGhostTargetOverride()
|
int |
getGhostTargetRoll()
|
int |
getGhostTargetRollMoS()
|
int |
getGoodCriticals(CriticalSlot cs,
int loc)
Returns the number of operational critical slots of the specified type in the location |
int |
getGoodCriticals(int type,
int index,
int loc)
Returns the number of operational critical slots of the specified type in the location |
int |
getGrappled()
|
int |
getGrappleSide()
|
int |
getGyroType()
Only Mechs have Gyros but this helps keep the code a bit cleaner. |
java.util.Vector<java.lang.Integer> |
getHeading()
return the heading of the unit based on its active vectors if vectors are tied then return two headings |
abstract int |
getHeatCapacity()
Returns the amount of heat that the entity can sink each turn. |
abstract int |
getHeatCapacityWithWater()
Returns the amount of heat that the entity can sink each turn, factoring in whether the entity is standing in water. |
int |
getHeatFiringModifier()
Returns the modifier to weapons fire due to heat. |
int |
getHeatInArc(int location,
boolean rearMount)
|
int |
getHeatMPReduction()
This returns how much MP is removed due to heat |
int |
getHeight()
|
int |
getHitCriticals(int type,
int index,
int loc)
Number of slots doomed, missing or destroyed in a location |
int |
getHittableCriticals(int loc)
Returns the number of operational critical slots remaining in a location |
int |
getHQIniBonus()
|
int |
getId()
Returns the ID number of this Entity. |
java.util.Iterator<INarcPod> |
getINarcPodsAttached()
Get an Enumeration of INarcPods that are
attached to this entity. |
int |
getInternal(HitData hit)
Returns the amount of internal structure in the location hit. |
int |
getInternal(int loc)
Returns the amount of internal structure in the location specified, or ARMOR_NA, or ARMOR_DESTROYED. |
double |
getInternalRemainingPercent()
Returns the percent of the armor remaining |
java.lang.String |
getInternalString(int loc)
Returns a string representing the internal structure in the location |
int |
getJumpHeat(int movedMP)
get the heat generated by this Entity when jumping for a certain amount of MP |
int |
getJumpMP()
Returns this entity's current jumping MP, not effected by terrain, factored for gravity. |
int |
getJumpMP(boolean gravity)
return this entity's current jump MP, possibly affected by gravity |
int |
getJumpMPWithTerrain()
Returns this entity's current jumping MP, effected by terrain (like water.) |
int |
getJumpType()
|
int |
getKillNumber()
|
java.util.Enumeration<Entity> |
getKills()
|
int |
getLastTarget()
|
java.util.Vector<Entity> |
getLaunchableFighters()
|
java.util.Vector<Entity> |
getLaunchableSmallCraft()
|
Bay |
getLoadedBay(int bayID)
|
java.util.Vector<Entity> |
getLoadedFighters()
|
java.util.Vector<Entity> |
getLoadedSmallCraft()
|
java.util.List<Entity> |
getLoadedUnits()
Get a List of the units currently loaded into this payload. |
java.lang.String |
getLocationAbbr(HitData hit)
Returns the abbreviated name of the location specified. |
java.lang.String |
getLocationAbbr(int loc)
Returns the abbreviated name of the location specified. |
abstract java.lang.String[] |
getLocationAbbrs()
|
int |
getLocationFromAbbr(java.lang.String abbr)
Returns the location that the specified abbreviation indicates |
java.lang.String |
getLocationName(HitData hit)
Returns the name of the location specified. |
java.lang.String |
getLocationName(int loc)
Returns the name of the location specified. |
abstract java.lang.String[] |
getLocationNames()
|
int |
getLocationStatus(int loc)
returns exposure or breached flag for location |
int |
getLongRangeModifier()
|
abstract int |
getMaxElevationChange()
The maximum elevation change the entity can cross |
int |
getMaxElevationDown()
by default, entities can move as far down as they can move up |
int |
getMDIniBonus()
|
int |
getMediumRangeModifier()
|
java.util.ArrayList<Mounted> |
getMisc()
|
java.lang.String |
getModel()
Returns the unit code for this entity. |
abstract java.lang.String |
getMovementAbbr(EntityMovementType mtype)
Returns the abbreviation of the name of the type of movement used. |
int |
getMovementBeforeSkidPSRModifier(int distance)
Calculate the piloting skill roll modifier, based upon the number of hexes moved this phase. |
EntityMovementMode |
getMovementMode()
Get the movement mode of the entity |
java.lang.String |
getMovementModeAsBattleForceString()
Get the movement mode of the entity and return it as a battle force string. |
java.lang.String |
getMovementModeAsString()
Get the movement mode of the entity as a String. |
abstract java.lang.String |
getMovementString(EntityMovementType mtype)
Returns the name of the type of movement used. |
Sensor |
getNextSensor()
|
int |
getNextWeapon(int start)
Returns the next ready weapon, starting at the specified index |
protected abstract int[] |
getNoOfSlots()
|
int |
getNumberOf(EquipmentType etype)
Returns how many of the given equipment are present in the mech, destroyed or not. |
int |
getNumberOfCriticals(EquipmentType etype)
Returns the number of critical slots present in the mech, destroyed or not. |
int |
getNumberOfCriticals(EquipmentType etype,
int loc)
Returns the number of critical slots present in the section, destroyed or not. |
int |
getNumberOfCriticals(int loc)
Returns the number of total critical slots in a location |
int |
getNumberOfCriticals(int type,
int index,
int loc)
Returns the number of critical slots present in the section, destroyed or not. |
int |
getNumberOfShields(long size)
Check to see how many shields of a certian size a mek has. you can have up to shields per mech. |
int |
getOArmor(HitData hit)
Returns the original amount of armor in the location hit. |
int |
getOArmor(int loc)
Returns the original amount of armor in the location specified. |
int |
getOArmor(int loc,
boolean rear)
Returns the original amount of armor in the location specified, or ARMOR_NA, or ARMOR_DESTROYED. |
OffBoardDirection |
getOffBoardDirection()
Get the direction the board that the unit will be deployed. |
int |
getOffBoardDistance()
Get the distance in hexes from the board that the unit will be deployed. |
int |
getOInternal(HitData hit)
Returns the original amount of internal structure in the location hit. |
int |
getOInternal(int loc)
Returns the original amount of internal structure in the location specified, or ARMOR_NA, or ARMOR_DESTROYED. |
int |
getOriginalJumpMP()
Returns this entity's original jumping mp. |
protected int |
getOriginalRunMP()
Returns this entity's unmodified running/flank mp. |
protected int |
getOriginalSprintMP()
Returns this entity's unmodified sprint mp. |
int |
getOriginalWalkMP()
Returns this entity's original walking movement points |
Player |
getOwner()
Returns the player that "owns" this entity. |
int |
getOwnerId()
|
java.util.Vector<Coords> |
getPassedThrough()
|
java.util.Vector<java.lang.Integer> |
getPickedUpMechWarriors()
|
Coords |
getPosition()
Returns the current position of this entity on the board. |
Coords |
getPriorPosition()
|
int |
getQuirkIniBonus()
|
java.lang.String |
getQuirkList(java.lang.String sep)
Returns a string of all the quirk "codes" for this entity, using sep as the separator |
Quirks |
getQuirks()
|
int |
getRearArc()
Returns the rear firing arc for this entity - overrided by some units |
int |
getRecoveryTurn()
|
int |
getRemovalCondition()
Getter for property removalCondition. |
OffBoardDirection |
getRetreatedDirection()
|
int |
getRunHeat()
get the heat generated by this Entity when running/flanking |
int |
getRunMP()
Returns this entity's running/flank mp modified for heat and gravity. |
int |
getRunMP(boolean gravity,
boolean ignoreheat)
|
java.lang.String |
getRunMPasString()
Returns this entity's running/flank mp as a string. |
int |
getRunMPwithoutMASC()
Returns run MP without considering MASC |
abstract int |
getRunMPwithoutMASC(boolean gravity,
boolean ignoreheat)
Returns run MP without considering MASC, optionally figuring in gravity and possibly ignoring heat |
int |
getRunningGravityLimit()
get the gravity limit for ground movement |
int |
getSecondaryFacing()
Returns the secondary facing, or -1 if n/a |
java.util.Map<java.lang.Integer,Coords> |
getSecondaryPositions()
End of Battle Force Conversion Methods |
int |
getSensorCheck()
|
java.lang.String |
getSensorDesc()
returns a description to the current sensing range of the active sensor |
java.util.Vector<Sensor> |
getSensors()
|
java.lang.String |
getShortName()
A short name, suitable for displaying above a unit icon. |
java.lang.String |
getShortNameRaw()
|
int |
getShortRangeModifier()
|
java.util.Vector<SmallCraftBay> |
getSmallCraftBays()
get the bays separately |
int |
getSmallCraftLaunchRate()
|
java.lang.String |
getSource()
|
int |
getSpotTargetId()
|
int |
getSprintHeat()
get the heat generated by this Entity when sprinting |
int |
getSprintMP()
Returns this entity's running/flank mp modified for heat and gravity. |
int |
getSprintMP(boolean gravity,
boolean ignoreheat)
|
java.lang.String |
getSprintMPasString()
Returns this entity's sprint mp as a string. |
int |
getSprintMPwithoutMASC()
Returns sprint MP without considering MASC |
int |
getSprintMPwithoutMASC(boolean gravity,
boolean ignoreheat)
Returns sprint MP without considering MASC, optionally figuring in gravity and possibly ignoring heat |
int |
getStandingHeat()
get the heat generated by this Entity when standing still |
int |
getStartingPos()
|
TargetRoll |
getStealthModifier(int range,
Entity ae)
Determine the stealth modifier for firing at this unit from the given range. |
int |
getStructureType()
|
int |
getSwarmAttackerId()
Get the ID of the Entity that is attacking this unit with a
swarm attack. |
int |
getSwarmTargetId()
Get the ID of the Entity that is the current target of a
swarm attack by this unit. |
int |
getTaggedBy()
|
boolean |
getTargetedBySwarm(int entityId,
int weaponId)
Were we targeted by a certain swarm/swarm-i volley this turn? |
int |
getTargetId()
|
int |
getTargetType()
|
int |
getTaserFeedBackRounds()
get the rounds for which this entity suffers from taser feedback |
int |
getTaserInterference()
|
int |
getTaserInterferenceRounds()
|
int |
getTaserShutdownRounds()
get the number of rounds for which this unit should be shutdown by taser |
int |
getTechLevel()
Returns the unit tech for this entity. |
TeleMissileTracker |
getTMTracker()
|
int |
getTotalAmmoOfType(EquipmentType et)
|
int |
getTotalArmor()
Returns the total amount of armor on the entity. |
abstract int |
getTotalCommGearTons()
|
int |
getTotalInternal()
Returns the total amount of internal structure on the entity. |
int |
getTotalMunitionsOfType(EquipmentType et)
Determine how much ammunition (of all munition types) remains which is compatable with the given ammo. |
int |
getTotalOArmor()
Returns the total amount of armor on the entity. |
int |
getTotalOInternal()
Returns the total original amount of internal structure on the entity. |
java.util.ArrayList<Mounted> |
getTotalWeaponList()
|
abstract HitData |
getTransferLocation(HitData hit)
Gets the location that excess damage transfers to. |
int |
getTransferLocation(int loc)
int version |
java.util.Vector<Bay> |
getTransportBays()
|
int |
getTransportId()
Get the ID Entity that has loaded this one. |
java.util.Vector<Transporter> |
getTransports()
Returns vector of Transports for everything a unit transports |
float |
getTroopCarryingSpace()
|
HitData |
getTrooperAtLocation(HitData hit,
Entity transport)
|
char |
getUnitNumber()
Get the unit number of this entity. |
java.lang.String |
getUnusedString()
Return a string that identifies the unused capacity of this transporter. |
int |
getVector(int vectorFacing)
|
int[] |
getVectors()
|
int |
getVelocity()
|
int |
getVibroClaws()
Return how many BA vibroclaws this Entity is equipped with |
int |
getWalkHeat()
get the heat generated by this Entity when walking/cruising |
int |
getWalkMP()
Returns this entity's walking/cruising mp, factored for heat and gravity. |
int |
getWalkMP(boolean gravity,
boolean ignoreheat)
Returns this entity's walking/cruising mp, factored for heat and possibly gravity. |
abstract int |
getWeaponArc(int wn)
Returns the Rules.ARC that the weapon, specified by number, fires into. |
java.util.ArrayList<Mounted> |
getWeaponBayList()
|
java.util.ArrayList<Mounted> |
getWeaponGroupList()
|
java.util.ArrayList<Mounted> |
getWeaponList()
|
java.util.Iterator<Mounted> |
getWeapons()
|
int |
getWeaponsAndEquipmentCost(boolean ignoreAmmo)
|
int |
getWeaponsAndEquipmentCost(java.lang.StringBuffer detail,
boolean ignoreAmmo)
|
float |
getWeight()
|
int |
getWeightClass()
|
java.lang.String |
getWeightClassName()
|
int |
getYear()
|
boolean |
hasActiveAngelECCM()
Checks to see if this unit has a functional AngelECM unit that is using ECCM. |
boolean |
hasActiveAngelECM()
Does the mech have a functioning ECM unit? |
boolean |
hasActiveBlueShield()
Checks to see if this unit has a functional Blue Shield Particle Field Damper that is turned on |
boolean |
hasActiveECCM()
Checks to see if this entity has a functional ECM unit that is using ECCM. |
boolean |
hasActiveECM()
Does the mech have a functioning ECM unit? |
boolean |
hasActiveECM(boolean stealth)
check if we have an active ECM unit for stealth armor purposes |
boolean |
hasActiveEiCockpit()
|
boolean |
hasActiveShield(int location)
Does the mech have an active shield This should only be called by hasActiveShield(location,rear) |
boolean |
hasActiveShield(int location,
boolean rear)
Does the mech have an active shield This should only be called after hasShield has been called. |
boolean |
hasAimModeTargComp()
Returns wether or not this entity has a Targeting Computer that is in aimed shot mode. |
boolean |
hasArcFired(int location,
boolean rearMount)
|
boolean |
hasArmoredChassis()
does this entity have an armored chassis? |
boolean |
hasArmoredEngine()
|
boolean |
hasBAP()
Does the mech have a functioning BAP? |
boolean |
hasBAP(boolean checkECM)
|
boolean |
hasBARArmor()
does this Entity have BAR armor? |
boolean |
hasBattleArmorHandles()
|
boolean |
hasC3()
Checks if it has any type of C3 computer. |
boolean |
hasC3i()
|
boolean |
hasC3M()
Checks if the entity has a C3 Master. |
boolean |
hasC3MM()
|
boolean |
hasC3S()
Returns whether this 'mech has a C3 Slave or not. |
boolean |
hasCASEII()
Only Meks can have CASE II so all other entites return false. |
boolean |
hasCASEII(int location)
Only Meks have CASE II so all other entites return false. |
boolean |
hasDisplacementAttack()
|
boolean |
hasEiCockpit()
|
boolean |
hasEnvironmentalSealing()
does this Entity have Environmental sealing? |
boolean |
hasFunctionalArmAES(int location)
|
boolean |
hasFunctionalLegAES()
|
boolean |
hasGhostTargets(boolean active)
Does the mech have a functioning ECM unit, tuned to ghost target generation? |
boolean |
hasHipCrit()
Returns true if the entity has a hip crit. |
boolean |
hasINarcPodsAttached()
Do we have any iNarc Pods attached? |
boolean |
hasInfernoAmmo()
Scans through the ammo on the unit for any inferno rounds. |
boolean |
hasLegActuatorCrit()
Returns true if the entity has a leg actuator crit |
boolean |
hasLinkedMGA(Mounted mounted)
|
boolean |
hasModularArmor()
|
boolean |
hasModularArmor(int loc)
|
boolean |
hasNoDefenseShield(int location)
Does the mech have an shield in no defense mode |
boolean |
hasPassiveShield(int location)
Does the mech have a passive shield This should only be called by hasPassiveShield(location,rear) |
boolean |
hasPassiveShield(int location,
boolean rear)
Does the mech have a passive shield This should only be called after hasShield has been called. |
abstract boolean |
hasRearArmor(int loc)
Does this location have rear armor? |
boolean |
hasShield()
Does the mech have any shields. a mech can have up to 2 shields. |
boolean |
hasSpotlight()
|
boolean |
hasStealth()
does this unit have stealth armor? |
boolean |
hasSystem(int system,
int loc)
Returns true if the the location has a system of the type, whether is destroyed or not |
boolean |
hasTAG()
|
boolean |
hasTargComp()
Returns wether or not this entity has a Targeting Computer. |
boolean |
hasUMU()
This method checks to see if a unit has Underwater Maneuvering Units Only Battle Mechs may have UMU's |
boolean |
hasVibroblades()
Checks to see if this entity is wielding any vibroblades |
boolean |
hasWorkingMisc(java.math.BigInteger flag)
Check if the entity has an arbitrary type of misc equipment |
boolean |
hasWorkingMisc(java.math.BigInteger flag,
int secondary,
int location)
Check if the entity has an arbitrary type of misc equipment |
boolean |
hasWorkingMisc(java.math.BigInteger flag,
long secondary)
Check if the entity has an arbitrary type of misc equipment |
boolean |
hasWorkingMisc(java.lang.String name)
Check if the entity has an arbitrary type of misc equipment |
boolean |
hasWorkingSystem(int system,
int loc)
Returns true if there is at least 1 functional system of the type specified in the location |
boolean |
hasWorkingWeapon(java.math.BigInteger flag)
Check if the entity has an arbitrary type of weapon |
boolean |
hasWorkingWeapon(java.math.BigInteger flag,
int secondary,
int location)
Check if the entity has an arbitrary type of weapon |
boolean |
hasWorkingWeapon(java.math.BigInteger flag,
long secondary)
Check if the entity has an arbitrary type of weapon |
boolean |
hasWorkingWeapon(java.lang.String name)
Check if the entity has an arbitrary type of weapon |
int |
height()
Returns the height of the unit, that is, how many levels above it's elevation is it for LOS purposes. |
void |
hitAllCriticals(int loc,
int slot)
Hits all criticals of the system occupying the specified critical slot. |
void |
illuminateTarget(HexTarget target)
illuminate a hex and all units that are between us and the hex |
void |
initializeArmor(int val,
int loc)
Initializes the armor on the unit. |
void |
initializeInternal(int val,
int loc)
Initializes the internal structure on the unit. |
boolean |
isActive()
Determine if this entity participate in the current game phase. |
boolean |
isActive(int turn)
|
boolean |
isAirborne()
|
boolean |
isAirborneVTOL()
|
boolean |
isAssaultDropInProgress()
|
boolean |
isAttackingThisTurn()
|
boolean |
isBATaserShutdown()
|
boolean |
isBoardProhibited(int mapType)
Returns true if the the given board is prohibited |
boolean |
isCanon()
|
boolean |
isCapitalFighter()
|
boolean |
isCapitalScale()
a function that let's us know if this entity has capital-scale armor |
boolean |
isCaptured()
Has this entity been captured? |
boolean |
isCarcass()
Is this unit a carcass, a carcass can take no action |
boolean |
isCarefulStand()
|
boolean |
isChameleonShieldActive()
Determine if this unit has an active chameleon light polarization field. |
boolean |
isCharging()
|
boolean |
isClan()
Checks if this is a clan unit. |
boolean |
isClanArmor()
|
boolean |
isClearingMinefield()
|
boolean |
isCommander()
|
boolean |
isDeployed()
Checks to see if an entity has been deployed |
boolean |
isDesignValid()
|
boolean |
isDestroyed()
|
boolean |
isDone()
|
boolean |
isDoomed()
|
boolean |
isDropping()
|
boolean |
isElevationValid(int assumedElevation,
IHex hex)
Check if this entity can legally occupy the requested elevation. |
boolean |
isEligibleFor(IGame.Phase phase)
Determines if an entity is eligible for a phase. |
boolean |
isEligibleForFiring()
An entity is eligible if its to-hit number is anything but impossible. |
boolean |
isEligibleForMovement()
Pretty much anybody's eligible for movement. |
boolean |
isEligibleForOffboard()
|
boolean |
isEligibleForPhysical()
Check if the entity has any valid targets for physical attacks. |
boolean |
isEligibleForTargetingPhase()
|
boolean |
isEnemyOf(Entity other)
Returns true if the other entity is an enemy of this entity. |
boolean |
isEvading()
|
boolean |
isFighter()
|
boolean |
isFindingClub()
|
boolean |
isGrappleAttacker()
|
boolean |
isHexProhibited(IHex hex)
Returns true if the specified hex contains some sort of prohibited terrain. |
boolean |
isHidden()
|
boolean |
isHullDown()
|
boolean |
isIlluminated()
|
boolean |
isImmobile()
Is this entity shut down or is the crew unconscious? |
boolean |
isINarcedBy(int nTeamID)
Have we been iNarced with a homing pod from that team? |
boolean |
isINarcedWith(long type)
Have we been iNarced with the named pod from any team? |
boolean |
isLargeCraft()
is this entity a large craft? |
boolean |
isLayingMines()
|
boolean |
isLoadableThisTurn()
Returns true if this entity could potentially be loaded (did not move from starting hex) |
boolean |
isLocationBad(int loc)
Is this location destroyed or breached? |
boolean |
isLocationDoomed(int loc)
Is this location destroyed or breached? |
boolean |
isMakingDfa()
|
boolean |
isMilitary()
returns whether the unit is a military unit (as opposed to a civilian unit). |
boolean |
isMixedTech()
|
boolean |
isNarcedBy(int nTeamID)
has the team attached a narc pod to me? |
boolean |
isNOE()
is the unit flying Nape of the Earth? |
abstract boolean |
isNuclearHardened()
Checks if the unit is hardened agaist nuclear strikes. |
boolean |
isNullSigActive()
Determine if this unit has an active null-signature system. |
boolean |
isOffBoard()
|
boolean |
isOmni()
|
boolean |
isOnSameSheet(Coords tc)
returns true if this is a valid target for Arrow IV homing which was aimed at hex (tc) |
boolean |
isPartOfFighterSquadron()
is this entity loaded into a fighter squadron? |
boolean |
isProne()
|
boolean |
isPushing()
|
boolean |
isRamming()
|
boolean |
isReckless()
|
boolean |
isRepairable()
Determine if the unit can be repaired, or only harvested for spares. |
boolean |
isSalvage()
Determine if the unit is just combat-lossed or if it has been utterly destroyed. |
abstract boolean |
isSecondaryArcWeapon(int weaponId)
Returns true if this weapon fires into the secondary facing arc. |
boolean |
isSeenByEnemy()
|
boolean |
isSelectableThisTurn()
Returns true if this entity is selectable for action. |
boolean |
isShutDown()
|
boolean |
isShutDownThisPhase()
|
boolean |
isSpotting()
|
boolean |
isStalled()
Is this Entity's ICE Engine stalled? |
boolean |
isStealthActive()
Determine if this unit has an active and working stealth system. |
boolean |
isStealthOn()
Determine if this unit has an active and working stealth system. |
boolean |
isStuck()
Is the Entity stuck in a swamp? |
boolean |
isSufferingEMI()
|
boolean |
isSurfaceNaval()
is this a naval vessel on the surface of the water? |
boolean |
isSystemRepairable(int system,
int loc)
Returns false if there is at least one non-repairable critical slot for this system in the given location |
boolean |
isTargetable()
Returns true if this entity is targetable for attacks |
boolean |
isTargetOfDisplacementAttack()
Returns true if any other entities this entity knows of are making a displacement attack on this entity. |
boolean |
isUnjammingRAC()
|
boolean |
isUnloadedThisTurn()
Determine if this Entity was unloaded previously this turn. |
boolean |
isUsingManAce()
|
boolean |
isUsingSpotlight()
|
abstract boolean |
isValidSecondaryFacing(int dir)
Can this entity torso/turret twist the given direction? |
boolean |
isVisibleToEnemy()
|
boolean |
isVoidSigActive()
Determine if this unit has an active void signature system. |
boolean |
isWeaponBlockedAt(int loc,
boolean isRear)
Determine if transported units prevent a weapon in the given location from firing. |
boolean |
itemOppositeTech(java.lang.String s)
|
void |
load(Entity unit)
Load the given unit. |
void |
load(Entity unit,
boolean checkElev)
Load the given unit. |
void |
loadAllWeapons()
Attempts to load all weapons with ammo |
boolean |
loadedUnitsHaveActiveECM()
Do units loaded onto this entity still have active ECM/ECCM/etc.? |
void |
loadWeapon(Mounted mounted)
Tries to load the specified weapon with the first available ammo |
boolean |
loadWeapon(Mounted mounted,
Mounted mountedAmmo)
Tries to load the specified weapon with the specified ammo. |
void |
loadWeaponWithSameAmmo(Mounted mounted)
Tries to load the specified weapon with the first available ammo of the same munition type as currently in use. |
boolean |
loadWeaponWithSameAmmo(Mounted mounted,
Mounted mountedAmmo)
Tries to load the specified weapon with the specified ammo. |
boolean |
locationHasCase(int loc)
Returns whether there is CASE protecting the location. |
boolean |
locationIsLeg(int loc)
Returns true is the location is a leg |
abstract int |
locations()
Returns the number of locations in the entity |
boolean |
needsRollToStand()
Returns true is the entity needs a roll to stand up |
void |
newRound(int roundNumber)
Start a new round |
boolean |
onSameC3NetworkAs(Entity e)
|
boolean |
onSameC3NetworkAs(Entity e,
boolean ignoreECM)
Checks if another entity is on the same c3 network as this entity |
boolean |
passedThrough(Coords c)
|
Coords |
passedThroughPrevious(Coords c)
What coords were passed through previous to the given one |
boolean |
passedWithin(Coords c,
int dist)
Did the entity pass within a certain number of hexes of these coords? |
void |
pickUp(MechWarrior mw)
|
protected void |
printDebugToFile()
|
void |
recover(Entity unit)
Recover the given unit. |
void |
refreshLocations()
|
void |
reloadEmptyWeapons()
Attempts to reload any empty weapons with the first ammo found |
void |
removeAllINarcPods()
Remove all attached iNarc Pods |
void |
removeAllTransporters()
Remove all transportation components from this Entity. |
void |
removeCriticals(int loc,
CriticalSlot cs)
Removes all matching critical slots from the location |
boolean |
removeINarcPod(INarcPod pod)
Remove an INarcPod from this entity. |
void |
removeMisc(java.lang.String toRemove)
Removes the first misc eq. whose name equals the specified string. |
boolean |
removePartialCoverHits(int location,
int cover,
int side)
|
void |
resetBayDoors()
do any damage to bay doors |
void |
resetFiringArcs()
|
void |
restore()
Restores the entity after serialization |
abstract HitData |
rollHitLocation(int table,
int side)
Rolls up a hit location |
abstract HitData |
rollHitLocation(int table,
int side,
int aimedLocation,
int aimingMode)
Rolls the to-hit number |
PilotingRollData |
rollMovementInBuilding(Building bldg,
int distance,
java.lang.String why,
EntityMovementType overallMoveType)
Calculates and returns the roll for an entity moving in buildings. |
void |
setAltitude(int a)
|
void |
setArcFired(int location,
boolean rearMount)
|
void |
setArmor(int val,
HitData hit)
Sets the amount of armor in the location specified. |
void |
setArmor(int val,
int loc)
Sets the amount of armor in the front location specified. |
void |
setArmor(int val,
int loc,
boolean rear)
Sets the amount of armor in the location specified. |
void |
setArmorTechLevel(int newTL)
|
void |
setArmorType(int armType)
|
void |
setArmorType(java.lang.String armType)
|
void |
setArmsFlipped(boolean armsFlipped)
Set whether or not the mech's arms are flipped to the rear |
void |
setAssaultDropInProgress(boolean flag)
|
void |
setBATaserShutdown(boolean value)
|
void |
setC3Master(Entity e)
Set another Entity as our C3 Master |
void |
setC3Master(int entityId)
|
void |
setC3NetId(Entity e)
|
void |
setCanon(boolean canon)
|
void |
setCanUnstickByJumping(boolean arg)
Set wether this Enity is stuck in a swamp or not |
void |
setCaptured(boolean arg)
Specify that this entity has been captured. |
void |
setCarcass(boolean carcass)
Sets if this unit is a carcass. |
void |
setCarefulStand(boolean stand)
|
void |
setChassis(java.lang.String chassis)
sets the chassis name for this entity. |
void |
setClearingMinefield(boolean clearingMinefield)
|
void |
setClimbMode(boolean state)
|
void |
setCommander(boolean arg)
|
void |
setCrew(Pilot crew)
|
void |
setCritical(int loc,
int slot,
CriticalSlot cs)
Sets a critical hit slot |
void |
setDeployed(boolean deployed)
Toggles if an entity has been deployed |
void |
setDeployRound(int deployRound)
The round the unit will be deployed. |
void |
setDesignValid(boolean designValid)
|
void |
setDestroyed(boolean destroyed)
|
void |
setDisplacementAttack(DisplacementAttackAction displacementAttack)
|
void |
setDone(boolean done)
|
void |
setDoomed(boolean doomed)
|
void |
setElevation(int elevation)
Sets the current elevation of this entity above the ground. |
void |
setEMI(boolean inVal)
|
void |
setEvading(boolean evasion)
|
void |
setExternalId(int externalId)
This sets the external ID. |
void |
setFacing(int facing)
Sets the primary facing. |
void |
setFindingClub(boolean findingClub)
|
void |
setGame(IGame game)
This sets the game the entity belongs to. |
void |
setGameOptions()
|
void |
setGrappled(int id,
boolean attacker)
|
void |
setGrappleSide(int side)
|
void |
setHidden(boolean inVal)
|
void |
setHullDown(boolean down)
|
void |
setId(int id)
Sets the ID number of this Entity, which will also set the display name and short name to null. |
void |
setIlluminated(boolean arg)
|
void |
setInternal(int val,
HitData hit)
Sets the amount of armor in the location specified. |
void |
setInternal(int val,
int loc)
Sets the amount of armor in the location specified. |
void |
setLandedAssaultDrop()
|
void |
setLastTarget(int id)
|
void |
setLayingMines(boolean laying)
|
void |
setLocationStatus(int loc,
int status)
sets location exposure |
void |
setMixedTech(boolean mixedTech)
|
void |
setModel(java.lang.String model)
Sets the unit code for this Entity. |
void |
setMovementMode(EntityMovementMode movementMode)
Set the movement type of the entity |
void |
setNextSensor(Sensor s)
|
void |
setOffBoard(int distance,
OffBoardDirection direction)
Set the unit as an offboard deployment. |
void |
setOmni(boolean omni)
|
void |
setOriginalJumpMP(int jumpMP)
Sets this entity's original jump movement points |
void |
setOriginalWalkMP(int walkMP)
Sets this entity's original walking movement points |
void |
setOwner(Player player)
|
void |
setPassedThrough(java.util.Vector<Coords> pass)
|
void |
setPosition(Coords position)
Sets the current position of this entity on the board. |
void |
setProne(boolean prone)
|
void |
setQuirks(Quirks quirks)
|
void |
setRamming(boolean b)
|
void |
setRapidFire()
Force rapid fire mode to the highest level on RAC and UAC |
void |
setReckless(boolean b)
|
void |
setRecoveryTurn(int r)
|
void |
setRemovalCondition(int removalCondition)
Setter for property removalCondition. |
void |
setRetreatedDirection(OffBoardDirection retreatedDirection)
|
void |
setSalvage(boolean canSalvage)
Record if the unit is just combat-lossed or if it has been utterly destroyed. |
void |
setSecondaryFacing(int sec_facing)
Sets the secondary facing. |
void |
setSeenByEnemy(boolean b)
|
void |
setShutDown(boolean shutDown)
|
void |
setShutDownThisPhase(boolean shutDown)
|
void |
setSource(java.lang.String source)
used to set the source of the creation of this entity, i.e RS PPU Custom what not Fluff for MMLab |
void |
setSpotlight(boolean arg)
|
void |
setSpotlightState(boolean arg)
|
void |
setSpotTargetId(int targetId)
|
void |
setSpotting(boolean spotting)
|
void |
setStartingPos(int i)
|
void |
setStructureType(int strucType)
|
void |
setStructureType(java.lang.String strucType)
|
void |
setStuck(boolean arg)
Set weather this Entity is stuck in a swamp or not |
void |
setSwarmAttackerId(int id)
Record the ID of the Entity that is attacking this unit with
a swarm attack. |
void |
setSwarmTargetId(int id)
Record the ID of the Entity that is the current target of a
swarm attack by this unit. |
void |
setTaggedBy(int tagger)
|
void |
setTaserFeedback(int rounds)
set this entity to suffer from taser feedback |
void |
setTaserInterference(int value,
int rounds)
|
void |
setTaserShutdownRounds(int rounds)
|
void |
setTechLevel(int techLevel)
Sets the tech level for this Entity. |
void |
setTransportId(int transportId)
Record the ID of the Entity that has loaded this unit. |
void |
setUnitNumber(char unit)
Set the unit number for this entity. |
void |
setUnjammingRAC(boolean u)
|
void |
setUnloaded(boolean unloaded)
This method should only be called when needed to remove a dead swarmer's game turn. |
void |
setUsedSearchlight(boolean arg)
|
void |
setVectors(int[] v)
|
void |
setVisibleToEnemy(boolean b)
|
void |
setWeaponHit(Mounted which)
|
void |
setWeight(float weight)
|
void |
setYear(int year)
|
boolean |
shouldDeploy(int round)
Returns true if the entity should be deployed |
int |
sideTable(Coords src)
|
int |
sideTable(Coords src,
boolean usePrior)
|
int |
sideTable(Coords src,
boolean usePrior,
int face)
|
java.lang.String |
statusToString()
This returns a textual description of the entity for visualy impaired users. |
java.lang.String |
statusToString(int loc)
This returns a textual description of a specific location of the entity for visualy impaired users. |
java.lang.String |
statusToString(java.lang.String str)
|
java.lang.String |
toString()
|
boolean |
unload(Entity unit)
Unload the given unit. |
void |
updateBays()
cycle through and update Bays |
boolean |
usedSearchlight()
|
boolean |
usedTag()
|
boolean |
usesWeaponBays()
a function that let's us know if this entity is using weapons bays |
abstract java.util.Vector<Report> |
victoryReport()
Generates a vector containing reports on all useful information about this entity. |
boolean |
weaponFiredFrom(int loc)
Checks whether a weapon has been fired from the specified location this turn |
Mounted |
whichBay(int bayID)
return the bay of the current weapon |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int NONE
public static final int LOC_NONE
public static final int LOC_DESTROYED
public static final int MAX_C3_NODES
public static final int GRAPPLE_BOTH
public static final int GRAPPLE_RIGHT
public static final int GRAPPLE_LEFT
protected transient IGame game
protected int id
protected int externalId
protected float weight
protected boolean omni
protected java.lang.String chassis
protected java.lang.String model
protected int year
protected int techLevel
protected Engine engine
protected boolean mixedTech
protected boolean designValid
protected java.lang.String displayName
protected java.lang.String shortName
public int duplicateMarker
protected transient Player owner
protected int ownerId
public Pilot crew
protected boolean shutDown
protected boolean shutDownThisPhase
protected boolean doomed
protected boolean destroyed
protected Coords position
protected java.util.Map<java.lang.Integer,Coords> secondaryPositions
protected int facing
protected int sec_facing
protected int walkMP
protected int jumpMP
protected boolean done
protected boolean prone
protected boolean hullDown
protected boolean findingClub
protected boolean armsFlipped
protected boolean unjammingRAC
protected boolean hasSpotlight
protected boolean illuminated
protected boolean spotlightIsActive
protected boolean usedSearchlight
protected boolean stuckInSwamp
protected boolean canUnstickByJumping
protected int taggedBy
protected boolean layingMines
protected boolean _isEMId
protected DisplacementAttackAction displacementAttack
public int heat
public int heatBuildup
public int heatFromExternal
public int delta_distance
public int mpUsed
public EntityMovementType moved
protected int mpUsedLastRound
public boolean gotPavementBonus
public boolean hitThisRoundByAntiTSM
public boolean inReverse
public int damageThisPhase
public int damageThisRound
public int engineHitsThisRound
public boolean rolledForEngineExplosion
public boolean dodging
public boolean reckless
public boolean spotting
protected int killerId
protected int[] vectors
public InfernoTracker infernos
public ArtilleryTracker aTracker
public TeleMissileTracker tmTracker
protected java.lang.String c3NetIdString
protected int c3Master
protected int c3CompanyMasterIndex
protected int armorType
protected int armorTechLevel
protected int structureType
protected java.lang.String source
protected java.util.ArrayList<Mounted> equipmentList
protected java.util.ArrayList<Mounted> weaponList
protected java.util.ArrayList<Mounted> weaponBayList
protected java.util.ArrayList<Mounted> weaponGroupList
protected java.util.ArrayList<Mounted> totalWeaponList
protected java.util.ArrayList<Mounted> ammoList
protected java.util.ArrayList<Mounted> bombList
protected java.util.ArrayList<Mounted> miscList
protected java.util.ArrayList<INarcPod> pendingINarcPods
protected java.util.ArrayList<INarcPod> iNarcPods
protected java.util.ArrayList<NarcPod> pendingNarcPods
protected java.util.ArrayList<NarcPod> narcPods
protected java.util.ArrayList<java.lang.String> failedEquipmentList
protected long m_lNarcedBy
protected long m_lPendingNarc
protected CriticalSlot[][] crits
protected EntityMovementMode movementMode
protected boolean isHidden
protected boolean carcass
protected int elevation
protected int altitude
protected int lastTarget
protected boolean isCarefulStanding
protected int heatSinkCoolantFailureFactor
protected int taserShutdownRounds
protected boolean shutdownByBATaser
protected int taserFeedBackRounds
protected int taserInterference
protected int taserInterferenceRounds
protected java.lang.StringBuffer bvText
protected java.lang.String startTable
protected java.lang.String endTable
protected java.lang.String startRow
protected java.lang.String endRow
protected java.lang.String startColumn
protected java.lang.String endColumn
protected java.lang.String nl
protected boolean DEBUGBATTLEFORCE
protected java.lang.StringBuffer battleForceDebugString
protected double[] battleForceMinRangeModifier
protected double[] battleForceToHitModifier
public static final int BATTLEFORCESHORTRANGE
public static final int BATTLEFORCEMEDIUMRANGE
public static final int BATTLEFORCELONGRANGE
public static final int BATTLEFORCEEXTREMERANGE
protected Entity.EntityFluff fluff
| Constructor Detail |
|---|
public Entity()
| Method Detail |
|---|
public void restore()
public int getId()
public void setId(int id)
id - the new ID.public int getExternalId()
externalIdpublic void setExternalId(int externalId)
externalId - the new external ID for this Entity.externalIdpublic IGame getGame()
public void setGame(IGame game)
game - the game.public java.lang.String getModel()
public void setModel(java.lang.String model)
model - The unit code.public java.lang.String getChassis()
public void setChassis(java.lang.String chassis)
chassis - The chassis name.public Entity.EntityFluff getFluff()
public int getTechLevel()
public void setTechLevel(int techLevel)
techLevel - The tech level, it must be one of the
TechConstants .public int getRecoveryTurn()
public void setRecoveryTurn(int r)
public boolean isClan()
setTechLevel(int)public boolean isClanArmor()
public boolean isMixedTech()
public void setMixedTech(boolean mixedTech)
public boolean isDesignValid()
public void setDesignValid(boolean designValid)
public int getYear()
public void setYear(int year)
public float getWeight()
public int getWeightClass()
public java.lang.String getWeightClassName()
public void setWeight(float weight)
public boolean isOmni()
public void setOmni(boolean omni)
public abstract int locations()
public Player getOwner()
public void setOwner(Player player)
public int getOwnerId()
public boolean isEnemyOf(Entity other)
public Pilot getCrew()
public void setCrew(Pilot crew)
public boolean isShutDown()
public void setShutDown(boolean shutDown)
public void setShutDownThisPhase(boolean shutDown)
public boolean isShutDownThisPhase()
public boolean isDoomed()
public void setDoomed(boolean doomed)
public boolean isDestroyed()
public void setDestroyed(boolean destroyed)
public int getTargetType()
getTargetType in interface Targetablepublic int getTargetId()
getTargetId in interface Targetablepublic int getHeight()
getHeight in interface Targetablepublic boolean isDone()
public void setDone(boolean done)
public void setUnloaded(boolean unloaded)
public boolean isActive()
true if this entity is not shut down, is not
destroyed, has an active crew, and was not unloaded from a
transport this turn. false otherwise.public boolean isActive(int turn)
public boolean isSelectableThisTurn()
public boolean isLoadableThisTurn()
public boolean isUnloadedThisTurn()
Entity was unloaded previously this turn.
true if this entity was unloaded for any reason
during this turn.public boolean isTargetable()
public boolean isProne()
public void setProne(boolean prone)
public boolean isHullDown()
public void setHullDown(boolean down)
public boolean isImmobile()
isImmobile in interface Targetablepublic boolean isCharging()
public boolean isPushing()
public boolean isMakingDfa()
public boolean hasDisplacementAttack()
public DisplacementAttackAction getDisplacementAttack()
public void setDisplacementAttack(DisplacementAttackAction displacementAttack)
public boolean isTargetOfDisplacementAttack()
public DisplacementAttackAction findTargetedDisplacement()
public boolean isUnjammingRAC()
public void setUnjammingRAC(boolean u)
public boolean isFindingClub()
public void setFindingClub(boolean findingClub)
public void setArmsFlipped(boolean armsFlipped)
public boolean getArmsFlipped()
public Coords getPosition()
getPosition in interface Targetablepublic void setPosition(Coords position)
position - the new position.public Coords getPriorPosition()
public void setElevation(int elevation)
elevation - an int representing the new position.
public int calcElevation(IHex current,
IHex next,
int assumedElevation,
boolean climb,
boolean wigeEndClimbPrevious)
public int calcElevation(IHex current,
IHex next)
public int getElevation()
getElevation in interface Targetablepublic boolean canGoDown()
public boolean canGoDown(int assumedElevation,
Coords assumedPos)
public boolean canGoUp(int assumedElevation,
Coords assumedPos)
public boolean isElevationValid(int assumedElevation,
IHex hex)
public int height()
public int absHeight()
absHeight in interface Targetablepublic java.lang.String getDisplayName()
getDisplayName in interface Targetablepublic void generateDisplayName()
public java.lang.String getShortName()
public void generateShortName()
public java.lang.String getShortNameRaw()
public int getFacing()
public void setFacing(int facing)
public int getSecondaryFacing()
public void setSecondaryFacing(int sec_facing)
public abstract boolean canChangeSecondaryFacing()
public abstract boolean isValidSecondaryFacing(int dir)
public abstract int clipSecondaryFacing(int dir)
public boolean canUnjamRAC()
public boolean canFlipArms()
public int getOriginalWalkMP()
public void setOriginalWalkMP(int walkMP)
public int getWalkMP()
public int getWalkMP(boolean gravity,
boolean ignoreheat)
gravity - Should the movement be factored for gravityignoreheat - Should heat be ignored?public int getHeatMPReduction()
public int getStandingHeat()
public int getWalkHeat()
protected int getOriginalRunMP()
public int getRunMP()
public int getRunMP(boolean gravity,
boolean ignoreheat)
public int getRunMPwithoutMASC()
public abstract int getRunMPwithoutMASC(boolean gravity,
boolean ignoreheat)
public java.lang.String getRunMPasString()
public int getRunHeat()
protected int getOriginalSprintMP()
public int getSprintMP()
public int getSprintMP(boolean gravity,
boolean ignoreheat)
public int getSprintMPwithoutMASC()
public int getSprintMPwithoutMASC(boolean gravity,
boolean ignoreheat)
public java.lang.String getSprintMPasString()
public int getSprintHeat()
public int getRunningGravityLimit()
public int getOriginalJumpMP()
public void setOriginalJumpMP(int jumpMP)
public int getJumpMP()
public int getJumpMP(boolean gravity)
gravity -
public int getJumpType()
public int getJumpHeat(int movedMP)
movedMP - the number of movement points spentpublic int getJumpMPWithTerrain()
public int elevationOccupied(IHex hex)
public boolean isHexProhibited(IHex hex)
public boolean isBoardProhibited(int mapType)
public abstract java.lang.String getMovementString(EntityMovementType mtype)
public abstract java.lang.String getMovementAbbr(EntityMovementType mtype)
public java.lang.String getLocationName(HitData hit)
public abstract java.lang.String[] getLocationNames()
public java.lang.String getLocationName(int loc)
public abstract java.lang.String[] getLocationAbbrs()
public java.lang.String getLocationAbbr(HitData hit)
public java.lang.String getLocationAbbr(int loc)
public int getLocationFromAbbr(java.lang.String abbr)
public abstract HitData rollHitLocation(int table,
int side,
int aimedLocation,
int aimingMode)
public abstract HitData rollHitLocation(int table,
int side)
public abstract HitData getTransferLocation(HitData hit)
public int getTransferLocation(int loc)
public abstract int getDependentLocation(int loc)
public abstract boolean hasRearArmor(int loc)
public int getArmor(int loc)
public int getArmor(HitData hit)
public int getArmor(int loc,
boolean rear)
public int getOArmor(int loc)
public int getOArmor(HitData hit)
public int getOArmor(int loc,
boolean rear)
loc - the location to check.rear - if true inspect the rear armor, else check the front.
public void setArmor(int val,
HitData hit)
public void setArmor(int val,
int loc)
public void setArmor(int val,
int loc,
boolean rear)
val - the value of the armor (eg how many armor points)loc - the location of the armorrear - true iff the armor is rear mounted.public void refreshLocations()
public void initializeArmor(int val,
int loc)
public int getTotalArmor()
public int getTotalOArmor()
public double getArmorRemainingPercent()
public int getInternal(HitData hit)
public int getInternal(int loc)
public int getOInternal(HitData hit)
public int getOInternal(int loc)
public void setInternal(int val,
HitData hit)
public void setInternal(int val,
int loc)
public void initializeInternal(int val,
int loc)
public abstract void autoSetInternal()
public int getTotalInternal()
public int getTotalOInternal()
public double getInternalRemainingPercent()
public boolean isLocationBad(int loc)
public boolean isLocationDoomed(int loc)
public int getLocationStatus(int loc)
public void setLocationStatus(int loc,
int status)
loc - the location who's exposure is to be setstatus - the status to setpublic boolean locationIsLeg(int loc)
loc - the location to check.public java.lang.String getArmorString(int loc)
public java.lang.String getArmorString(int loc,
boolean rear)
public java.lang.String getInternalString(int loc)
public static java.lang.String armorStringFor(int value)
public int getHeatFiringModifier()
public Mounted addEquipment(EquipmentType etype,
int loc)
throws LocationFullException
LocationFullException
public Mounted addEquipment(EquipmentType etype,
int loc,
boolean rearMounted)
throws LocationFullException
LocationFullException
public Mounted addEquipment(EquipmentType etype,
int loc,
boolean rearMounted,
boolean bodyMounted,
boolean isArmored)
throws LocationFullException
LocationFullException
public Mounted addEquipment(EquipmentType etype,
int loc,
boolean rearMounted,
int nAmmo)
throws LocationFullException
etype - loc - rearMounted - nAmmo -
LocationFullException
public Mounted addBomb(EquipmentType etype,
int loc)
throws LocationFullException
LocationFullException
public Mounted addWeaponGroup(EquipmentType etype,
int loc)
throws LocationFullException
LocationFullException
public Mounted addEquipment(EquipmentType etype,
int loc,
boolean rearMounted,
boolean bodyMounted)
throws LocationFullException
LocationFullException
protected void addEquipment(Mounted mounted,
int loc,
boolean rearMounted,
int nAmmo)
throws LocationFullException
LocationFullException
protected void addBomb(Mounted mounted,
int loc)
throws LocationFullException
LocationFullException
protected void addEquipment(Mounted mounted,
int loc,
boolean rearMounted,
boolean isWeaponGroup)
throws LocationFullException
LocationFullException
protected void addEquipment(Mounted mounted,
int loc,
boolean rearMounted)
throws LocationFullException
LocationFullExceptionpublic void addFailedEquipment(java.lang.String s)
public int getEquipmentNum(Mounted mounted)
public java.util.ArrayList<Mounted> getEquipment()
public Mounted getEquipment(int index)
public EquipmentType getEquipmentType(CriticalSlot cs)
public java.util.Iterator<java.lang.String> getFailedEquipment()
public int getTotalAmmoOfType(EquipmentType et)
public int getTotalMunitionsOfType(EquipmentType et)
et - - the EquipmentType of the ammo to be found. This
value may be null.
int count of the amount of shots of all
munitions equivalent to the given ammo type.public abstract int getWeaponArc(int wn)
public abstract boolean isSecondaryArcWeapon(int weaponId)
public java.util.Iterator<Mounted> getWeapons()
public java.util.ArrayList<Mounted> getWeaponList()
public java.util.ArrayList<Mounted> getTotalWeaponList()
public java.util.ArrayList<Mounted> getWeaponBayList()
public java.util.ArrayList<Mounted> getWeaponGroupList()
public int getFirstWeapon()
public int getNextWeapon(int start)
public void loadAllWeapons()
public void loadWeapon(Mounted mounted)
public void loadWeaponWithSameAmmo(Mounted mounted)
public boolean loadWeapon(Mounted mounted,
Mounted mountedAmmo)
public boolean loadWeaponWithSameAmmo(Mounted mounted,
Mounted mountedAmmo)
public boolean weaponFiredFrom(int loc)
public java.util.ArrayList<Mounted> getAmmo()
public java.util.ArrayList<Mounted> getMisc()
public java.util.ArrayList<Mounted> getBombs()
public java.util.Vector<Mounted> getBombs(java.math.BigInteger flag)
public void removeMisc(java.lang.String toRemove)
public java.util.List<Mounted> getClubs()
public boolean hasWorkingMisc(java.math.BigInteger flag)
flag - A MiscType.F_XXX
public boolean hasWorkingMisc(java.math.BigInteger flag,
long secondary)
flag - A MiscType.F_XXXsecondary - A MiscType.S_XXX or -1 for don't care
public int countWorkingMisc(java.math.BigInteger flag)
flag -
public boolean hasWorkingMisc(java.lang.String name)
name - MiscType internal name
public boolean hasWorkingMisc(java.math.BigInteger flag,
int secondary,
int location)
flag - A MiscType.F_XXXsecondary - A MiscType.S_XXX or -1 for don't carelocation - The location to check e.g. Mech.LOC_LARM
public boolean hasWorkingWeapon(java.math.BigInteger flag)
flag - A WeaponType.F_XXX
public boolean hasWorkingWeapon(java.math.BigInteger flag,
long secondary)
flag - A WeaponType.F_XXXsecondary - A WeaponType.S_XXX or -1 for don't care
public boolean hasWorkingWeapon(java.lang.String name)
string - internal name of the weapon.
public boolean hasWorkingWeapon(java.math.BigInteger flag,
int secondary,
int location)
flag - A WeaponType.F_XXXsecondary - A WeaponType.S_XXX or -1 for don't carelocation - The location to check e.g. Mech.LOC_LARM
public abstract int getHeatCapacity()
public abstract int getHeatCapacityWithWater()
public abstract int getEngineCritHeat()
public CriticalSlot getCritical(int loc,
int slot)
public void setCritical(int loc,
int slot,
CriticalSlot cs)
public boolean addCritical(int loc,
CriticalSlot cs)
public boolean addCritical(int loc,
int slot,
CriticalSlot cs)
public void removeCriticals(int loc,
CriticalSlot cs)
public int getEmptyCriticals(int loc)
public int getHittableCriticals(int loc)
public boolean canTransferCriticals(int loc)
public int getGyroType()
-1
public int getGoodCriticals(CriticalSlot cs,
int loc)
public int getGoodCriticals(int type,
int index,
int loc)
public int getBadCriticals(int type,
int index,
int loc)
public int getHitCriticals(int type,
int index,
int loc)
protected abstract int[] getNoOfSlots()
public int getNumberOfCriticals(int loc)
public int getNumberOfCriticals(int type,
int index,
int loc)
public int getNumberOfCriticals(EquipmentType etype,
int loc)
public int getNumberOfCriticals(EquipmentType etype)
public int getNumberOf(EquipmentType etype)
public boolean hasHipCrit()
public boolean hasLegActuatorCrit()
public boolean hasWorkingSystem(int system,
int loc)
public boolean isSystemRepairable(int system,
int loc)
public boolean hasSystem(int system,
int loc)
public boolean hasVibroblades()
false as Only biped mechs can wield
vibrobladespublic int getActiveVibrobladeHeat(int location)
location -
0 as Only biped mechs can wield
vibrobladespublic boolean hasShield()
true if shieldCount is greater then 0
else falsepublic int getNumberOfShields(long size)
public boolean hasActiveShield(int location,
boolean rear)
public boolean hasActiveShield(int location)
public boolean hasPassiveShield(int location,
boolean rear)
public boolean hasPassiveShield(int location)
public boolean hasNoDefenseShield(int location)
public boolean hasUMU()
boolean if the entity has usable UMU crits.public int getActiveUMUCount()
intof useable UMU'spublic int getAllUMUCount()
intTotal number of UMUs a mech has.public boolean hasActiveECM()
public boolean hasActiveECM(boolean stealth)
stealth -
public boolean hasActiveAngelECM()
public boolean hasGhostTargets(boolean active)
public boolean hasActiveECCM()
true if the entity has angelecm and it is in ECCM
mode false if the entity does not have angel ecm or
it is not in eccm mode or it is damaged.public boolean hasActiveAngelECCM()
true if the entity has angelecm and it is in ECCM
mode false if the entity does not have angel ecm or
it is not in eccm mode or it is damaged.public int getECMRange()
int range of this unit's ECM. This value will be
Entity.NONE if no ECM is active.public boolean hasBAP()
public boolean hasBAP(boolean checkECM)
public int getBAPRange()
int range of this unit's BAP. This value will be
Entity.NONE if no BAP is active.public boolean hasTargComp()
public boolean hasAimModeTargComp()
public boolean hasC3S()
public boolean hasCASEII()
public boolean hasCASEII(int location)
location -
public boolean hasC3M()
public boolean hasC3MM()
public boolean hasC3()
public boolean hasC3i()
public java.lang.String getC3NetId()
public void setC3NetId(Entity e)
public int calculateFreeC3MNodes()
Entity.
Please note, if this Entity does not have two C3 Master
computers, then it must first be identified as a company commander;
otherwise the number of free nodes will be zero.
int value.public int calculateFreeC3Nodes()
Entity.
Please note, if this Entity has two C3 Master computers,
then this function only returns the remaining number of C3 Slave
computers that can connect.
int value.public Entity getC3Top()
public Entity getC3Master()
Entity that is the master of this unit's C3
network. This value may be null. If the value master
unit has shut down, then the value will be non-null
after the master unit restarts.public int getC3MasterId()
Entity.NONE is returned is when this unit is
permanently out of the C3 network, or when it was never in a C3 network.
int ID of the unit that is the master of this
unit's C3 network, or Entity.NONE.public boolean C3MasterIs(Entity e)
Entity is the C3 Master of this
unit.
Please note, that when an Entity is it's own C3 Master, then
it is a company commander.
Also note that when null is the master for this
Entity, then it is an independent master.
e - - the Entity that may be this unit's C3 Master.
boolean that is true when the passed
Entity is this unit's commander. If the passed unit
isn't this unit's commander, this routine returns
false.public void setC3Master(Entity e)
Entity as our C3 Master
e - - the Entity that should be set as our C3 Master.public void setC3Master(int entityId)
entityId - public boolean onSameC3NetworkAs(Entity e)
public boolean onSameC3NetworkAs(Entity e,
boolean ignoreECM)
e - The Entity to check against this entityignoreECM - a boolean indicating if ECM should be ignored, we
need this for c3i
boolean that is true if the given
entity is on the same network, false if not.public boolean locationHasCase(int loc)
public void hitAllCriticals(int loc,
int slot)
public void newRound(int roundNumber)
newRound in interface RoundUpdatedroundNumber - the int number of the new roundpublic void applyDamage()
public void reloadEmptyWeapons()
public void assignAMS(java.util.Vector<WeaponHandler> vAttacks)
public boolean isNarcedBy(int nTeamID)
public void attachNarcPod(NarcPod pod)
pod - The NarcPod to be attached.public void attachINarcPod(INarcPod pod)
pod - The INarcPod to be attached.public boolean isINarcedBy(int nTeamID)
nTeamID - The id of the team that we are wondering about.
public boolean isINarcedWith(long type)
type - the int type of iNarc pod.
true if we have.public void removeAllINarcPods()
public boolean hasINarcPodsAttached()
public java.util.Iterator<INarcPod> getINarcPodsAttached()
Enumeration of INarcPods that are
attached to this entity.
Enumeration of INarcPods.public boolean removeINarcPod(INarcPod pod)
INarcPod from this entity.
pod - the INarcPod to be removed.
true if the pod was removed, false if
the pod was not attached to this entity.public abstract int calculateBattleValue()
public int calculateBattleValue(boolean ignoreC3,
boolean ignorePilot)
ignoreC3 - if the contribution of the C3 computer should be ignored when
calculating BV.ignorePilot - if the extra BV due to piloting skill should be ignore, needed
for c3 bvpublic abstract java.util.Vector<Report> victoryReport()
public boolean equals(java.lang.Object object)
equals in class java.lang.Objectpublic EntityMovementMode getMovementMode()
public java.lang.String getMovementModeAsString()
public void setMovementMode(EntityMovementMode movementMode)
public boolean entityIsBiped()
public boolean entityIsQuad()
public boolean needsRollToStand()
public PilotingRollData getBasePilotingRoll()
public PilotingRollData getBasePilotingRoll(EntityMovementType moveType)
public abstract PilotingRollData addEntityBonuses(PilotingRollData roll)
public PilotingRollData addConditionBonuses(PilotingRollData roll,
EntityMovementType moveType)
public PilotingRollData checkGetUp(MoveStep step)
public PilotingRollData checkRunningWithDamage(EntityMovementType overallMoveType)
public PilotingRollData checkSprintingWithMASC(EntityMovementType overallMoveType,
int used)
public PilotingRollData checkSprintingWithSupercharger(EntityMovementType overallMoveType,
int used)
public PilotingRollData checkRecklessMove(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos,
IHex prevHex)
public PilotingRollData checkLandingWithDamage(EntityMovementType overallMoveType)
public PilotingRollData checkLandingInHeavyWoods(EntityMovementType overallMoveType,
IHex curHex)
public PilotingRollData checkLandingOnIce(EntityMovementType overallMoveType,
IHex curHex)
public PilotingRollData checkMovedTooFast(MoveStep step)
PilotingRollData checking for wether this Entity
moved too fast due to low gravity
step -
public PilotingRollData checkSkid(EntityMovementType moveType,
IHex prevHex,
EntityMovementType overallMoveType,
MoveStep prevStep,
int prevFacing,
int curFacing,
Coords lastPos,
Coords curPos,
boolean isInfantry,
int distance)
public PilotingRollData checkRubbleMove(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos)
public PilotingRollData checkBogDown(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos,
int lastElev,
boolean isPavementStep)
public PilotingRollData checkWaterMove(MoveStep step,
IHex curHex,
Coords lastPos,
Coords curPos,
boolean isPavementStep)
public PilotingRollData checkWaterMove(int waterLevel,
EntityMovementType overallMoveType)
public PilotingRollData checkDislodgeSwarmers(MoveStep step)
public int checkMovementInBuilding(MoveStep step,
MoveStep prevStep,
Coords curPos,
Coords prevPos)
public PilotingRollData rollMovementInBuilding(Building bldg,
int distance,
java.lang.String why,
EntityMovementType overallMoveType)
public int getMovementBeforeSkidPSRModifier(int distance)
public abstract int getMaxElevationChange()
public int getMaxElevationDown()
public static java.lang.String encodeTransporters(Entity entity)
Transporters for the
given Entity.
This method should only be used when serializing the
Entity.
entity - - the Entity being serialized.
String listing the Transporter class
names of the Entity. This value will be empty ("")
if the entity has no Transporters.
public static void decodeTransporters(Entity entity,
java.lang.String transporters)
throws java.lang.IllegalStateException
Transporters for the given Entity.
This method should only be used when deserializing the
Entity.
entity - - the Entity being deserialized.transporters - - the String listing the class names of the
Transporters to be set for the
Entity, separated by commas. This value can be
null or empty ("").
java.lang.IllegalStateException - if any error occurs.public void addTransporter(Transporter component)
component - - One of this new entity's Transporters.public void removeAllTransporters()
public boolean canLoad(Entity unit,
boolean checkElev)
unit - - the Entity to be loaded.
true if the unit can be loaded, false
otherwise.public boolean canLoad(Entity unit)
Transporter
canLoad in interface Transporterunit - - the Entity to be loaded.
true if the unit can be loaded, false
otherwise.
public void load(Entity unit,
boolean checkElev)
unit - - the Entity to be loaded.
java.lang.IllegalArgumentException - If the unit can't be loadedpublic void load(Entity unit)
Transporter
load in interface Transporterunit - - the Entity to be loaded.public void recover(Entity unit)
unit - - the Entity to be loaded.
java.lang.IllegalArgumentException - If the unit can't be loadedpublic void updateBays()
public java.lang.String damageBayDoor()
public void damageDoorRecovery(Entity en)
public boolean damageDockCollar()
public void pickUp(MechWarrior mw)
public java.util.List<Entity> getLoadedUnits()
List of the units currently loaded into this payload.
getLoadedUnits in interface TransporterList of loaded Entity units. This
list will never be null, but it may be empty. The
returned List is independant from the under- lying
data structure; modifying one does not affect the other.public int getDocks()
public java.util.Vector<Entity> getBayLoadedUnits()
public java.util.Vector<Entity> getLoadedFighters()
public java.util.Vector<Entity> getLaunchableFighters()
public java.util.Vector<Entity> getDroppableUnits()
public Bay getLoadedBay(int bayID)
public java.util.Vector<Bay> getFighterBays()
public java.util.Vector<Transporter> getTransports()
public java.util.Vector<Bay> getTransportBays()
public void resetBayDoors()
public int getFighterLaunchRate()
public java.util.Vector<Entity> getLoadedSmallCraft()
public java.util.Vector<Entity> getLaunchableSmallCraft()
public java.util.Vector<SmallCraftBay> getSmallCraftBays()
public int getSmallCraftLaunchRate()
public boolean unload(Entity unit)
unload in interface Transporterunit - - the Entity to be unloaded.
true if the unit was contained in this space,
false otherwise.public java.lang.String getUnusedString()
getUnusedString in interface TransporterString meant for a human.
public boolean isWeaponBlockedAt(int loc,
boolean isRear)
isWeaponBlockedAt in interface Transporterloc - - the int location attempting to fire.isRear - - a boolean value stating if the given location
is rear facing; if false, the location is front
facing.
true if a transported unit is in the way,
false if the weapon can fire.
public Entity getExteriorUnitAt(int loc,
boolean isRear)
getExteriorUnitAt in interface Transporterloc - - the int location hit by attack.isRear - - a boolean value stating if the given location
is rear facing; if false, the location is front
facing.
Entity being transported on the outside at that
location. This value will be null if no unit is
transported on the outside at that location.public java.util.ArrayList<Entity> getExternalUnits()
getExternalUnits in interface Transporterpublic int getCargoMpReduction()
getCargoMpReduction in interface Transporter
public HitData getTrooperAtLocation(HitData hit,
Entity transport)
public void setTransportId(int transportId)
Entity that has loaded this unit. A
unit that is unloaded can neither move nor attack for the rest of the
turn.
transportId - - the int ID of our transport. The ID is
not validated. This value should be
Entity.NONE if this unit has been unloaded.public int getTransportId()
Entity that has loaded this one.
int ID of our transport. The ID may be invalid.
This value should be Entity.NONE if this unit has
not been loaded.public boolean isStealthActive()
true if this unit has a stealth system that is
currently active and it's actually working, false if
there is no stealth system or if it is inactive.public boolean isStealthOn()
true if this unit has a stealth system that is
currently active and it's actually working, false if
there is no stealth system or if it is inactive.public boolean isNullSigActive()
true if this unit has a null signature system that
is currently active, false if there is no stealth
system or if it is inactive.public boolean isVoidSigActive()
true if this unit has a void signature system that
is currently active, false if there is no stealth
system or if it is inactive.public boolean isChameleonShieldActive()
true if this unit has a void signature system that
is currently active, false if there is no stealth
system or if it is inactive.
public TargetRoll getStealthModifier(int range,
Entity ae)
range is not one of the
Entity class range constants, an
IllegalArgumentException will be thrown.
Sub-classes are encouraged to override this method.
range - - an int value that must match one of the
Compute class range constants.ae - - the entity making the attack, who maybe immune to certain
kinds of stealth
TargetRoll value that contains the stealth
modifier for the given range.public void setSwarmTargetId(int id)
Entity that is the current target of a
swarm attack by this unit. A unit that stops swarming can neither move
nor attack for the rest of the turn.
id - - the int ID of the swarm attack's target. The ID
is not validated. This value should be
Entity.NONE if this unit has stopped swarming.public int getSwarmTargetId()
Entity that is the current target of a
swarm attack by this unit.
int ID of the swarm attack's target The ID may
be invalid. This value should be Entity.NONE if this
unit is not swarming.public void setSwarmAttackerId(int id)
Entity that is attacking this unit with
a swarm attack.
id - - the int ID of the swarm attack's attacker. The
ID is not validated. This value should be
Entity.NONE if the swarm attack has ended.public int getSwarmAttackerId()
Entity that is attacking this unit with a
swarm attack.
int ID of the swarm attack's attacker The ID may
be invalid. This value should be Entity.NONE if this
unit is not being swarmed.public boolean hasInfernoAmmo()
true if the unit is still loaded with Inferno
rounds. false if no rounds were ever loaded or if
they have all been fired.public void setSalvage(boolean canSalvage)
canSalvage - - a boolean that is true if the unit
can be repaired (given time and parts); if this value is
false, the unit is utterly destroyed.public boolean isSalvage()
boolean that is true if the unit has
salvageable components; if this value is false the
unit is utterly destroyed.isRepairable()public boolean isRepairable()
boolean that is true if the unit can
be repaired (given enough time and parts); if this value is
false, the unit is only a source of spares.isSalvage()public int getRemovalCondition()
public void setRemovalCondition(int removalCondition)
removalCondition - New value of property removalCondition.public boolean isClearingMinefield()
public void setClearingMinefield(boolean clearingMinefield)
clearingMinefield - public boolean isSpotting()
public void setSpotting(boolean spotting)
spotting - public boolean canSpot()
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String statusToString()
public java.lang.String statusToString(int loc)
loc - the location
public java.lang.String statusToString(java.lang.String str)
string - a string defining the location
public void setDeployRound(int deployRound)
deployRound - an intpublic int getDeployRound()
public void setDeployed(boolean deployed)
public boolean isDeployed()
public boolean shouldDeploy(int round)
public void setUnitNumber(char unit)
unit - the char number for the low-level unit that this
entity belongs to. This entity can be removed from its unit by
passing the value, (char) Entity.NONE.public char getUnitNumber()
char unit number. If the entity does not belong
to a unit, (char) Entity.NONE will be returned.public boolean canFlee()
public void setSeenByEnemy(boolean b)
public boolean isSeenByEnemy()
public void setVisibleToEnemy(boolean b)
public boolean isVisibleToEnemy()
protected int applyGravityEffectsOnMP(int MP)
public boolean canCharge()
public boolean canDFA()
public boolean canRam()
public boolean isUsingManAce()
public java.util.Enumeration<Entity> getKills()
public int getKillNumber()
public void addKill(Entity kill)
public boolean getGaveKillCredit()
public boolean isEligibleFor(IGame.Phase phase)
public boolean canAssist(IGame.Phase phase)
public boolean isEligibleForFiring()
public boolean isEligibleForMovement()
public boolean isEligibleForOffboard()
public boolean isAttackingThisTurn()
public boolean isEligibleForPhysical()
public boolean isEligibleForTargetingPhase()
public float getTroopCarryingSpace()
public boolean hasBattleArmorHandles()
public boolean isOffBoard()
isOffBoard in interface Targetable
public void setOffBoard(int distance,
OffBoardDirection direction)
Entity.NONE. If a direction
other than Entity.NONE is chosen, the distance must
not be zero (0).
distance - the int distance in hexes that the unit will be
deployed from the board; this value must not be negative.direction - the int direction from the board that the unit
will be deployed; a valid value must be selected from: NONE,
NORTH, SOUTH, EAST, or WEST.
java.lang.IllegalArgumentException - if a negative distance, an invalid direction is selected, or
the distance does not match the direction.public int getOffBoardDistance()
int distance from the board the unit will be
deployed (in hexes); this value will never be negative.public OffBoardDirection getOffBoardDirection()
IOffBoardDirections.NONE, otherwise it will be one of the
values:
IOffBoardDirections.NORTHIOffBoardDirections.SOUTHIOffBoardDirections.EASTIOffBoardDirections.WEST
int direction from the board the unit will be
deployed. Only valid values will be returned.public void deployOffBoard()
Server after
the board has been selected and all the players are ready to start. The
side effects of this methods set the unit's position and facing as
appropriate (as well as deploying the unit).
Onboard units (units with an offboard distance of zero and a direction of
Entity.NONE) will be unaffected by this method.
public java.util.Vector<java.lang.Integer> getPickedUpMechWarriors()
public boolean isCaptured()
true if it has.public void setCaptured(boolean arg)
arg - the boolean value to assign.public void setSpotlight(boolean arg)
public boolean hasSpotlight()
public void setSpotlightState(boolean arg)
public boolean isIlluminated()
public void setIlluminated(boolean arg)
public boolean isUsingSpotlight()
public void setUsedSearchlight(boolean arg)
public boolean usedSearchlight()
public void illuminateTarget(HexTarget target)
target - the HexTarget to illuminatepublic boolean isStuck()
public void setStuck(boolean arg)
arg - the boolean value to assignpublic boolean canUnstickByJumping()
public void setCanUnstickByJumping(boolean arg)
arg - the boolean value to assign
public java.lang.String destroy(java.lang.String reason,
boolean survivable,
boolean canSalvage)
public void addTargetedBySwarm(int entityId,
int weaponId)
entityId - The int id of the shooting entityweaponId - The int id of the shooting lrm launcher
public boolean getTargetedBySwarm(int entityId,
int weaponId)
entityId - The int id of the shooting entity we are checkingweaponId - The int id of the launcher to check
boolean valuepublic int getShortRangeModifier()
public int getMediumRangeModifier()
public int getLongRangeModifier()
public int getExtremeRangeModifier()
public void setArmorType(int armType)
public void setStructureType(int strucType)
public void setArmorType(java.lang.String armType)
public void setStructureType(java.lang.String strucType)
public int getArmorType()
public void setArmorTechLevel(int newTL)
public int getArmorTechLevel()
public int getStructureType()
public void setWeaponHit(Mounted which)
public void setTaggedBy(int tagger)
public int getTaggedBy()
public abstract double getCost(boolean ignoreAmmo)
public int getWeaponsAndEquipmentCost(boolean ignoreAmmo)
public int getWeaponsAndEquipmentCost(java.lang.StringBuffer detail,
boolean ignoreAmmo)
public boolean removePartialCoverHits(int location,
int cover,
int side)
public boolean isOnSameSheet(Coords tc)
public abstract boolean doomedInVacuum()
public abstract boolean doomedOnGround()
public abstract boolean doomedInAtmosphere()
public abstract boolean doomedInSpace()
public double getArmorWeight()
public boolean hasTAG()
public boolean isCanon()
public void setCanon(boolean canon)
public boolean climbMode()
public void setClimbMode(boolean state)
public boolean usedTag()
public boolean hasEiCockpit()
public boolean hasActiveEiCockpit()
public boolean isLayingMines()
public void setLayingMines(boolean laying)
public boolean canLayMine()
public int sideTable(Coords src)
sideTable in interface Targetable
public int sideTable(Coords src,
boolean usePrior)
sideTable in interface Targetable
public int sideTable(Coords src,
boolean usePrior,
int face)
public boolean canGoHullDown()
public boolean canAssaultDrop()
public void setAssaultDropInProgress(boolean flag)
public void setLandedAssaultDrop()
public boolean isAssaultDropInProgress()
public void addPilotingModifierForTerrain(PilotingRollData roll,
Coords c)
roll - the PSR to modifyc - the coordinates where the PSR happens
public void addPilotingModifierForTerrain(PilotingRollData roll,
MoveStep step)
roll - the PSR to modifystep - the move step the PSR occurs atpublic void addPilotingModifierForTerrain(PilotingRollData roll)
roll - the PSR to modifypublic boolean fixElevation()
public Engine getEngine()
public boolean itemOppositeTech(java.lang.String s)
public OffBoardDirection getRetreatedDirection()
public void setRetreatedDirection(OffBoardDirection retreatedDirection)
retreatedDirection - The retreatedDirection to set.public void setLastTarget(int id)
public int getLastTarget()
public boolean isSufferingEMI()
public void setEMI(boolean inVal)
public abstract boolean isNuclearHardened()
public void setHidden(boolean inVal)
public boolean isHidden()
public boolean isCarcass()
public void setCarcass(boolean carcass)
carcass - true if this unit should be a carcass, false otherwise.isCarcass()public void destroyLocation(int loc)
loc - The location that is destroyed.
public PilotingRollData checkSideSlip(EntityMovementType moveType,
IHex prevHex,
EntityMovementType overallMoveType,
MoveStep prevStep,
int prevFacing,
int curFacing,
Coords lastPos,
Coords curPos,
int distance)
public boolean isAirborneVTOL()
isAirborneVTOL in interface TargetableTargetable.isAirborne()public void setSpotTargetId(int targetId)
public int getSpotTargetId()
public void setCommander(boolean arg)
public boolean isCommander()
public boolean hasLinkedMGA(Mounted mounted)
public void setReckless(boolean b)
public boolean isReckless()
public boolean isFighter()
public boolean isCapitalFighter()
public boolean isCapitalScale()
public boolean usesWeaponBays()
public Mounted whichBay(int bayID)
bayID -
public Mounted getFirstBay(WeaponType wtype,
int loc,
boolean rearMount)
wtype - loc - rearMount -
public int getHeatInArc(int location,
boolean rearMount)
public int[] getVectors()
public void setVectors(int[] v)
public int getVector(int vectorFacing)
public int getVelocity()
public int chooseSide(Coords attackPos,
boolean usePrior)
public java.util.Vector<java.lang.Integer> getHeading()
public void setPassedThrough(java.util.Vector<Coords> pass)
public java.util.Vector<Coords> getPassedThrough()
public void addPassedThrough(Coords c)
public boolean passedThrough(Coords c)
public boolean passedWithin(Coords c,
int dist)
public Coords passedThroughPrevious(Coords c)
public void setRamming(boolean b)
public boolean isRamming()
public void resetFiringArcs()
public boolean hasArcFired(int location,
boolean rearMount)
public void setArcFired(int location,
boolean rearMount)
public void setRapidFire()
public void extendBlade(int loc)
public void destroyRetractableBlade(int loc)
public TeleMissileTracker getTMTracker()
public void setGrappled(int id,
boolean attacker)
public boolean isGrappleAttacker()
public int getGrappled()
public void setGameOptions()
public void setGrappleSide(int side)
public int getGrappleSide()
public boolean hasFunctionalArmAES(int location)
public boolean hasFunctionalLegAES()
public boolean isEvading()
public void setEvading(boolean evasion)
public int getEvasionBonus()
public void setCarefulStand(boolean stand)
public boolean isCarefulStand()
public java.util.Vector<Sensor> getSensors()
public Sensor getActiveSensor()
public Sensor getNextSensor()
public void setNextSensor(Sensor s)
public int getSensorCheck()
public boolean hasModularArmor()
public boolean hasModularArmor(int loc)
public int getDamageReductionFromModularArmor(int loc,
int damage,
java.util.Vector<Report> vDesc)
public int getGhostTargetRoll()
public int getGhostTargetRollMoS()
public int getGhostTargetOverride()
public int getCoolantFailureAmount()
public void addCoolantFailureAmount(int amount)
public int getExtraCommGearTons()
public double getECMStrength()
public double getECCMStrength()
public abstract int getTotalCommGearTons()
public int getHQIniBonus()
public int getMDIniBonus()
public int getQuirkIniBonus()
public void applySantaAnna()
public Mounted getBayByAmmo(Mounted mammo)
mammo -
public int getVibroClaws()
Entity is equipped with
public void baTaserShutdown(int turns)
turns - - the amount of rounds for which this Entity should be
shutdownpublic int getTaserShutdownRounds()
public void setTaserShutdownRounds(int rounds)
public boolean isBATaserShutdown()
public void setBATaserShutdown(boolean value)
public void setTaserFeedback(int rounds)
rounds - - the number of rounds to suffer from taserfeedbackpublic int getTaserFeedBackRounds()
public void setTaserInterference(int value,
int rounds)
public int getTaserInterference()
public int getTaserInterferenceRounds()
public boolean isMilitary()
public boolean isLargeCraft()
public boolean loadedUnitsHaveActiveECM()
public boolean isPartOfFighterSquadron()
public java.lang.String getBVText()
String explaining the BV calculationpublic int getBARRating()
public boolean hasBARArmor()
public boolean hasArmoredChassis()
public boolean hasEnvironmentalSealing()
Entity have Environmental sealing? (only Support
Vehicles or IndustrialMechs should mount this)
public java.util.Vector<Report> doCheckEngineStallRoll(java.util.Vector<Report> vPhaseReport)
vPhaseReport - the Vector containing the phase reports
public void checkUnstall(java.util.Vector<Report> vPhaseReport)
vPhaseReport - the Vector containing the phase reportspublic boolean hasArmoredEngine()
public boolean isStalled()
public boolean isSurfaceNaval()
public void setSource(java.lang.String source)
source - public java.lang.String getSource()
public void setQuirks(Quirks quirks)
public Quirks getQuirks()
public void clearQuirks()
public int countQuirks()
public int countQuirks(java.lang.String grpKey)
public java.lang.String getQuirkList(java.lang.String sep)
public int getForwardArc()
public int getRearArc()
public java.lang.String getSensorDesc()
public boolean isAirborne()
isAirborne in interface TargetableTargetable.isAirborneVTOL()public boolean isNOE()
public int getStartingPos()
public void setStartingPos(int i)
public int getAltitude()
getAltitude in interface Targetablepublic void setAltitude(int a)
public int[] getBombLoadout()
public int getBattleForcePoints()
public long getBattleForceMovementPoints()
public long getBattleForceJumpPoints()
public java.lang.String getMovementModeAsBattleForceString()
public java.lang.String getBattleForceMovement()
public int getBattleForceArmorPoints()
public java.lang.String getBattleForceDamageThresholdString()
public int getBattleForceStructurePoints()
public int getBattleForceStandardWeaponsDamage(int range)
range -
public int getBattleForceStandardWeaponsDamage(int range,
int ammoType)
range - ammoType -
public int getBattleForceStandardWeaponsDamage(int range,
boolean ignoreHeat,
boolean ignoreSpecialAbilities)
range - ignoreHeat - ignoreSpecialAbilities -
public int getBattleForceStandardWeaponsDamage(int range,
int ammoType,
boolean ignoreHeat,
boolean ignoreSpecialAbilities)
range - ammoType - ignoreHeat - if set to true then heat modifier is not used on damageignoreSpecialAbilities - calculate special attacks into total damage if set to true
public int getBattleForceTotalHeatGeneration(boolean allowRear)
public java.lang.String getBattleForceOverHeatValue()
public java.lang.String getBattleForceSpecialAbilites()
public int getBattleForceSize()
protected void printDebugToFile()
public java.util.Map<java.lang.Integer,Coords> getSecondaryPositions()
public boolean hasActiveBlueShield()
true if the entity has a working, switched on blue
field false otherwisepublic int getBlueShieldRounds()
public boolean isDropping()
public boolean hasStealth()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||