1package com.fs.starfarer.api.impl.campaign.intel.events;
4import java.util.LinkedHashSet;
8import com.fs.starfarer.api.Global;
9import com.fs.starfarer.api.campaign.StarSystemAPI;
10import com.fs.starfarer.api.campaign.econ.MarketAPI;
11import com.fs.starfarer.api.impl.campaign.ids.Factions;
12import com.fs.starfarer.api.impl.campaign.intel.bases.LuddicPathBaseIntel;
13import com.fs.starfarer.api.impl.campaign.intel.bases.LuddicPathBaseManager;
14import com.fs.starfarer.api.impl.campaign.intel.bases.LuddicPathCellsIntel;
15import com.fs.starfarer.api.impl.campaign.rulecmd.HA_CMD;
16import com.fs.starfarer.api.ui.TooltipMakerAPI;
17import com.fs.starfarer.api.ui.TooltipMakerAPI.TooltipCreator;
18import com.fs.starfarer.api.util.Misc;
29 public void createTooltip(
TooltipMakerAPI tooltip,
boolean expanded, Object tooltipParam) {
31 tooltip.
addPara(
"Use of advanced technology and AI cores attracts the attention of Pathers.", 0f,
34 Set<LuddicPathBaseIntel> seen =
new LinkedHashSet<LuddicPathBaseIntel>();
37 if (base ==
null)
continue;
39 if (seen.contains(base))
continue;
42 if (cells ==
null || cells.
isSleeper())
continue;
51 tooltip.
addPara(
"Active Pather cells on some of your colonies are being supported "
52 +
"by a Pather base" + system +
". %s "
53 +
"will reduce the level of Pather fleet actvity.", opad, h,
54 "Dealing with this base");
60 if (cells ==
null)
continue;
62 tooltip.
addPara(
"Pather cells on some of your colonies have been disrupted, reducing "
63 +
"the Pather interest contribution from these colonies to event progress.", opad,
81 return super.getProgressStr();
87 return super.getProgressColor(
intel);
108 int reduced = Math.round(adjusted);
109 if (progress > 0 && reduced < 1) reduced = 1;
120 return "Technology and AI core use";
139 return getPatherInterest(system, multIfNoCells, multIfSleeper, multIfActive,
false);
148 mult = multIfNoCells;
149 }
else if (
intel.isSleeper()) {
150 mult = multIfSleeper;
156 if (countCellsOnly) interest = 1f;
157 total += (interest * mult);
182 if (
intel ==
null)
continue;
185 if (
intel.isSleeper()) {
186 curr += perSleeperBase + market.getSize() * perSleeperSize;
188 curr += perActiveBase + market.getSize() * perActiveSize;
192 curr += interest * perPointOfInterest;
199 max = Math.round(max * 100f) / 100f;
static SettingsAPI getSettings()
static final String PLAYER
boolean isPlayerVisible()
StarSystemAPI getSystem()
static float getLuddicPathMarketInterest(MarketAPI market)
float getSleeperTimeout()
static LuddicPathBaseIntel getClosestBase(MarketAPI market)
static LuddicPathCellsIntel getCellsForMarket(MarketAPI market)
HostileActivityEventIntel intel
static boolean isPlayerDefeatedPatherExpedition()
static float getPatherInterest(StarSystemAPI system, float multIfNoCells, float multIfSleeper, float multIfActive, boolean countCellsOnly)
float getTotalPatherInterest()
TooltipCreator getTooltip()
StandardLuddicPathActivityCause2(HostileActivityEventIntel intel)
float getMagnitudeContribution(StarSystemAPI system)
Color getProgressColor(BaseEventIntel intel)
static float getPatherInterest(StarSystemAPI system, float multIfNoCells, float multIfSleeper, float multIfActive)
static boolean playerHasPatherAgreement()
static List< MarketAPI > getMarketsInLocation(LocationAPI location, String factionId)
static List< StarSystemAPI > getPlayerSystems(boolean includeNonPlayerFaction)
static Color getHighlightColor()
static List< MarketAPI > getPlayerMarkets(boolean includeNonPlayerFaction)
static Color getPositiveHighlightColor()
float getFloat(String key)
String getNameWithLowercaseTypeShort()
static String NEGATED_FACTOR_PROGRESS