Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Pages: [1] 2 3 ... 5

Author Topic: [0.95.1a-RC6] Trophy s-mods [0.7.2]  (Read 14194 times)

michail

  • Lieutenant
  • **
  • Posts: 88
    • View Profile
[0.95.1a-RC6] Trophy s-mods [0.7.2]
« on: June 05, 2021, 01:39:53 AM »

s-modding the pirate way

0.7.x is not save-compatible with 0.6.x and earlier. Not safe to disable.

Features:
  • All AI fleets will be blessed with a number of s-mods. Bigger fleets will get more. Ships with officers receive a bigger share of fleet's s-mod pool depending on the officer's level.
  • s-mods on enemy ships don't disappear when the ship is recovered.
  • Adding s-mods with story points is no longer possible, unless you have a skill that raises the cap

There's a few knobs in the config files to turn. Please refer to README.md or README.txt in mod's directory for all the gory details. You can change relative probabilities of s-modding any given hullmod, prevent s-modding of undesirable hullmods and s-mod numbers (and distribution).

Current version, sources, release history.

Changelog:
Spoiler
0.7.2:
Spoiler
  • The mod now honors "no_build_in" tag, except for Safety Overrides.
  • Added "trophysmods_ignore" tag - modders who wish to make a hullmod non-s-moddable can put it on the hullmod and Trophy S-mods will skip it.
[close]
0.7.1:
Spoiler
  • Compatibility settings for Apex Design Collective, preventing a crash (unless you're already screwed by 0.7.0).
[close]
0.7.0:
Spoiler
  • Proper 0.95.1a support - that is, configured weights of new hullmods.
  • A more stable s-mod selection for each ship
[close]
0.6.0:
Spoiler
  • 0.95.1a support.
  • New algorithm for selecting s-mods (every release has this line, doesn't it?). It allows customizing s-mod pool consumption down to individual hullmods.
  • Much smoother probability curves of receiving N hullmods given a varying share of s-mod pool.
  • Documentation (automatically generated) of all configuration files.
[close]
0.5.0:
Spoiler
  • Hullmod tags and categories (which are exactly the same thing, but are defined externally by the mod) can now influence hullmod weights when selecting hullmods to s-mod. There are two sides to this. The first is global settings in the root of "randomized_picks.json" ("tag_affinities" and "category_affinities"), which apply to all hullmods that have a corresponding tag/category. The second is per-hullmod settings under keys "categories" and "tags" in the "affinities" map, which examine the tags and categories of other hullmods on the ship and modify the weight if those match.
  • The mod can now merge several JSON files into its main config using about the same rules Starsector goes by when merging mod JSONs. Files providing compatibility with other mods now reside in `data/config/trophysmods/compat`. Please note that the list of files to merge is hard-coded, dropping an extra file there will not work.
[close]
0.4.2:
Spoiler
  • Fixed unintentional rarity of s-modding common hullmods.
[close]
0.4.1:
Spoiler
  • Automated Commands compatibility.
  • Fixed detection of fighter slots.
[close]
0.4.0:
Spoiler
  • s-mod pool is calculated based on fleet's DP and d-mods, and distributed based on officer levels.
  • A different algorithm for s-mod selection. It should produce more varied and interesting loadouts. It is also aware of more s-moddable hullmods than the core autofit plugin.
[close]
0.3.1:
Spoiler
  • Corrected version in mod_info
[close]
0.3.0:
Spoiler
  • s-mods on enemy ships no longer disappear upon recovery. In other words the mod should finally somewhat work.
  • Fixed a crash when adding s-mods to Mess fleets from HMI (and similar fleets).
[close]
0.2.0:
Spoiler
  • Sensible s-mod combinations via piggybacking on the autofitter (thanks to Jahgaimo and BreenBB for the suggestion)
  • s-mod distribution across a fleet depends on each ship's DP (suggested by Arcagnello)
  • s-mod generation is a lot more aggressive. High-end fleets should have total s-mods in double digits
  • Config changes on an old save should actually work now
[close]
[close]

Thoughts on mod's current state
Spoiler
I like it. The new s-mod distributing algorithm produces enough s-mods to make most fleets vaguely intersting, while also throwing in real eye-catchers every now and then. I think I'll experiment with raising the s-mod cap.
[close]

Ramblings Rationale:
Spoiler
I'm not entirely happy with s-mods costing story points. Adding them early is all right, since bonus XP helps getting them back in a reasonable time, and losses don't hurt too much. However, in the late game with each SP being worth a million XP bonus XP doesn't do much to alleviate the grind. Even worse, my playstyle late-game mostly focuses on exploration rather than combat, slowing the natural SP gain even more. I can go out of my way and fight, but I don't exactly have an incentive. It also makes me either overly cautious, never picking a fight I know I can't win without major losses, or sucker-punches me after taking a risk and being beaten (while still having a blast in-combat, mind you) by saying "now grind N million XP with a weakened fleet, mate".

This mod is not exactly a solution. It won't change the fact that losing battles sucks, and losing s-mods triples the suck. This mod is an experiment. I want to try and trigger my roguelike player's mentality of "RNG giveth and RNG taketh away" wrt s-mods by making them, essentially, loot. I also hope it'd give me an extra incentive to fight big human fleets and take risks.

(yes, I have just copied the README)
[close]
« Last Edit: June 25, 2022, 08:08:33 AM by michail »
Logged

Jaghaimo

  • Admiral
  • *****
  • Posts: 661
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #1 on: June 05, 2021, 03:51:12 AM »

I very much like this idea. Perhaps instead of random selection, have one of the existing mods become s-mod? Could tie it up to performance and difficulty of the battle.
Logged

BreenBB

  • Commander
  • ***
  • Posts: 150
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #2 on: June 05, 2021, 03:56:14 AM »

I think is good idea, built in existing hullmods and run autofit again on that ship so it spends that OPs on something usefull.
Logged

Arcagnello

  • Admiral
  • *****
  • Posts: 1011
  • Arguably Heretical, Definetly Insane
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #3 on: June 05, 2021, 04:21:32 AM »

I have actually suggested something like this to death around the forum for a while now, I love this idea. As for what I suggested that could maybe apply to this mod:

Restrict AI fleet officer spam to not be absolutely overwhelming (especially concerning [Redacted]) and have AI fleets start applying Smods instead!

Example: randomly generated Pirate fleet has 16 officers totaling up to something like 90 officer skills, which we're going to call "Officer Points" from now on for ease of understanding.
This mod could cut the officer spam down to the maximum the player can obtain with human officers which 60 officer points (20 of potentially being elite skills thanks to both having Officer Training and Officer Management) and convert the remaining "skill points" into Integrated hullmods, at a rate of One Integrated Hullmod for every 4 Officer Points..

I don't know if the core concept is even possible, let alone creating coding that applies Integrated Hullmods on the bigger, badder enemy ships first. But it would be hella cool, would it not?
Logged
Arranging holidays in an embrace with the Starsector is priceless.
The therapist removed my F5 key.

michail

  • Lieutenant
  • **
  • Posts: 88
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #4 on: June 05, 2021, 05:01:42 AM »

I very much like this idea. Perhaps instead of random selection, have one of the existing mods become s-mod? Could tie it up to performance and difficulty of the battle.
I think is good idea, built in existing hullmods and run autofit again on that ship so it spends that OPs on something usefull.

Oh, this sounds really good, thanks for the suggestion! Right now the config file is an absolute mess of white- and blacklists, which doesn't work properly and requires some extensions. Yeah, I should just let the autofit do its job. Integration with other mods should also be much easier this way (assuming they modify the autopicker to be aware of new hullmods). There might be a problem with ships without any hullmods, but I'm not sure how often autofit generates them (gotta admit that I rarely check enemy fleet's hullmods, even if I probably should)

I have actually suggested something like this to death around the forum for a while now, I love this idea. As for what I suggested that could maybe apply to this mod:

Restrict AI fleet officer spam to not be absolutely overwhelming (especially concerning [Redacted]) and have AI fleets start applying Smods instead!

Example: randomly generated Pirate fleet has 16 officers totaling up to something like 90 officer skills, which we're going to call "Officer Points" from now on for ease of understanding.
This mod could cut the officer spam down to the maximum the player can obtain with human officers which 60 officer points (20 of potentially being elite skills thanks to both having Officer Training and Officer Management) and convert the remaining "skill points" into Integrated hullmods, at a rate of One Integrated Hullmod for every 4 Officer Points..

I don't know if the core concept is even possible, let alone creating coding that applies Integrated Hullmods on the bigger, badder enemy ships first. But it would be hella cool, would it not?

I think this is doable. I'd prefer not to make the threshold hard to keep s-mods obtainable before the player can fight maxed out fleets. Something like 0.0x s-mods per officer point below the threshold + 0.y per point above should help with that. And yeah, something should be done about lategame fleets, esp. once s-mods selection is fixed and sensible - it's a straight up buff.
Logged

Arcagnello

  • Admiral
  • *****
  • Posts: 1011
  • Arguably Heretical, Definetly Insane
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #5 on: June 05, 2021, 05:09:15 AM »

I'm really looking forward to see the future of this mod now. Best of luck fighting the Coding demons!
Logged
Arranging holidays in an embrace with the Starsector is priceless.
The therapist removed my F5 key.

ModdedLaharl

  • Ensign
  • *
  • Posts: 38
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #6 on: June 05, 2021, 08:06:17 PM »

A mod that sticks a big spiky shaft up the arse of story points and replaces them with something that actually makes in-game sense and bringing it closer to a mechanic that's fun to engage with? Why I do believe you just earned my love. I'll be including this in my stream loadout and will happily render testing aid if you need
Logged

michail

  • Lieutenant
  • **
  • Posts: 88
    • View Profile
Re: [0.95a-RC15] Trophy s-mods
« Reply #7 on: June 06, 2021, 07:18:42 AM »

TIL that asking the standard autofit plugin to cram 8 s-mods into an Onslaught is not a good idea and crashes the game. Darn, now I want to actually see this insanity in action. Also, I need to tone the numbers down.
Logged

michail

  • Lieutenant
  • **
  • Posts: 88
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #8 on: June 06, 2021, 02:25:11 PM »

Updated the OP with new version. It actually generates good, if boring and similar, loadouts. No conversion of excess officers into s-mods or complicated curves for s-mod numbers though.
Logged

BreenBB

  • Commander
  • ***
  • Posts: 150
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #9 on: June 09, 2021, 12:21:24 PM »

Got a crash in Opuntia system from HMI, seems like it caused by this mod judging from logs.

Spoiler
762587 [Thread-3] INFO  trophysmods.SmodAddingListener  - Inflating fleet Small Swarm
762588 [Thread-3] INFO  trophysmods.SmodAddingListener  - Fleet's s-mod pool: 9.88
762588 [Thread-3] INFO  trophysmods.SmodAddingListener  - Adding 0 smods (expected number: 1.6099999) to ship OBJ 1095 (Enforcer (Mess) class Machine Gun Medium Droneship)
762588 [Thread-3] INFO  sound.oo0O  - Cleaning up music with id [015.ogg]
762600 [Thread-7] INFO  sound.oo0O  - Cleaning up music with id [023.ogg]
762896 [Thread-9] INFO  sound.oo0O  - Creating streaming player for music with id [023.ogg]
762897 [Thread-9] INFO  sound.OooO  - Playing music with id [023.ogg]
763032 [Thread-3] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NullPointerException
java.lang.NullPointerException
   at com.fs.starfarer.api.plugins.impl.CoreAutofitPlugin.doFit(CoreAutofitPlugin.java:323)
   at trophysmods.SmodAddingListener$SmoddingInflater.forceFit(SmodAddingListener.java:151)
   at trophysmods.SmodAddingListener$SmoddingInflater.inflate(SmodAddingListener.java:138)
   at com.fs.starfarer.campaign.fleet.CampaignFleet.inflateIfNeeded(Unknown Source)
   at com.fs.starfarer.campaign.ai.TacticalModule.hasEnoughStuffAround(Unknown Source)
   at com.fs.starfarer.campaign.ai.TacticalModule.advance(Unknown Source)
   at com.fs.starfarer.campaign.ai.ModularFleetAI.advance(Unknown Source)
   at com.fs.starfarer.campaign.fleet.CampaignFleet.advance(Unknown Source)
   at com.fs.starfarer.campaign.BaseLocation.advance(Unknown Source)
   at com.fs.starfarer.campaign.StarSystem.advance(Unknown Source)
   at com.fs.starfarer.campaign.CampaignEngine.advance(Unknown Source)
   at com.fs.starfarer.campaign.CampaignState.advance(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.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
[close]
Logged

michail

  • Lieutenant
  • **
  • Posts: 88
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #10 on: June 09, 2021, 01:51:38 PM »

Got a crash in Opuntia system from HMI, seems like it caused by this mod judging from logs.

Spoiler
762587 [Thread-3] INFO  trophysmods.SmodAddingListener  - Inflating fleet Small Swarm
762588 [Thread-3] INFO  trophysmods.SmodAddingListener  - Fleet's s-mod pool: 9.88
762588 [Thread-3] INFO  trophysmods.SmodAddingListener  - Adding 0 smods (expected number: 1.6099999) to ship OBJ 1095 (Enforcer (Mess) class Machine Gun Medium Droneship)
762588 [Thread-3] INFO  sound.oo0O  - Cleaning up music with id [015.ogg]
762600 [Thread-7] INFO  sound.oo0O  - Cleaning up music with id [023.ogg]
762896 [Thread-9] INFO  sound.oo0O  - Creating streaming player for music with id [023.ogg]
762897 [Thread-9] INFO  sound.OooO  - Playing music with id [023.ogg]
763032 [Thread-3] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NullPointerException
java.lang.NullPointerException
   at com.fs.starfarer.api.plugins.impl.CoreAutofitPlugin.doFit(CoreAutofitPlugin.java:323)
   at trophysmods.SmodAddingListener$SmoddingInflater.forceFit(SmodAddingListener.java:151)
   at trophysmods.SmodAddingListener$SmoddingInflater.inflate(SmodAddingListener.java:138)
   at com.fs.starfarer.campaign.fleet.CampaignFleet.inflateIfNeeded(Unknown Source)
   at com.fs.starfarer.campaign.ai.TacticalModule.hasEnoughStuffAround(Unknown Source)
   at com.fs.starfarer.campaign.ai.TacticalModule.advance(Unknown Source)
   at com.fs.starfarer.campaign.ai.ModularFleetAI.advance(Unknown Source)
   at com.fs.starfarer.campaign.fleet.CampaignFleet.advance(Unknown Source)
   at com.fs.starfarer.campaign.BaseLocation.advance(Unknown Source)
   at com.fs.starfarer.campaign.StarSystem.advance(Unknown Source)
   at com.fs.starfarer.campaign.CampaignEngine.advance(Unknown Source)
   at com.fs.starfarer.campaign.CampaignState.advance(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.o00000(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
[close]

Interesting. I think this can happen if all ships in the fleet have TAG_NO_AUTOFIT on their hulls (even if I don't know what that is, exactly). For such fleet, DefaultFleetInflater will skip a loop in which it sets its "fighters" variable, which the standard autofit plugin attempts to query at line 323. I'll try to figure out a way to check this guess tomorrow. But at any rate, I believe I should stop abusing DefaultFleetInflater's implementation of AutofitPluginDelegate, it seems to be mostly to instruct the autofit in its own "inflate" and not for general-purpose usage.

I haven't tried Hazard Mining yet, could you tell me which faction this fleet most likely belongs to? Could try spawning a few in with console commands.
« Last Edit: June 09, 2021, 01:58:32 PM by michail »
Logged

BreenBB

  • Commander
  • ***
  • Posts: 150
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #11 on: June 09, 2021, 02:35:44 PM »

That was "mess" boss faction, they spawn in HMI added Opuntia system.
Logged

ModdedLaharl

  • Ensign
  • *
  • Posts: 38
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #12 on: June 09, 2021, 11:20:45 PM »

Definitely needs a big fat healthy injection of randomness shoved into it. Possibly also see if you can get it working with mod-added hullmods?
Logged

Deshara

  • Admiral
  • *****
  • Posts: 1578
  • Suggestion Writer
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #13 on: June 10, 2021, 12:39:05 AM »

the OP is not actually clear enough about what the mod does. It says s-mods are acquirable thru combat, but instead of describing what that means, u go on to talk about how the AI get s-mods which gives me the impression this mod might not do anything for the player at all but cause AI to bring s-mods to the field, but the responses of the commenters makes me think thats not the case & it does thing for the player too. Format of the OP should go, 1 sentence summary of what to generally expect from the mod, then a sentence describing what it does for players, then a sentence describing what it does for the enemy AI, then go into details (the details being bulleted preferably if only bc it helps u organize the thoughts in a way that is easily skimmable by a reader)
Logged
Quote from: Deshara
I cant be blamed for what I said 5 minutes ago. I was a different person back then

Amoebka

  • Admiral
  • *****
  • Posts: 1330
    • View Profile
Re: [0.95a-RC15] Trophy s-mods [0.2.0]
« Reply #14 on: June 10, 2021, 10:55:19 AM »

I'm guessing it adds S-mods to the enemy ships and allows to recover them without losing S-mods? But yeah, the OP does a rather poor job of describing the mod.
Logged
Pages: [1] 2 3 ... 5