Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.9.1a is out! (05/10/19); Blog post: Personal Contacts (08/13/20)

Pages: 1 ... 319 320 [321] 322 323 ... 453

Author Topic: Misc modding questions that are too minor to warrant their own thread  (Read 991977 times)

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 16913
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4800 on: August 15, 2019, 11:02:40 AM »

Alright, so i forgot to mention that i also reduced the stockpile consumption rate when there is a demand as well.

That only matters for colonies with "use local stockpiles to counter unmet demand" set, so, pretty much player colonies plus Galatia during the tutorial, iirc.


I don't think messing with the rate at which stockpiles refill would break anything. If you change the maximum stockpiles, though, I think that would affect prices.
Logged

Salv

  • Lieutenant
  • **
  • Posts: 56
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4801 on: August 15, 2019, 11:38:58 AM »

 That's all i needed to know. Thank you for clearing things up.
Logged

TrashMan

  • Admiral
  • *****
  • Posts: 1314
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4802 on: August 16, 2019, 01:02:55 AM »

I have a question abut Ground Support Package. How does it work beneath the hood?

Does the number of ships with it matter? Does it only work on troop transports or would any ship equip with it give a bonus? Does it scale?
Logged

Salv

  • Lieutenant
  • **
  • Posts: 56
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4803 on: August 16, 2019, 01:21:33 AM »

So i did manage to get the economy to start stabilized but the problem with the discrepancy between the stockpile in a colony and its supply and demand still persists. Now i reduced the rate the stockpile is removed in addAndRemoveStockpiledResources to compensate for the reduced add rate. I set both to be 10x slower to more easily observe the changes.

To illustrate the problem, a colony needs 4000 fuel so i sell them the amount and fulfill that demand. The demand is at zero, and after a month it goes back up to 4000. The actual stockpile only decreased by 400. The same goes for the supply, it gets reset a month after i had bought it all, while the stockpile only gets 1/10 of the amount, as per the change to the add rate. This means i can always buy stuff from colonies with excess for a reduced price and sell for a higher price to colonies with deficit. The stockpile will never catch up unless i allow it to.

Is it possible to make the two things somehow tick in tandem without meddling with the code too much?
« Last Edit: August 16, 2019, 01:30:41 AM by Salv »
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 16913
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4804 on: August 16, 2019, 10:25:25 AM »

I have a question abut Ground Support Package. How does it work beneath the hood?

Does the number of ships with it matter? Does it only work on troop transports or would any ship equip with it give a bonus? Does it scale?

Take a look at:

com.fs.starfarer.api.combat.BaseHullMod.GroundSupport

And anywhere that uses Stats.FLEET_GROUND_SUPPORT, if you need more detail.


So i did manage to get the economy to start stabilized but the problem with the discrepancy between the stockpile in a colony and its supply and demand still persists. Now i reduced the rate the stockpile is removed in addAndRemoveStockpiledResources to compensate for the reduced add rate. I set both to be 10x slower to more easily observe the changes.

To illustrate the problem, a colony needs 4000 fuel so i sell them the amount and fulfill that demand. The demand is at zero, and after a month it goes back up to 4000. The actual stockpile only decreased by 400. The same goes for the supply, it gets reset a month after i had bought it all, while the stockpile only gets 1/10 of the amount, as per the change to the add rate. This means i can always buy stuff from colonies with excess for a reduced price and sell for a higher price to colonies with deficit. The stockpile will never catch up unless i allow it to.

Is it possible to make the two things somehow tick in tandem without meddling with the code too much?

With the caveat that syncing everything up will probably be tricky, the thing you might want to do is change

BaseSubmarketPlugin.TRADE_IMPACT_DAYS to something other than 30. That determines how long the player buying/selling things influences the colony's supply/demand for.
Logged

Alec

  • Ensign
  • *
  • Posts: 13
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4805 on: August 17, 2019, 12:26:58 AM »

Is there anyway to modify the class SectorProcGen? In particular the generate() method?
I want more stars and a less random and more evenly distributed map.
Logged

Nawj

  • Ensign
  • *
  • Posts: 3
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4806 on: August 17, 2019, 01:09:12 AM »

Out of these highlighted mods, which do you think would be most likely to cause a memory leak? Saves got progressively slower all day up until the point they started freezing the game. Now even though they don't totally freeze the game, I'm given an error code and the game won't save outright

The reason I say the highlighted mods is the ones not highlighted weren't active when the error took place.
I understand that this is a very broad question but I'm looking for any help I can get as I now have to throw away my first successful run at Starsector which I'd been playing all day since I'd gotten off of work. Having to troubleshoot this via process of elimination would take me two weeks because I'd have to turn off a mod and play for ten hours straight to see if the game freezes.
Logged

Neuromute

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4807 on: August 17, 2019, 01:59:24 AM »

Is this the right place to ask for help with making a mod?
Logged

vagrant

  • Ensign
  • *
  • Posts: 29
    • View Profile
    • Email
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4808 on: August 17, 2019, 06:45:22 AM »

So I'm working on a total conversion that currently is only scoped to include missions. I would like to replace weapon_data.csv so that vanilla weapons don't show up in the refit screen. I was able to replace a handful of other files already without issue, but there seems to be somewhere still trying to load vanilla data and causing a crash during initial startup.

I've replaced:
mission_list.csv, title_screen_variants.csv, sim_opponents.csv, which i thought would be the only places that potentially load ship/variant/weapon data initially (ie before starting campaign generation), but i'm still getting a crash relating to a missing variants.

Am i being naive here? Is the vanilla data more ingrained than i realize or am I missing an obvious place (or option). Any input appreciated.


Edit: my hypothesis currently is that the code responsible for pause screen variants is responsible but i'm not sure where exactly that is... hoping it's not obvious!
« Last Edit: August 17, 2019, 06:50:28 AM by vagrant »
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 16913
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4809 on: August 17, 2019, 09:11:16 AM »

Is there anyway to modify the class SectorProcGen? In particular the generate() method?
I want more stars and a less random and more evenly distributed map.

Yes, you need to provide an alternate version of it and point to it from your mods' settings.json - see vanilla settings.json and its "plugins" section.

Out of these highlighted mods, which do you think would be most likely to cause a memory leak?

Hi - you might have better luck posting this in the modded support board, here, I think it'll be more likely to be seen by someone that might know.


Is this the right place to ask for help with making a mod?

I guess it depends - if it's a quick-ish question (i.e. not "how do I make a mod"), then yeah. Otherwise, a new thread is probably a better place.


So I'm working on a total conversion that currently is only scoped to include missions. I would like to replace weapon_data.csv so that vanilla weapons don't show up in the refit screen. I was able to replace a handful of other files already without issue, but there seems to be somewhere still trying to load vanilla data and causing a crash during initial startup.

I've replaced:
mission_list.csv, title_screen_variants.csv, sim_opponents.csv, which i thought would be the only places that potentially load ship/variant/weapon data initially (ie before starting campaign generation), but i'm still getting a crash relating to a missing variants.

Am i being naive here? Is the vanilla data more ingrained than i realize or am I missing an obvious place (or option). Any input appreciated.


Edit: my hypothesis currently is that the code responsible for pause screen variants is responsible but i'm not sure where exactly that is... hoping it's not obvious!

I'm not actually 100% sure, depends on the error you're getting. You could also add the SYSTEM hint to weapons etc to make them not show up in the refit screen, that seems like it'll be easier than to try to rip them completely out of the game.
Logged

vagrant

  • Ensign
  • *
  • Posts: 29
    • View Profile
    • Email
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4810 on: August 17, 2019, 09:36:29 AM »

I'm not actually 100% sure, depends on the error you're getting. You could also add the SYSTEM hint to weapons etc to make them not show up in the refit screen, that seems like it'll be easier than to try to rip them completely out of the game.

That's a good idea! I'll try it.

On a similar line of thinking, are parts of the main menu easily accessible if I wanted to disable/remove them? As mentioned, i'm only using 'missions' so ideally i'd want to get rid of 'continue', 'new game' 'load game', or at least keep the player from accessing them. If not, i can live with it!

Thanks for all the help so far!
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 16913
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4811 on: August 17, 2019, 09:50:24 AM »

The main menu is not modable like that, no.
Logged

xenoargh

  • Admiral
  • *****
  • Posts: 4861
  • naively breaking things!
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4812 on: August 17, 2019, 08:39:36 PM »

If a Beam weapon has more than 1 barrel, is the CSV's listed damage split between the number of Beams, or does each Beam do the stated damage?  What about Flux cost?
Logged
Please check out my SS projects :)
Xeno's Mod Pack

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 16913
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4813 on: August 17, 2019, 09:21:35 PM »

IIRC both are totals for all the barrels combined.
Logged

NoFoodAfterMidnight

  • Ensign
  • *
  • Posts: 39
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #4814 on: August 17, 2019, 10:41:46 PM »

When working with generating fleets using FleetFactoryV3, how are combat points spent? Like does a battleship cost it's fleet points or is it a set cost for each ship class, like a Capital Ship costs 8 or something?

Also if I wanted to modify every fleet being created by the game, would I do it my adding something at the end of createFleet(), like adding a buff or just adding modifiers to mutableshipstatsapi for each member of the newly generated fleet? (Never mind, this did in fact work)
« Last Edit: August 18, 2019, 04:44:26 AM by NoFoodAfterMidnight »
Logged
Pages: 1 ... 319 320 [321] 322 323 ... 453