Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.96a is out! (05/05/23); Blog post: Colony Crises (11/24/23)

Pages: 1 ... 5 6 [7]

Author Topic: [0.96a] Officer Extension (0.5)  (Read 91669 times)

float

  • Commander
  • ***
  • Posts: 213
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #90 on: September 11, 2023, 10:23:09 AM »

Can you disable Officer Extension and post a picture of the officer selection screen or fleet screen?

(Again, this mod is not compatible with the Chinese language pack, if you're using that.)
Logged

Ash and dust

  • Ensign
  • *
  • Posts: 13
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #91 on: September 12, 2023, 04:55:09 AM »

Can you disable Officer Extension and post a picture of the officer selection screen or fleet screen?

(Again, this mod is not compatible with the Chinese language pack, if you're using that.)
Ok, I will disable this Mod until the Chinese forum translator can update it to support 0.96;
 Here's how I repeat the error situation.
I just finished creating a new game and then I click on the bottom left corner from left to right for the second (Fleet Management)
https://backup1.fossic.oss.jnxyp.cn/forum/202309/12/193832rhhah852cmgbhoh8.jpg
The game immediately freezes and crashes, and this error message pops up.
https://backup1.fossic.oss.jnxyp.cn/forum/202309/12/193823mgd401gbdewc7cyc.png

[Game log]

88780 [Thread-7] INFO  sound.oo0OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOO  - Cleaning up music with id [campaign_noncore_part1.ogg]
88905 [Thread-10] INFO  sound.oo0OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOO  - Creating streaming player for music with id [campaign_noncore_part1.ogg]
88905 [Thread-10] INFO  sound.H  - Playing music with id [campaign_noncore_part1.ogg]
90644 [Thread-3] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.RuntimeException: Renderer's graphics object not found
java.lang.RuntimeException: Renderer's graphics object not found
   at officerextension.ui.Button.getText(Button.java:82)
   at officerextension.FleetPanelInjector.getAutoAssignButton(FleetPanelInjector.java:212)
   at officerextension.FleetPanelInjector.advance(FleetPanelInjector.java:44)
   at officerextension.CoreScript.advance(CoreScript.java:101)
   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)



« Last Edit: September 12, 2023, 04:59:22 AM by Ash and dust »
Logged

AtlanticAccent

  • Lieutenant
  • **
  • Posts: 66
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #92 on: September 15, 2023, 07:58:38 AM »

Hi,

Your reflection work was one of the original inspirations for me to get into messing with officers and UI.

One thing I'd like to request in the name of cross-mod compatibility is the ability to prevent certain skills from being "demotable". In my case, I'm (mis)using the skill system to represent non-skill/skill-adjacent concepts[1]. In vanilla, there is already a way to indicate that a skill is unremovable by adding
Code
"unremovable" : true
to the .skill file. This can be retrieved in code through SkillSpecAPI.isPermanent(). I should note that no vanilla skill makes use of this but it is still handled correctly by the game.

Additionally, you can add arbitrary tags to skills in their entry in the skill_data.csv file. If it's not too much trouble, I'd like to propose adding a tag that Officer Extension recognises as opting a skill out from being demotable, for cases where the skill author does not want to use the permanent field in the skill file.

These changes would effectively require adding some filtering on the list returned by getSkillButtons in injectSkillButtons.

Happy to discuss this in a proper issue on GitHub or a PR if you'd like.

[1]
Spoiler
In my mod I call them Conditions, the most prominent being Injuries that temporarily remove a skill from an officer when they are, naturally, injured. Source: https://github.com/atlanticaccent/price-of-command/
[close]
Logged

float

  • Commander
  • ***
  • Posts: 213
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #93 on: September 16, 2023, 10:09:46 AM »

Thanks for the info.

I'll see if I can make Officer Extension ignore permanent skills. Is there a reason why you want Officer Extension to have a not-demotable tag separate from "isPermanent"? Seems to me like they'd be functionally equivalent. Can you elaborate on how exactly the base game handles unremovable skills, considering that there isn't a way to remove skills in vanilla in the first place?

Edit: I've tried adding
Code
"unremovable": true
to a couple of .skill files, and it doesn't seem to work at all. I can still remove "unremovable" skills, both on players and on officers. Either I'm not adding this snippet in the right place, or the feature has been fully deprecated. I can still make a custom tag for officer-permanent conditions, though. In fact, it's only a couple of lines of code.

Edit 2: Ok, added handling of an "officerextension_unremovable" tag to dev, if you'd like to test compatibility before release feel free to download the jar from the github repo.
« Last Edit: September 16, 2023, 10:53:16 AM by float »
Logged

Wyvern

  • Admiral
  • *****
  • Posts: 3564
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #94 on: November 27, 2023, 05:51:25 PM »

Hey, just got an exception seemingly from this mod:
Code
292725 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.NullPointerException
java.lang.NullPointerException
at officerextension.FleetListener.reportShownInteractionDialog(FleetListener.java:37)
at com.fs.starfarer.campaign.CampaignEngine.reportShowInteractionDialog(Unknown Source)
at com.fs.starfarer.campaign.CampaignState.showInteractionDialog(Unknown Source)
at tecrys.svc.world.notifications.NotificationBase.showNotification(NotificationBase.kt:20)
at tecrys.svc.world.notifications.NotificationBase.showIfRequested(NotificationBase.kt:28)
at tecrys.svc.world.notifications.NotificationShower.advance(NotificationShower.kt:61)
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.super(Unknown Source)
at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
at java.lang.Thread.run(Thread.java:745)
Was not triggered by anything obvious; I was just flying through hyperspace back towards the core when, boom, game dead.

Reloading and taking a similar course a second time did not replicate the crash.
Logged
Wyvern is 100% correct about the math.

float

  • Commander
  • ***
  • Posts: 213
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #95 on: November 27, 2023, 07:30:53 PM »

Thanks for the report, looking at it I see the only way this could happen is if a fleet's getBattle is not null but getBattle().getOtherSideCombined is null. Seems like an odd crash... could it be that the fleet you were fighting against didn't exist or didn't have any ships?

I'll add some additional null checks, though I suspect this is some funky mod fleet. What exactly is tecrys?

Edit: if you're still getting the crash try downloading the latest jar from the github repo and let me know if that fixes it, here: https://github.com/qcwxezda/Starsector-Officer-Extension/tree/main/jars
« Last Edit: November 27, 2023, 07:34:31 PM by float »
Logged

Wyvern

  • Admiral
  • *****
  • Posts: 3564
    • View Profile
Re: [0.96a] Officer Extension (0.5)
« Reply #96 on: November 27, 2023, 07:52:03 PM »

Ahh, so weird mod interaction, that'd do it. Tecrys would presumably be the Symbiotic Void Creatures mod; I've reported this issue in that mod's thread as well, here. Thanks for the information on what's likely causing it; that should help Tecrys fix up their mod, too.

(Edit: To clarify: I wasn't even fighting anything when this crash went down, just cruising along through hyperspace with nothing in sight.)

Will go ahead and download the jar, though given the apparent rarity of this bug- well, if it happens again, I'll let you know; all I can do there. Thanks for the fast fix!
« Last Edit: November 27, 2023, 07:54:33 PM by Wyvern »
Logged
Wyvern is 100% correct about the math.
Pages: 1 ... 5 6 [7]