Package megamek.client.bot.princess
Class PathEnumerator
java.lang.Object
megamek.client.bot.princess.PathEnumerator
This class contains logic that calculates and stores a) possible paths that units in play can take, and b) their
possible locations
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetEntitiesWithLocation(Coords location, boolean groundOnly) protected GamegetGame()protected Map<Integer, CoordFacingCombo> protected Map<Integer, List<BulldozerMovePath>> getSimilarUnitPaths(int moverId, BulldozerMovePath prunedPath) Find paths with a similar direction and step count to the provided path, within the selected unit's already-computed unit paths.protected Map<Integer, Set<CoordFacingCombo>> booleanisLegalAeroMove(MovePath path) voidrecalculateMovesFor(Entity mover) Calculate what to do on my turn.
-
Constructor Details
-
PathEnumerator
-
-
Method Details
-
getEntitiesWithLocation
-
recalculateMovesFor
Calculate what to do on my turn. Has a retry mechanism for when the turn calculation fails due to concurrency issues -
isLegalAeroMove
Returns whether aMovePathis legit for anAerounit isMoveLegal() seems to disagree with me on some aero moves, but I can't exactly figure out why, and who is right. So, I'm just going to put a list of exceptions here instead of possibly screwing upMovePath.isMoveLegal()for everyone. I think it has to do with fly off or return at the end of a move. This also affects clip to possible- Parameters:
path- The path to be examined.- Returns:
- TRUE if the path is legal.
-
getLongRangePaths
-
getUnitPaths
-
getUnitMovableAreas
-
getUnitPotentialLocations
-
getLastKnownLocations
-
getGame
-
getSimilarUnitPaths
Find paths with a similar direction and step count to the provided path, within the selected unit's already-computed unit paths.
-