001package com.fs.starfarer.api.campaign.econ; 002 003import java.awt.Color; 004import java.util.List; 005import java.util.Map; 006 007import com.fs.starfarer.api.ui.TooltipMakerAPI; 008 009 010public interface MarketConditionPlugin { 011 012 void advance(float amount); 013 014 void init(MarketAPI market, MarketConditionAPI condition); 015 void apply(String id); 016 void unapply(String id); 017 018 019 /** 020 * Only used for conditions that come from events. 021 * @return 022 */ 023 List<String> getRelatedCommodities(); 024 025 026 /** 027 * For the description that shows up in the tooltip. 028 * @return 029 */ 030 Map<String, String> getTokenReplacements(); 031 032 /** 033 * For the description, which is shown in the tooltip. 034 * @return 035 */ 036 String [] getHighlights(); 037 Color [] getHighlightColors(); 038 039 void setParam(Object param); 040 041 /** 042 * Return false if the plugin has data that needs to be in the savefile. Otherwise, it won't be saved. 043 * @return 044 */ 045 boolean isTransient(); 046 boolean showIcon(); 047 boolean isPlanetary(); 048 049 050 boolean hasCustomTooltip(); 051 void createTooltip(TooltipMakerAPI tooltip, boolean expanded); 052 boolean isTooltipExpandable(); 053 float getTooltipWidth(); 054 055 boolean runWhilePaused(); 056 057 String getName(); 058 String getIconName(); 059} 060 061 062