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)

Author Topic: No understand AI core loot from battles  (Read 2036 times)

Histidine

  • Admiral
  • *****
  • Posts: 4661
    • View Profile
    • GitHub profile
No understand AI core loot from battles
« on: April 05, 2022, 03:51:44 AM »

How are AI core drops from combat with Remnants (and derelicts) calculated, exactly?

This question seems to crop up quite frequently on the Discord, e.g. someone just reported killing "20" capitals with "95%" alpha core officers, and getting zero alpha core items out of the deal. Then I've heard from another mod dev that there's a hidden (in obsfucated code?) bit where core drops from farming Remnants has diminishing returns.

Are the drop_prob_officer_alpha_core etc. values specified in settings.json and referenced in FleetEncounterContext actually used to calculate drops? Are there further modifiers on top of this?
EDIT: Also, could mods be having funny effects on the drops?
« Last Edit: April 05, 2022, 04:04:47 AM by Histidine »
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 23989
    • View Profile
Re: No understand AI core loot from battles
« Reply #1 on: April 05, 2022, 07:24:34 AM »

This question seems to crop up quite frequently on the Discord, e.g. someone just reported killing "20" capitals with "95%" alpha core officers, and getting zero alpha core items out of the deal. Then I've heard from another mod dev that there's a hidden (in obsfucated code?) bit where core drops from farming Remnants has diminishing returns.

20 capitals with alpha cores, let's see... base 5% chance for an Alpha Core, times 4 for a capital ship, 20% chance each. 0.8^20 is around 0.01, so, 1% chance of zero core drops - certainly not impossible, but not very likely either.

As much as I love the paranoia (and I love it a lot), there aren't any hidden drop-reductions in core code.

Are the drop_prob_officer_alpha_core etc. values specified in settings.json and referenced in FleetEncounterContext actually used to calculate drops? Are there further modifiers on top of this?

It looks like you've found it; it's handled in FEC.lootWeapons(). As far as I'm aware/can remember, that's the only place, though there *might* be some code elsewhere.

EDIT: Also, could mods be having funny effects on the drops?

Certainly! From changing FEC, to changing these settings values, to filtering the loot via whatever listener lets you do that, to probably some other things I'm not thinking about.
Logged