001package com.fs.starfarer.api.impl.campaign.intel.events; 002 003import com.fs.starfarer.api.ui.TooltipMakerAPI; 004import com.fs.starfarer.api.ui.TooltipMakerAPI.TooltipCreator; 005 006public class HAShipsDestroyedFactorHint extends HAShipsDestroyedFactor { 007 008 public HAShipsDestroyedFactorHint() { 009 super(0); 010 timestamp = 0; // makes it not expire 011 } 012 013 @Override 014 public boolean shouldShow(BaseEventIntel intel) { 015 return !hasOtherFactorsOfClass(intel, HAShipsDestroyedFactor.class); 016// for (EventFactor factor : intel.getFactors()) { 017// if (factor != this && factor instanceof HAShipsDestroyedFactor) { 018// return false; 019// } 020// } 021// return true; 022 } 023 024 @Override 025 public TooltipCreator getMainRowTooltip(BaseEventIntel intel) { 026 return new BaseFactorTooltip() { 027 @Override 028 public void createTooltip(TooltipMakerAPI tooltip, boolean expanded, Object tooltipParam) { 029 tooltip.addPara("Destroying hostile ships in or near one of the star systems " 030 + "with your colonies will reduce event progress.", 031 0f); 032 } 033 034 }; 035 } 036 037// @Override 038// public String getProgressStr(BaseEventIntel intel) { 039// return ""; 040// } 041// 042// @Override 043// public Color getDescColor(BaseEventIntel intel) { 044// return Misc.getGrayColor(); 045// } 046 047}