|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmegamek.common.MovePath
megamek.client.bot.MoveOption
public class MoveOption
TODO: add the notion of a dependent state (at least a first pass estimate of worst case threat) for when psr's are made. TODO: add a notion of a blocked move, something that could open up after another mech moves.
| Nested Class Summary | |
|---|---|
static class |
MoveOption.DamageInfo
|
static class |
MoveOption.DistanceComparator
|
static class |
MoveOption.Table
|
static class |
MoveOption.WeightedComparator
|
| Nested classes/interfaces inherited from class megamek.common.MovePath |
|---|
MovePath.Key, MovePath.MovePathComparator, MovePath.MoveStepType |
| Field Summary | |
|---|---|
static int |
ATTACK_MOD
|
static int |
ATTACK_PC
|
(package private) double |
damage
|
(package private) java.util.HashMap<CEntity,MoveOption.DamageInfo> |
damageInfos
|
static int |
DEFENCE_MOD
|
static int |
DEFENCE_PC
|
static MoveOption.DistanceComparator |
DISTANCE_COMPARATOR
|
(package private) boolean |
doomed
|
(package private) boolean |
inDanger
|
(package private) boolean |
isPhysical
|
(package private) double |
movement_threat
|
(package private) double |
self_damage
|
(package private) double |
self_threat
|
(package private) double |
threat
|
(package private) java.util.ArrayList<java.lang.String> |
tv
|
(package private) double |
utility
|
(package private) boolean |
utilityCalculated
|
| Fields inherited from class megamek.common.MovePath |
|---|
DEFAULT_PATHFINDER_TIME_LIMIT, entity, game, steps |
| Constructor Summary | |
|---|---|
MoveOption(IGame game,
CEntity centity)
|
|
MoveOption(MoveOption base)
|
|
| Method Summary | |
|---|---|
MoveOption |
addStep(MovePath.MoveStepType step_type)
Add a new step to the movement path. |
boolean |
changeToPhysical()
|
MoveOption |
clone()
Clones this path, will contain a new clone of the steps so that the clone is independent from the original. |
(package private) CEntity |
getCEntity()
|
double |
getDamage(CEntity e)
|
MoveOption.DamageInfo |
getDamageInfo(CEntity cen,
boolean create)
|
double |
getDistUtility()
|
double |
getMaxModifiedDamage(MoveOption enemy,
int modifier,
int apc)
get maximum damage in this current state from enemy accounting for torso twisting and slightly for heat -- the ce passed in is supposed to be the enemy mech |
double |
getMinDamage(CEntity e)
|
int[] |
getModifiers(Entity te)
TODO: replace with more common logic approximates the attack and defensive modifies assumes that set state has been called |
int |
getMovementheatBuildup()
|
(package private) int |
getPhysicalTargetId()
There could still be a problem here, but now it's the callers problem |
double |
getThreat(CEntity e)
|
double |
getUtility()
TODO: the result of this calculation should be cached... |
void |
setDamage(CEntity e,
double value)
|
void |
setState()
|
void |
setThreat(CEntity e,
double value)
|
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final MoveOption.DistanceComparator DISTANCE_COMPARATOR
public static final int ATTACK_MOD
public static final int DEFENCE_MOD
public static final int ATTACK_PC
public static final int DEFENCE_PC
boolean utilityCalculated
boolean inDanger
boolean doomed
boolean isPhysical
double utility
double self_threat
double movement_threat
double self_damage
double damage
double threat
transient java.util.ArrayList<java.lang.String> tv
transient java.util.HashMap<CEntity,MoveOption.DamageInfo> damageInfos
| Constructor Detail |
|---|
public MoveOption(IGame game,
CEntity centity)
public MoveOption(MoveOption base)
| Method Detail |
|---|
public MoveOption clone()
MovePath
clone in class MovePathpublic double getThreat(CEntity e)
public void setThreat(CEntity e,
double value)
public double getMinDamage(CEntity e)
public double getDamage(CEntity e)
public void setDamage(CEntity e,
double value)
CEntity getCEntity()
public MoveOption addStep(MovePath.MoveStepType step_type)
MovePath
addStep in class MovePathstep_type - the type of movement.public int getMovementheatBuildup()
public boolean changeToPhysical()
public void setState()
public int[] getModifiers(Entity te)
public double getUtility()
public double getMaxModifiedDamage(MoveOption enemy,
int modifier,
int apc)
public MoveOption.DamageInfo getDamageInfo(CEntity cen,
boolean create)
public double getDistUtility()
int getPhysicalTargetId()
public java.lang.String toString()
toString in class MovePath
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||