1package com.fs.starfarer.api.impl.campaign.intel.bar.events;
5import com.fs.starfarer.api.campaign.econ.CommodityOnMarketAPI;
6import com.fs.starfarer.api.campaign.econ.MarketAPI;
7import com.fs.starfarer.api.characters.PersonAPI;
8import com.fs.starfarer.api.impl.campaign.econ.impl.BaseIndustry;
9import com.fs.starfarer.api.impl.campaign.ids.Commodities;
10import com.fs.starfarer.api.impl.campaign.ids.Factions;
11import com.fs.starfarer.api.impl.campaign.ids.Ranks;
12import com.fs.starfarer.api.impl.campaign.ids.Tags;
13import com.fs.starfarer.api.impl.campaign.intel.contacts.ContactIntel;
14import com.fs.starfarer.api.util.Misc;
23 if (!super.shouldShowAtMarket(
market))
return false;
26 if (!
market.getFactionId().equals(Factions.LUDDIC_CHURCH) &&
27 !
market.getFactionId().equals(Factions.LUDDIC_PATH)) {
31 if (
market.getStabilityValue() < 4)
return false;
34 if (com.getMaxSupply() <= 0)
return false;
35 if (com.getAvailable() < com.getMaxDemand())
return false;
42 return Commodities.FOOD;
52 super.adjustPerson(
person);
54 person.addTag(Tags.CONTACT_TRADE);
59 return Ranks.POST_COMMUNE_LEADER;
64 return Factions.LUDDIC_CHURCH;
77 int size = Math.min(com.getAvailable(), com.getMaxSupply());
78 if (size < 1) size = 1;
80 quantity *= Math.max(1, BaseIndustry.getSizeMult(size) - 2);
91 return "A weathered-looking " +
getManOrWoman() +
" whose worn but well-tailored " +
92 "work suit bears the sigil of a farming commune sits at a table drinking small-beer.";
97 return "Chat up the weathered-looking " +
getManOrWoman() +
"";
103 return Misc.ucFirst(heOrShe) +
" turns out to be the master of a farming commune " +
104 "and " + heOrShe +
" has come \"to town\" to find distributors for their product. " +
105 Misc.ucFirst(heOrShe) +
"'s got %s units of food that has to be moved as soon as possible and " +
106 "if you buy it all today, you'll get an under-market price of %s per unit. " +
107 "And, " + heOrShe +
" says with a wink, \"As pious folk, we need not bother with the Church’s tariff.\",";
112 return new String [] { Misc.getWithDGS(
quantity), Misc.getDGSCredits(
unitPrice) };
116 return new Color [] { Misc.getHighlightColor(), Misc.getHighlightColor() };
121 return "Accept with a firm handshake and cryptokey exchange";
126 return "Decline the deal, and thank " +
getHimOrHer() +
" for the proposal";
131 return "You make arrangements with the farm master for pickup of the cargo from a quiet warehouse " +
132 "on the outskirts of " +
market.getName() +
" and transmit the details " +
133 "to your quartermaster to handle.";
138 return new String [] { };
142 return new Color [] { };
transient TextPanelAPI text
PersonImportance pickLowImportance()
void regen(MarketAPI market)
String[] getAcceptTextTokens()
boolean shouldShowAtMarket(MarketAPI market)
String[] getMainTextTokens()
Color[] getMainTextColors()
void adjustPerson(PersonAPI person)
String getPersonFaction()
void doExtraConfirmActions()
Color[] getAcceptTextColors()