Fractal Softworks Forum

Please login or register.

Login with username, password and session length

Author Topic: AI Combat Error  (Read 291 times)

Shyguy

  • Lieutenant
  • **
  • Posts: 52
    • View Profile
AI Combat Error
« on: August 26, 2023, 05:13:57 PM »

Code
9516008 [Thread-3] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NullPointerException
java.lang.NullPointerException
at com.fs.starfarer.combat.ai.attack.AttackAIModule.o00000(Unknown Source)
at com.fs.starfarer.combat.ai.BasicShipAI.advance(Unknown Source)
at com.fs.starfarer.combat.CombatEngine.advanceInner(Unknown Source)
at com.fs.starfarer.combat.CombatEngine.advance(Unknown Source)
at com.fs.starfarer.combat.CombatState.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(Thread.java:750)

No idea where this came from, all I know is that this is the first time i've even seen it in person and it happened at the exact moment a ship was killed and the frigate responsible changed target to another enemy with an eliminate command.

I'm not sure if this is something that can be reproduced on my end, game version is the latest.
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24186
    • View Profile
Re: AI Combat Error
« Reply #1 on: August 26, 2023, 05:16:39 PM »

Thank you for the report! Is this vanilla or with mods?
Logged

Shyguy

  • Lieutenant
  • **
  • Posts: 52
    • View Profile
Re: AI Combat Error
« Reply #2 on: August 26, 2023, 06:04:31 PM »

With mods, the frigates in question was an Arma Armatura frigate destroying an Interstellar Imperium frigate but this had happened several times throughout the battle before the crash occured, it had finished that eliminate order and attempted to move onto the next.
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24186
    • View Profile
Re: AI Combat Error
« Reply #3 on: August 26, 2023, 06:18:40 PM »

Thank you for the details! I've looked over the code and the only place I can see where this might reasonably happen is if a ship's weapon groups were modified on the fly. It's possible that a mod might do that, but it's also possible that this might happen if a ship (not necessarily one of the frigates you were looking at, it could be another ship offscreen) was losing weapons to critical malfunctions. Does that seem like a possibility given what was happening?

I've fixed this potential issue up, regardless.
Logged

Shyguy

  • Lieutenant
  • **
  • Posts: 52
    • View Profile
Re: AI Combat Error
« Reply #4 on: August 26, 2023, 07:03:50 PM »

Two of my ships possess the Performance Irregularities D-Mod, would this be a possible cause with the malfunctions it causes? That's the only thing that springs to mind malfunction wise.
Logged

Alex

  • Administrator
  • Admiral
  • *****
  • Posts: 24186
    • View Profile
Re: AI Combat Error
« Reply #5 on: August 26, 2023, 07:34:15 PM »

Ah, hmm - maybe! Not familiar with what that one does, it's from a mod.

(If that's the cause, still looks like fundamentally a vanilla bug, and this just makes it more likely to show up.)
Logged