public class FactionHostilityEvent extends BaseEventPlugin
| Modifier and Type | Class and Description |
|---|---|
static class |
FactionHostilityEvent.FactionHostilityPairKey |
BaseEventPlugin.MarketFilterCampaignEventPlugin.CampaignEventCategory, CampaignEventPlugin.PriceUpdatePluginCampaignEventListener.FleetDespawnReason| Modifier and Type | Field and Description |
|---|---|
protected float |
duration |
protected float |
elapsedDays |
protected boolean |
ended |
static float |
HOSTILITY_PENALTY |
static org.apache.log4j.Logger |
log |
protected FactionAPI |
one |
protected float |
prevRel |
protected float |
prevRelOne |
protected float |
prevRelTwo |
protected FactionHostilityEvent.FactionHostilityPairKey |
target |
protected FactionAPI |
two |
entity, eventTarget, eventType, faction, market, memory, started, startProbability, statModId| Constructor and Description |
|---|
FactionHostilityEvent() |
| Modifier and Type | Method and Description |
|---|---|
void |
advance(float amount) |
boolean |
callEvent(java.lang.String ruleId,
InteractionDialogAPI dialog,
java.util.List<Misc.Token> params,
java.util.Map<java.lang.String,MemoryAPI> memoryMap)
Called by the CallEvent command (called from rules.csv).
|
protected void |
endEvent() |
java.lang.String |
getEventName() |
java.lang.String[] |
getHighlights(java.lang.String stageId)
Since multiple reports (possibly from different channels) are possible per stage:
1) All reports must have the highlighted text occur in the same order, which is the order
this method returns them in, and
2) Not all highlights have to occur in every report.
|
java.util.Map<java.lang.String,java.lang.String> |
getTokenReplacements()
Token values for filling out descriptions from reports.csv.
|
void |
init(java.lang.String type,
CampaignEventTarget eventTarget)
Called when the EventProbability for this event is accessed.
|
boolean |
isDone() |
void |
startEvent()
Called when the event starts.
|
protected void |
startHostilities() |
addFactionNameTokens, addPersonTokens, addTokensToList, allowMultipleOngoingForSameTarget, cleanup, findMatchingMarkets, findNearestMarket, getCurrentImage, getCurrentMessageIcon, getDefaultPriority, getEventCategory, getEventIcon, getEventTarget, getEventType, getHighlightColors, getId, getLoggingId, getMemory, getPriceUpdates, getRelatedCommodities, getStageIdForLikely, getStageIdForPossible, getStatModId, getTargetName, getWarningWhenLikelyPriority, getWarningWhenPossiblePriority, increaseRecentUnrest, init, isEventStarted, reportBattleFinished, reportBattleOccurred, reportEconomyMonthEnd, reportEconomyTick, reportEncounterLootGenerated, reportFleetDespawned, reportFleetJumped, reportFleetReachedEntity, reportFleetSpawned, reportPlayerActivatedAbility, reportPlayerClosedMarket, reportPlayerDeactivatedAbility, reportPlayerDidNotTakeCargo, reportPlayerDumpedCargo, reportPlayerEngagement, reportPlayerMarketTransaction, reportPlayerOpenedMarket, reportPlayerOpenedMarketAndCargoUpdated, reportPlayerReputationChange, reportPlayerReputationChange, reportShownInteractionDialog, setParam, setProbability, setTarget, showAllMessagesIfOngoing, showLatestMessageIfOngoing, startEvent, useEventNameAsIdpublic static final float HOSTILITY_PENALTY
public static org.apache.log4j.Logger log
protected float elapsedDays
protected float duration
protected FactionHostilityEvent.FactionHostilityPairKey target
protected FactionAPI one
protected FactionAPI two
protected boolean ended
protected float prevRel
protected float prevRelOne
protected float prevRelTwo
public FactionHostilityEvent()
public void init(java.lang.String type, CampaignEventTarget eventTarget)
CampaignEventPlugininit in interface CampaignEventPlugininit in class BaseEventPluginpublic void startEvent()
CampaignEventPluginstartEvent in interface CampaignEventPluginstartEvent in class BaseEventPluginprotected void startHostilities()
public void advance(float amount)
advance in interface CampaignEventPluginadvance in class BaseEventPluginprotected void endEvent()
public java.lang.String getEventName()
getEventName in interface CampaignEventPlugingetEventName in class BaseEventPluginpublic boolean callEvent(java.lang.String ruleId, InteractionDialogAPI dialog, java.util.List<Misc.Token> params, java.util.Map<java.lang.String,MemoryAPI> memoryMap)
CampaignEventPlugincallEvent in interface CampaignEventPlugincallEvent in interface CallEvent.CallableEventcallEvent in class BaseEventPluginpublic java.util.Map<java.lang.String,java.lang.String> getTokenReplacements()
CampaignEventPlugingetTokenReplacements in interface CampaignEventPlugingetTokenReplacements in class BaseEventPluginpublic java.lang.String[] getHighlights(java.lang.String stageId)
CampaignEventPlugingetHighlights in interface CampaignEventPlugingetHighlights in class BaseEventPluginpublic boolean isDone()
isDone in interface CampaignEventPluginisDone in class BaseEventPlugin