Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.97a is out! (02/02/24); New blog post: Simulator Enhancements (03/13/24)

Pages: 1 ... 243 244 [245] 246 247 ... 706

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

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3660 on: November 08, 2017, 02:05:54 PM »

If GraphicsLib is used along with every mod under the sun, VRAM requirements might reach as high as 2.5 GB.  I doubt that would happen with GraphicsLib disabled.  Even dedicated cards will fall back to system memory if you run out.  Not that this would be problematic if you have 12 GB of RAM, which leaves quite a healthy buffer even if you allocate 4 GB to Starsector.

In my experience, unless you simply don't allocate enough memory to Starsector (say, less than 3 GB if you have a ton of mods that add lots of markets), the only source of save failure is the bug where XStream fails midway through the saving, which isn't memory-related.  Other people have reported a separate issue where the game will just progressively slow down until it's too laggy to use (and the save freezes entirely) - I have seen this before on occasion - and it seems to be caused by DynaSector for unknown reasons.  Nobody who reported this issue has ever submitted a save file, no matter how many times I asked.
Logged

Iridescens

  • Lieutenant
  • **
  • Posts: 56
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3661 on: November 08, 2017, 03:34:57 PM »

Ok, the setup is "-Xms8192m -Xmx8192m" (overzealous I might be), 2.5GB taken by Win10+apps/services, 1.5GB free no matter what, 2GB swap on SSD (just a cherry on top for old apps compat), 2GB Nvidia GTX670 at 1920*1200.

Mods:
Spoiler
Active-Gates
ApproLight
Audio Plus
Autosave
Blackrock Drive Yards
Combat Chatter
Common Radar
Console Commands
Dassault-Mikoyan Engineering
DIABLEAVIONICS
DisassembleReassemble_v0.8
DynaSector
Extra System Reloaded
Galatia Complete
GraphicsLib
Interstellar Imperium
LazyLib
Leading Pip
Lightshow_with_SWP
Metelson
Neutrino corp
New Galactic Order 1.06b
Nexerelin
Omnifactory
ORA
Portrait pack
Save Transfer
SCY
Shadowyards
Ship and Weapon Pack
Simulator Overhaul
Steiner Foundation
TARGETS
Templars
Tyrador Safeguard Coalition
Underworld
UnknownSkies
UpgradedRotaryWeapons
Version Checker
[close]

When GraphicsLib is "just for compatibility" SS runs fine for hours and I haven't ever ran into a crash. But when GraphicsLib is ON, SS drops at a) the end of galaxy creation right when it tries to save the game, b) it creates galaxy fine, but next save (even right after the exact start) will crash it.
After a second thought, may be I should LOWER the 8192 to 6144 (or even 4096) in java mem-alloc options?
« Last Edit: November 08, 2017, 03:37:30 PM by Iridescens »
Logged

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3662 on: November 08, 2017, 07:26:05 PM »

Yes, you should reduce your allocation.

Also, with GfxLib on, you’re definitely using more than 2 GBs of VRAM with that mod list.
Logged

Novaris

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3663 on: November 10, 2017, 04:19:25 AM »

If GraphicsLib is used along with every mod under the sun, VRAM requirements might reach as high as 2.5 GB.  I doubt that would happen with GraphicsLib disabled.  Even dedicated cards will fall back to system memory if you run out.  Not that this would be problematic if you have 12 GB of RAM, which leaves quite a healthy buffer even if you allocate 4 GB to Starsector.

In my experience, unless you simply don't allocate enough memory to Starsector (say, less than 3 GB if you have a ton of mods that add lots of markets), the only source of save failure is the bug where XStream fails midway through the saving, which isn't memory-related.  Other people have reported a separate issue where the game will just progressively slow down until it's too laggy to use (and the save freezes entirely) - I have seen this before on occasion - and it seems to be caused by DynaSector for unknown reasons.  Nobody who reported this issue has ever submitted a save file, no matter how many times I asked.

Seems I'm one of these affected cases. I increased the memory limit to 5GB (simply because I use nearly every faction mod there is which is probably also the source of my issue together with DynaSector and Nexerelin) but when I play for about an hour you see the CPU idle percentagy decreasing more and more until it starts to impact the FPS, which will then gradually fall from 60 to 25. Once I save and close the game and reload the same savefile it is ok again, but only for a few minutes, then it follows essentially the same path. For now I tracked the issue down to essentially two things: the garbage collector kicking in because of all the debris in the systems and the fights going on throughout sector which the game has to calculate in the back and get rid of the objects it doesn't need anymore (once I see this phenomenon I also find a star system which is just full of space debris) and, judging from the log file, market information and fleet creation.

I tried a few things to ease the situation by switching on other garbage collection schemes but none of them really led to a better solution. The only thing that works every time is doing a save transfer into a newly created system, then the clock starts ticking again. One thing I also noticed is that this behavior starts once the first templar crusade notification pops up. My best guess is that this event leads to an increase in space battle and debris count which just accelerates the problem. I have yet to try out what happens if I deactivate the crusades though so please don't take it as blame assignment. What is also a little weird is that saving into the same save slot seems to be a lot slower than creating a new save file and does not tend to crash that often.

As for the question about the savegame: I will provide one once I'm at the machine again togeher with a mod list if you still want to investigate the matter.
« Last Edit: November 10, 2017, 05:28:15 AM by Novaris »
Logged

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3664 on: November 10, 2017, 10:03:04 AM »

Frankly, I don't want to investigate the matter, especially if the problem space is "literally everything", given that your mod list is as large as possible.

The first Crusade generally happens at the same time every game, so I doubt it's Templar-related.  Try disabling DynaSector instead and see if that affects the timing significantly.
Logged

Novaris

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3665 on: November 10, 2017, 10:08:01 AM »

Thats what I thought, but I will try your suggestion. Thanks!
Logged

King Alfonzo

  • Admiral
  • *****
  • Posts: 679
  • -- D O C T O R --
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3666 on: November 11, 2017, 12:06:09 AM »

Currently trying to get a new system generated, not entirely sure what has gone wrong:

Code
74002 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NullPointerException
java.lang.NullPointerException
at com.fs.starfarer.combat.entities.terrain.Planet.<init>(Unknown Source)
at com.fs.starfarer.combat.entities.terrain.Planet.<init>(Unknown Source)
at com.fs.starfarer.campaign.CampaignPlanet.<init>(Unknown Source)
at com.fs.starfarer.campaign.CampaignPlanet.<init>(Unknown Source)
at com.fs.starfarer.campaign.BaseLocation.addPlanet(Unknown Source)
at data.scripts.world.systems.HMI_mercy.generate(HMI_mercy.java:87)
at data.scripts.world.HMI_gen.generate(HMI_gen.java:16)
at data.scripts.HMI_modPlugin.initHMI(HMI_modPlugin.java:16)
at data.scripts.HMI_modPlugin.onNewGame(HMI_modPlugin.java:24)
at com.fs.starfarer.campaign.save.CampaignGameManager.o00000(Unknown Source)
at com.fs.starfarer.title.TitleScreenState.dialogDismissed(Unknown Source)
at com.fs.starfarer.ui.Oo0O.dismiss(Unknown Source)
at com.fs.starfarer.ui.impl.J.dismiss(Unknown Source)
at com.fs.starfarer.campaign.save.if.actionPerformed(Unknown Source)
at com.fs.starfarer.ui.j.super(Unknown Source)
at com.fs.starfarer.ui.I.processInput(Unknown Source)
at com.fs.starfarer.ui.V.o00000(Unknown Source)
at com.fs.starfarer.BaseGameState.traverse(Unknown Source)
at com.fs.state.AppDriver.begin(Unknown Source)
at com.fs.starfarer.combat.CombatMain.main(Unknown Source)
at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

Happens at initialization of new game. Reading it I thought something wasn't right with the planets.json, but I can't see anything wrong there. Any ideas?

Snrasha

  • Admiral
  • *****
  • Posts: 705
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3667 on: November 11, 2017, 12:15:13 AM »

Currently trying to get a new system generated, not entirely sure what has gone wrong:

Code
74002 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NullPointerException
java.lang.NullPointerException
at com.fs.starfarer.combat.entities.terrain.Planet.<init>(Unknown Source)
at com.fs.starfarer.combat.entities.terrain.Planet.<init>(Unknown Source)
at com.fs.starfarer.campaign.CampaignPlanet.<init>(Unknown Source)
at com.fs.starfarer.campaign.CampaignPlanet.<init>(Unknown Source)
at com.fs.starfarer.campaign.BaseLocation.addPlanet(Unknown Source)
at data.scripts.world.systems.HMI_mercy.generate(HMI_mercy.java:87)
at data.scripts.world.HMI_gen.generate(HMI_gen.java:16)
at data.scripts.HMI_modPlugin.initHMI(HMI_modPlugin.java:16)
at data.scripts.HMI_modPlugin.onNewGame(HMI_modPlugin.java:24)
at com.fs.starfarer.campaign.save.CampaignGameManager.o00000(Unknown Source)
at com.fs.starfarer.title.TitleScreenState.dialogDismissed(Unknown Source)
at com.fs.starfarer.ui.Oo0O.dismiss(Unknown Source)
at com.fs.starfarer.ui.impl.J.dismiss(Unknown Source)
at com.fs.starfarer.campaign.save.if.actionPerformed(Unknown Source)
at com.fs.starfarer.ui.j.super(Unknown Source)
at com.fs.starfarer.ui.I.processInput(Unknown Source)
at com.fs.starfarer.ui.V.o00000(Unknown Source)
at com.fs.starfarer.BaseGameState.traverse(Unknown Source)
at com.fs.state.AppDriver.begin(Unknown Source)
at com.fs.starfarer.combat.CombatMain.main(Unknown Source)
at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

Happens at initialization of new game. Reading it I thought something wasn't right with the planets.json, but I can't see anything wrong there. Any ideas?

Paste the HMI_mercy line 87 will be more helpful.
This is just a nullpointerexception, so you have forgot to check if a thing can be null or not, no?
Logged
I am pretty bad on english. So, sorry in advance.

Gladiator Society
Add battle options on Com Relay/ Framework for modders for add their own bounty.

Sanguinary Autonomist Defectors A fan-mod of Shadowyard.

King Alfonzo

  • Admiral
  • *****
  • Posts: 679
  • -- D O C T O R --
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3668 on: November 11, 2017, 01:13:12 AM »

Hmmm...I think I put the wrong thing in for a planet type. Let me check...

EDITL Yeah, that was it. Huh, didn't know those numbers actually corresponded to lines of code. Thanks Snrasha!

dk1332

  • Commander
  • ***
  • Posts: 197
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3669 on: November 11, 2017, 08:15:16 AM »

I got some few questions and I think I should address it here rather than making a thread for it.

-Is it possible to make a subsystem that creates a "portal" and temporarily extends a fighter's range?
-If so, is it also possible to restrict it to certain fighters by adding a hullmod?
-How do you make a weapon have another type of damage? (ex. Kinetic gun has a small percentage to deal a small amount of HE damage)
-About the recovery shuttle hullmod, is it possible to make a hullmod for a fighter that has the same effect (lowers the chance of a pilot dying)
-Is it possible to add a commodity as an expendable requirement on a ship/fighter/weapon?


Logged

King Alfonzo

  • Admiral
  • *****
  • Posts: 679
  • -- D O C T O R --
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3670 on: November 11, 2017, 05:19:52 PM »

I got some few questions and I think I should address it here rather than making a thread for it.

...

-How do you make a weapon have another type of damage? (ex. Kinetic gun has a small percentage to deal a small amount of HE damage)

My Codefu is lacking, but I do know the answer to this one: I suggest you pick up Blackrock, and have a peak at how the Shard weapons work, specifically the weapon script in the jar/src/data/scripts/weapons. Do note that this one is in a JAR, so it'll require the use of an IDE to get it to work.

Verrius

  • Captain
  • ****
  • Posts: 369
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3671 on: November 11, 2017, 06:44:58 PM »

Hey everyone, I wanted to ask if there's an easy way to prevent all spawning when you start the game? The easiest way to mod the game to be a completely empty universe in a single system, with no jump points to hyperspace, etc.

I tried to search but I'm either bad at searching, or it's not outlined in a single place.

Thanks!

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 23986
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3672 on: November 11, 2017, 07:09:52 PM »

Hey everyone, I wanted to ask if there's an easy way to prevent all spawning when you start the game? The easiest way to mod the game to be a completely empty universe in a single system, with no jump points to hyperspace, etc.

I tried to search but I'm either bad at searching, or it's not outlined in a single place.

Thanks!

I *think* if you override these in settings.json, that should cover it:

"newGameCreationEntryPoint":"data.scripts.world.SectorGen",
"newGameSectorProcGen":"com.fs.starfarer.api.impl.campaign.procgen.SectorProcGen",

You'd also have to mod new game creation (in rules.csv) to start in hyperspace instead of in a system that no longer exists.

Logged

Morrokain

  • Admiral
  • *****
  • Posts: 2143
  • Megalith Dreadnought - Archean Order
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3673 on: November 13, 2017, 01:38:28 PM »

For this method: Global.getSector().getMemory().getFleet(key)

I'm wondering what the "key" references? Is it a memory key you can set with:

CampaignFleetAPI.getMemoryWithoutUpdate().set(key, object)

What I'm doing:
I'm trying to reference a CampaignFleetAPI (without a for loop to search the entire sector if possible) in order to invoke CampaignFleetAPI.getFlagship() and use the resulting FleetMemberAPI in visual.showFleetMemberInfo(FleetMemberAPI)


Ah, shoot nvm. Must be the same issue I had a while ago. The key is in the entity memory, and the script is checking global. Disregard  ::)
« Last Edit: November 13, 2017, 01:46:55 PM by Morrokain »
Logged

Morrokain

  • Admiral
  • *****
  • Posts: 2143
  • Megalith Dreadnought - Archean Order
    • View Profile
Re: Misc modding questions that are too minor to warrant their own thread
« Reply #3674 on: November 16, 2017, 01:21:15 PM »

Ok lots of questions about this one.  :P

When setting up a custom BattleAPI for a battle with a specifically defined context, such as ESCAPE scenario with allies supporting your retreat, do you have to also define everything in the MissionDefinitionAPI and pass that as a parameter into BattleCreationPlugin alongside another defined BattleCreationContext?

How much does the engine do for me, and if the answer is nothing then how easy is it to define those classes? Orrr, the unlikely easy way? :

As long as they are nearby in the LocationAPI, can I just get the CampaignFleetAPI's for all involved and plug them in to the BattleAPI.join(CampaignFleetAPI) boolean then make a few tweaks to who's supporting who?

If it's anything like how the tutorial scripting works, it'll be a pretty big hierarchy I'm guessing.  ;D
Logged
Pages: 1 ... 243 244 [245] 246 247 ... 706