Class ApplyCRDamage
java.lang.Object
com.fs.starfarer.api.impl.campaign.rulecmd.BaseCommandPlugin
com.fs.starfarer.api.impl.campaign.rulecmd.ApplyCRDamage
- All Implemented Interfaces:
CommandPlugin
ApplyCRDamage
ApplyCRDamage $entity.fleetPoints 0.2 1 "Vindictive search"
The first param is the base number of fleet points for the amount of CR damage to do -
so, for an inspection it's based on the fleet points of the inspecting fleet, but it
could also just be a flat number, or based on the player fleet if
we wanted something like "half your ships take CR damage"
The second param is the multiplier for that number (basically, making up for the fact that you
can't say "$fleetPoints * 0.2" in rules - so the multiplication happens inside the command.
So you could have a more or less vindictive inspection by tuning this param
The third param is the multiplier for the CR damage each selected ship takes;
with it == 1 it's "half the recovery cost plus 1-10%"
Fourth param is the description for this CR loss event in the ship's CR tooltip
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
applyCRDamage
(CampaignFleetAPI fleet, float damageFP, float crMult, String desc, TextPanelAPI text, Random random) boolean
execute
(String ruleId, InteractionDialogAPI dialog, List<Misc.Token> params, Map<String, MemoryAPI> memoryMap) Methods inherited from class com.fs.starfarer.api.impl.campaign.rulecmd.BaseCommandPlugin
doesCommandAddOptions, getEntityMemory, getOptionOrder
-
Constructor Details
-
ApplyCRDamage
public ApplyCRDamage()
-
-
Method Details
-
execute
public boolean execute(String ruleId, InteractionDialogAPI dialog, List<Misc.Token> params, Map<String, MemoryAPI> memoryMap) -
applyCRDamage
public static void applyCRDamage(CampaignFleetAPI fleet, float damageFP, float crMult, String desc, TextPanelAPI text, Random random)
-