Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.98a is out! (03/27/25)

Pages: 1 ... 97 98 [99] 100

Author Topic: [0.98a] Console Commands v2025.03.30  (Read 1951554 times)

Akie

  • Ensign
  • *
  • Posts: 3
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1470 on: January 26, 2025, 05:28:00 AM »

 :)
Logged

Akie

  • Ensign
  • *
  • Posts: 3
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1471 on: January 26, 2025, 05:28:35 AM »

a
Logged

markepicboss

  • Ensign
  • *
  • Posts: 2
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1472 on: January 28, 2025, 01:59:36 PM »

is there a way to add all special items? i know it isn't a command but is there something special I can put in as a prompt to just give me all the special items?
Logged

Philo_sophist

  • Ensign
  • *
  • Posts: 21
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1473 on: February 02, 2025, 08:21:12 PM »

Anyone know a command to improve relations with contacts/specific characters?
Logged

Philo_sophist

  • Ensign
  • *
  • Posts: 21
    • View Profile
Re: [0.95.1a] Console Commands v2021.12.25
« Reply #1474 on: February 02, 2025, 09:22:25 PM »

I know there's a command to adjust relations with factions. That's a great one. But is there a command for adjusting the relationship meter of specific NPCs?

For example, Iron Shell mod has a few NPCs that have bonuses if you grind up their relationship. But only one of them has the easy path of "give AI cores, improve relationship with NPC". I'd love a way to skip all the specific mission grinding.

Looking for info on this as well
Logged

Philo_sophist

  • Ensign
  • *
  • Posts: 21
    • View Profile
Re: [0.95.1a] Console Commands v2021.12.25
« Reply #1475 on: February 02, 2025, 09:24:06 PM »

Is there a way to change relations with a character, not a faction?

You have to turn on Devmode and then interact with the individual.

Thanks for this info - is there any way to do this with console commands directly? Or is devmode the only known method?
Logged

Kiba

  • Ensign
  • *
  • Posts: 19
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1476 on: February 23, 2025, 06:47:46 AM »

Is there a way to add plain +x to stability on a market? Needed to counter a bug in Ashes of the Domain mod :(
Logged

Burminsky

  • Ensign
  • *
  • Posts: 13
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1477 on: March 04, 2025, 12:15:12 PM »

Is it possible to change the size of existing planets?

I'll answer myself - this can be done by changing the save file.
« Last Edit: March 04, 2025, 12:43:52 PM by Burminsky »
Logged

AzulaBestGirl

  • Ensign
  • *
  • Posts: 30
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1478 on: March 13, 2025, 04:37:08 AM »

Why does `help` not list all commands? How would I even list all commands? How am I reasonably to find `RemoveCondition`?

EDIT: I started reading the source code and noticed that `list` can `list commands`. I just find it odd that help doesn't mention this. Reading the code or javadoc is a bit of a high ask IMHO.

There's also something I don't fully get. But it's probably in the game's code, not the mod code. I see that you can add condition "Teran" to a world. And most others, Jungle, Barren, etc. Not Toxic though. HOWEVER, it does not change the world. I'm guessing that the world is just a tag, and changing the tag doesn't affect the visuals? But it creates this very odd scenario where I add `Teran` to a lifeless Barren world with no atmosphere. But, again. I'm guessing that the condition is supplied by the game's api, and changing a planet from Baren to Teran is outside the scope of the command.

EDIT 2:

Yep, looking in the save file. The planet type is just a `<type>` tag. You'd also need to change other stuff. For example barren worlds don't have `atmosphereColor`. And tagging a previously barren world as `Teran` with no `atmosphereColor` makes the planet still look barren. I think.
« Last Edit: March 13, 2025, 07:40:30 AM by AzulaBestGirl »
Logged

kaine3d

  • Ensign
  • *
  • Posts: 7
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1479 on: March 20, 2025, 08:37:09 AM »

is there a command to add a particular person as a contact on a market? i'm running armaa and just picked up dawn into my group before i did that, i did actually remember to ask for her boss, Sera Pha's contact info and she gave it to me but it seems like said info has disappeared from my list..... nevermind it was there it was just in a different group on the intel screen hmmmm suppose this could be useful for later
Logged

EpicSOB

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1480 on: March 28, 2025, 12:50:40 PM »

can someone explain why this command is not working for planets I didn't place myself. it is from this same thread, the last post on page 55

Code
runcode String _planetId = "Planet_ID";
SectorEntityToken _fleet = Global.getSector().getPlayerFleet();
StarSystemAPI _sys = (StarSystemAPI)_fleet.getContainingLocation();
SectorEntityToken _planet = _sys.getEntityById(_planetId);
float _orbitRadius = com.fs.starfarer.api.util.Misc.getDistance(_fleet.getLocation(), _planet.getLocation());
float _orbitDays = _orbitRadius / (20f + new Random().nextFloat() * 10f);
_sys.addRingBand(_planet,
"misc",
"rings_special0",
512,
1,
Color.RED,
256,
_orbitRadius,
_orbitDays)

it throws this error unless i created the planet. I even tried to copy and paste the id directly from the list command, and it still throws the error.
Code
2121426 [Thread-2] ERROR org.lazywizard.console.Console  - Execution failed:
java.lang.NullPointerException: Cannot invoke "com.fs.starfarer.api.campaign.SectorEntityToken.getLocation()" because "<local3>" is null
Logged

Wyvern

  • Admiral
  • *****
  • Posts: 4091
    • View Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1481 on: March 28, 2025, 12:56:08 PM »

So that looks like "_planet" (what's with the leading underscores? Weird coding style) is null. Presumably this means that you're feeding in the wrong ID value.

Try instead: "SectorEntityToken planet = $context.getEntityInteractedWith();" - this will get the planet your fleet is currently interacting with (but does require that you get your fleet to specifically that planet, so it's a bit less convenient than going by planet ID.)
Logged
Wyvern is 100% correct about the math.

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1374
    • View Profile
    • GitHub Profile
Re: [0.98a] Console Commands v2025.03.30
« Reply #1482 on: March 30, 2025, 10:55:02 AM »

I've put up a dev version with 0.98a support, you can grab it here.

I've been busy the past few days so this has had absolutely minimal testing. Please let me know of any bugs you encounter!
Logged
Active mods: LazyLib | Combat Radar | Console Commands | Version Checker  ||  Old mods: Autosave | Omnifactory | Simulator Overhaul
Feel free to use any code I've written or PM me for help with your own. Anyone is free to translate my work.

LazyWizard

  • Global Moderator
  • Admiral
  • *****
  • Posts: 1374
    • View Profile
    • GitHub Profile
Re: [0.97a] Console Commands v2024.10.04
« Reply #1483 on: March 30, 2025, 11:11:07 AM »

Why does `help` not list all commands? How would I even list all commands? How am I reasonably to find `RemoveCondition`?

Help lists the commands that work in the current context. So if you're docked with a colony RemoveCondition would show up, but it wouldn't be visible if you used Help while in combat. You can use 'help all' to list all commands.

Help's output should mention this; if it doesn't then a bug was introduced somewhere.


EDIT: I started reading the source code and noticed that `list` can `list commands`. I just find it odd that help doesn't mention this. Reading the code or javadoc is a bit of a high ask IMHO.

There are a few commands that can list the loaded commands in addition to whatever else they do. "List commands" is one of them, "Status" is another. But neither is the intended way to find out about new commands, Help is. I'll look into making "help all" more visible.

As for what things list can show, that's displayed with "help list". You should never need to look at the source to know how anything works. If you do, let me know and I'll try and make things clearer. :)


There's also something I don't fully get. But it's probably in the game's code, not the mod code. I see that you can add condition "Teran" to a world. And most others, Jungle, Barren, etc. Not Toxic though. HOWEVER, it does not change the world. I'm guessing that the world is just a tag, and changing the tag doesn't affect the visuals? But it creates this very odd scenario where I add `Teran` to a lifeless Barren world with no atmosphere. But, again. I'm guessing that the condition is supplied by the game's api, and changing a planet from Baren to Teran is outside the scope of the command.

EDIT 2:

Yep, looking in the save file. The planet type is just a `<type>` tag. You'd also need to change other stuff. For example barren worlds don't have `atmosphereColor`. And tagging a previously barren world as `Teran` with no `atmosphereColor` makes the planet still look barren. I think.

Changing a planet's appearance is somewhat complicated and would require RunCode at the moment. The tag is used by the game when generating the planet to add a bunch of tag-specific stuff like conditions and setting its appearance, and merely changing the tag mid-game won't run all that planet generation code again.

You can check out com/fs/starfarer/api/impl/campaign/procgen/StarSystemGenerator.java in starsector-core/starfarer.api.zip for an example of how planets are set up, but be warned that a) there's a lot of code that goes into generating planets, and b) in addition to adding anything that planet type needs, you'll also have to remove any of the old stuff that no longer applies.
« Last Edit: March 30, 2025, 11:14:51 AM by LazyWizard »
Logged
Active mods: LazyLib | Combat Radar | Console Commands | Version Checker  ||  Old mods: Autosave | Omnifactory | Simulator Overhaul
Feel free to use any code I've written or PM me for help with your own. Anyone is free to translate my work.

WhisperDSP

  • Captain
  • ****
  • Posts: 350
    • View Profile
Re: [0.98a] Console Commands v2025.03.30
« Reply #1484 on: March 31, 2025, 05:33:06 AM »

Cannot respec a found level 7 officer.

This is the officer involved and their original elite selection:



Got the skill/story points back alright, mentored them for the wider selection of skills:



Yet cannot go past level 6, and cannot make any skills elite even when doing a retrain:



A found level 5 officer respec'd with no issues and could choose elite skills:


Edit:

Tried with both the latest 2025 (unstable) and 2024 version of Console Commands.

(I suspect this is because the game code for officer leveling is hard-coded and maxes out at 6, if your character has the Officer Training skill.)
« Last Edit: March 31, 2025, 05:36:41 AM by WhisperDSP »
Logged
Pages: 1 ... 97 98 [99] 100