Package com.fs.starfarer.api.combat
Interface CombatFleetManagerAPI
public interface CombatFleetManagerAPI
- Author:
- Alex Mosolov Copyright 2012 Fractal Softworks, LLC
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionvoid
addToReserves
(FleetMemberAPI member) boolean
createWaypoint
(org.lwjgl.util.vector.Vector2f location, boolean ally) int
float
float
float
float
May return null if both the reserves and the deployed lists are empty.getGoal()
int
Max deployment points available.int
getOwner()
getShipFor
(PersonAPI captain) getShipFor
(FleetMemberAPI fleetMember) Returns ship that corresponds to the fleet member passed in.getTaskManager
(boolean ally) boolean
boolean
boolean
boolean
boolean
void
modifyFlatMax
(String source, int value) void
modifyPercentMax
(String source, float percent) void
removeDeployed
(FighterWingAPI wing, boolean retreated) void
removeDeployed
(ShipAPI ship, boolean retreated) void
removeFromReserves
(FleetMemberAPI member) void
setAdmiralAI
(AdmiralAIPlugin admiralAI) void
setCanForceShipsToEngageWhenBattleClearlyLost
(boolean canForceShipsToEngageWhenBattleClearlyLost) Defaults to true for enemy, false for player side.void
setDefaultCommander
(PersonAPI defaultCommander) void
setDeployedStation
(boolean deployedStation) void
setDeploymentYOffset
(float deploymentYOffset) void
setMaxStrength
(int maxStrength) void
setSuppressDeploymentMessages
(boolean suppressDeploymentMessages) spawnFleetMember
(FleetMemberAPI member, org.lwjgl.util.vector.Vector2f location, float facing, float initialBurnDur) member does not actually have to be in the reserves.spawnShipOrWing
(String specId, org.lwjgl.util.vector.Vector2f location, float facing) Deploy a ship/fighter wing with the given spec or variant id.spawnShipOrWing
(String specId, org.lwjgl.util.vector.Vector2f location, float facing, float initialBurnDur) Deploy a ship/fighter wing with the given spec or variant id.spawnShipOrWing
(String specId, org.lwjgl.util.vector.Vector2f location, float facing, float initialBurnDur, PersonAPI captain) void
-
Method Details
-
spawnShipOrWing
Deploy a ship/fighter wing with the given spec or variant id. If there isn't one in the reserves, a temporary FleetMemberAPI is created and added to the reserves (but not the underlying CampaignFleetAPI, if any)- Parameters:
id
-location
- Where to deploy.facing
- Facing at time of deployment.- Returns:
-
spawnShipOrWing
ShipAPI spawnShipOrWing(String specId, org.lwjgl.util.vector.Vector2f location, float facing, float initialBurnDur) Deploy a ship/fighter wing with the given spec or variant id. If there isn't one in the reserves, a temporary FleetMemberAPI is created and added to the reserves (but not the underlying CampaignFleetAPI, if any)- Parameters:
specId
-location
-facing
-level
- crew experience levelinitialBurnDur
- amount of time travel drive should be on (in seconds)- Returns:
-
spawnFleetMember
ShipAPI spawnFleetMember(FleetMemberAPI member, org.lwjgl.util.vector.Vector2f location, float facing, float initialBurnDur) member does not actually have to be in the reserves.- Parameters:
member
-location
-facing
-initialBurnDur
-- Returns:
-
getShipFor
Returns ship that corresponds to the fleet member passed in. Returns the wing leader for fighter wings.- Parameters:
fleetMember
-- Returns:
-
getDeployedCopy
List<FleetMemberAPI> getDeployedCopy() -
getReservesCopy
List<FleetMemberAPI> getReservesCopy() -
getDeployedFleetMember
-
getDeployedFleetMemberEvenIfDisabled
-
createWaypoint
-
getGoal
FleetGoal getGoal() -
addToReserves
-
removeFromReserves
-
getTaskManager
-
isOnlyTimidOrNonCombatDeployed
boolean isOnlyTimidOrNonCombatDeployed() -
getDisabledCopy
List<FleetMemberAPI> getDisabledCopy() -
getDestroyedCopy
List<FleetMemberAPI> getDestroyedCopy() -
getRetreatedCopy
List<FleetMemberAPI> getRetreatedCopy() -
isSuppressDeploymentMessages
boolean isSuppressDeploymentMessages() -
setSuppressDeploymentMessages
void setSuppressDeploymentMessages(boolean suppressDeploymentMessages) -
isDefendingStation
boolean isDefendingStation() -
getStations
List<DeployedFleetMemberAPI> getStations() -
getDeployedCopyDFM
List<DeployedFleetMemberAPI> getDeployedCopyDFM() -
getOwner
int getOwner() -
setDefaultCommander
-
getDefaultCommander
PersonAPI getDefaultCommander() -
getFleetCommander
PersonAPI getFleetCommander()May return null if both the reserves and the deployed lists are empty.- Returns:
-
getMaxStrength
int getMaxStrength()Max deployment points available.- Returns:
-
isDeployedStation
boolean isDeployedStation() -
setDeployedStation
void setDeployedStation(boolean deployedStation) -
setDeploymentYOffset
void setDeploymentYOffset(float deploymentYOffset) -
getDeploymentYOffset
float getDeploymentYOffset() -
getEnemyCleanDisengageProgress
float getEnemyCleanDisengageProgress() -
getEnemyCleanDisengageThreshold
float getEnemyCleanDisengageThreshold() -
getEnemyCleanDisengagePoints
float getEnemyCleanDisengagePoints() -
canEnemyDisengageCleanly
boolean canEnemyDisengageCleanly() -
getAllFleetCommanders
-
getFleetCommanderPreferPlayer
PersonAPI getFleetCommanderPreferPlayer() -
getAllEverDeployedCopy
List<DeployedFleetMemberAPI> getAllEverDeployedCopy() -
isCanForceShipsToEngageWhenBattleClearlyLost
boolean isCanForceShipsToEngageWhenBattleClearlyLost() -
setCanForceShipsToEngageWhenBattleClearlyLost
void setCanForceShipsToEngageWhenBattleClearlyLost(boolean canForceShipsToEngageWhenBattleClearlyLost) Defaults to true for enemy, false for player side.- Parameters:
canForceShipsToEngageWhenBattleClearlyLost
-
-
spawnShipOrWing
-
getShardToOriginalShipMap
Map<DeployedFleetMemberAPI,DeployedFleetMemberAPI> getShardToOriginalShipMap() -
getDeployedFleetMemberFromAllEverDeployed
-
getShipFor
-
getBiggestStationDeployedOrNot
FleetMemberAPI getBiggestStationDeployedOrNot() -
getAdmiralAI
AdmiralAIPlugin getAdmiralAI() -
setAdmiralAI
-
removeDeployed
-
setMaxStrength
void setMaxStrength(int maxStrength) -
getCurrStrength
int getCurrStrength() -
modifyFlatMax
-
modifyPercentMax
-
unmodifyMax
void unmodifyMax() -
removeDeployed
-