Starsector 0.97a is out! (02/02/24); New blog post: Simulator Enhancements (03/13/24)
Hello, sorry to disturb you but how can I use your old command "survey all"? May I create it? Or you will create it later?
*cough* try tossing the PK into a black hole *cough*
runcode import com.fs.starfarer.api.util.Misc; String planetName = "Gigantus"; float planetOrbitDays = 2000; float planetSize = 300; Vector2f playerCoords = $playerFleet.getLocation(); float angleCCW = Misc.getAngleInDegreesStrict(playerCoords); StarSystemAPI sys = (StarSystemAPI)$playerFleet.getContainingLocation(); PlanetAPI star = sys.getStar(); float orbitRadius = Misc.getDistance(star.getLocation(), playerCoords); PlanetAPI planet = sys.addPlanet(planetName, star, planetName, "gas_giant", angleCCW, planetSize, orbitRadius, planetOrbitDays ); MarketAPI market = sys.getEntityById(planetName).getMarket(); market.addCondition("volatiles_plentiful"); market.addCondition("IndEvo_RuinsCondition"); market.addCondition("US_floating"); market.addCondition("ruins_vast");
runcode import com.fs.starfarer.api.util.Misc; String planetName = "Gigantus"; Vector2f playerCoords = $playerFleet.getLocation(); float angleCCW = Misc.getAngleInDegreesStrict(playerCoords); StarSystemAPI sys = (StarSystemAPI)$playerFleet.getContainingLocation(); PlanetAPI star = sys.getStar(); float orbitRadius = Misc.getDistance(star.getLocation(), playerCoords); sys.addCustomEntity(null, null, "coronal_tap", null).setCircularOrbitPointingDown(star, angleCCW, orbitRadius, 360);
(requires LazyLib 2.6 and Starsector 0.95a-RC10 or higher!)
Quote from: Kurtdovah on April 16, 2021, 01:50:57 AMHello, sorry to disturb you but how can I use your old command "survey all"? May I create it? Or you will create it later?Was it removed? I think I just used it not long ago... but I might be mistaken by memory.
Was wondering it would be possible to add a colony industry modifier to make them improved (without having to add/use story points). I.E. something like "addindustry farming soil_nanites alpha_core improved"
runcode import com.fs.starfarer.api.campaign.SpecialItemData; String marketName = "Your_Market_Name"; String industryID = "farming"; IndustrySpecAPI spec = Global.getSettings().getIndustrySpec(industryID); if (spec == null) { Console.showMessage("Error - industry not found: " + industryID); return; } MarketAPI market = CommandUtils.findBestMarketMatch(marketName); if (market == null) { Console.showMessage("Error - market not found: " + marketName); return; } market.addIndustry(industryID); Industry industry = market.getIndustry(industryID); industry.setImproved(true); industry.setAICoreId("alpha_core"); industry.setSpecialItem(new SpecialItemData("soil_nanites", null));
runcode import com.fs.starfarer.api.campaign.SpecialItemData; String marketName = "Your_Market_Name"; String industryID = "spaceport"; MarketAPI market = CommandUtils.findBestMarketMatch(marketName); if (market == null) { Console.showMessage("Error - market not found: " + marketName); return; } if (market.hasIndustry(industryID) == false) { Console.showMessage("Error - market does not have industry " + industryID); return; } Industry industry = market.getIndustry(industryID); industry.setImproved(true); industry.setAICoreId("alpha_core"); industry.setSpecialItem(new SpecialItemData("fullerene_spool", null));
was experimenting with the add/remove condition commands and ive found a problem: removecondition does not properly remove the parasitic spores condition from the unknown skies mod
removecondition us_mind
It does if you use:Coderemovecondition us_mind