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 [2] 3 4 ... 7

Author Topic: [0.97a] MagicLib v1.4.3  (Read 201041 times)

Poxil

  • Ensign
  • *
  • Posts: 10
    • View Profile
Re: [0.95.1a] MagicLib v0.46.1 (2023/04/12)
« Reply #15 on: May 01, 2023, 08:39:34 AM »

Is it safe to ongoing game if I update to latest version?
Logged

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.95.1a] MagicLib v0.46.1 (2023/04/12)
« Reply #16 on: May 01, 2023, 03:40:19 PM »

Hi, I'm new to the modding scene, currently working on a mod that modifies the bounty rewards. It works for vanilla but before I release I was hoping to make it react dynamically to bounties added by other mods such as MagicLib. Is there a way to modify the bounty credit rewards in a blanket way, i.e. for all bounties added by MagicLib?

You could use MagicBountyCoordinator to get all ActiveBounty's, loop over them, and increase the payout. Those are the bounties that have been "inflated" from the spec, which happens when the player first views them at a bar. Would need to do it in an EveryFrameScript that runs when the game is paused.
There's no "official" way.

I've noticed that unlike in job_description, the job_comm_reply and job_intel_success fields will not render \n new lines correctly.

Thanks! Fixed for next update.

Is it safe to ongoing game if I update to latest version?

Yes.
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.0.0 (2023/05/05)
« Reply #17 on: May 06, 2023, 12:39:11 AM »

MagicLib v1.0.0
0.96a compatible.

NOT COMPATIBLE WITH PRE-0.96 MODS

Changelog: https://github.com/MagicLibStarsector/MagicLib/releases/tag/1.0.0

(I'm too lazy to convert this all to forum styling, have an image instead)
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.0.0 (2023/05/05)
« Reply #18 on: May 07, 2023, 10:23:28 AM »

Mod authors updating may find this useful:

Code
// Long createFleet method
MagicCampaign.createFleetBuilder()
        .setFleetName()
        .setFleetFaction()
        .setFleetType()
        .setFlagshipName()
        .setFlagshipVariant()
        .setFlagshipAlwaysRecoverable()
        .setFlagshipAutofit()
        .setCaptain()
        .setSupportFleet()
        .setSupportAutofit()
        .setMinFP()
        .setReinforcementFaction()
        .setQualityOverride()
        .setSpawnLocation()
        .setAssignment()
        .setAssignmentTarget()
        .setIsImportant()
        .setTransponderOn()
        .setVariantsPath()
        .create();

// Shorter createFleet method
MagicCampaign.createFleetBuilder()
        .setFleetName()
        .setFleetFaction()
        .setFleetType()
        .setFlagshipName()
        .setFlagshipVariant()
        .setCaptain()
        .setSupportFleet()
        .setMinFP()
        .setReinforcementFaction()
        .setQualityOverride()
        .setSpawnLocation()
        .setAssignment()
        .setAssignmentTarget()
        .setIsImportant()
        .setTransponderOn()
        .create();

// createCaptain
MagicCampaign.createCaptainBuilder()
        .setIsAI()
        .setAICoreType()
        .setFirstName()
        .setLastName()
        .setPortraitId()
        .setGender()
        .setFactionId()
        .setRankId()
        .setPostId()
        .setPersonality()
        .setLevel()
        .setEliteSkillsOverride()
        .setSkillPreference()
        .setSkillLevels()
        .create();

Note that you don't need to use all of these; each method tells you what the default is, and you can leave out any setter where the default is good (eg don't need to explicitly set isAICore to false for humans).



Paths to replace
Code
import data.scripts.Magic -> import org.magiclib.Magic
import data.scripts.util.Magic -> import org.magiclib.util.Magic
import data.scripts.terrain.Magic-> import org.magiclib.terrain.Magic
import data.scripts.ai.Magic-> import org.magiclib.ai.Magic
import data.scripts.bounty.Magic-> import org.magiclib.bounty.Magic
import data.scripts.campaign.Magic-> import org.magiclib.campaign.Magic
import data.scripts.hullmods.Magic-> import org.magiclib.hullmods.Magic
import data.scripts.plugins.Magic-> import org.magiclib.plugins.Magic
import data.scripts.weapons.Magic-> import org.magiclib.weapons.Magic
« Last Edit: May 08, 2023, 07:38:13 AM by Wispborne »
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.0.0 (2023/05/07)
« Reply #19 on: May 07, 2023, 11:32:29 AM »

Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Zuthal

  • Ensign
  • *
  • Posts: 47
    • View Profile
Re: [0.96a] MagicLib v1.0.0 (2023/05/07)
« Reply #20 on: May 07, 2023, 11:35:09 AM »

Something broke, that link downloads an empty zip
Logged

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.0.0 (2023/05/07)
« Reply #21 on: May 07, 2023, 11:46:58 AM »

Something broke, that link downloads an empty zip

Sorry! It should be fixed now.
I relied on my automatic process to create the .zip, it broke, and I didn't double-check it :|
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Zuthal

  • Ensign
  • *
  • Posts: 47
    • View Profile
Re: [0.96a] MagicLib v1.0.0 (2023/05/07)
« Reply #22 on: May 08, 2023, 02:23:18 AM »

Something broke, that link downloads an empty zip

Sorry! It should be fixed now.
I relied on my automatic process to create the .zip, it broke, and I didn't double-check it :|

Yep, it works now! Though this time, seems you left a bunch of the project files, kotlin folders and such in it
Logged

Dhunt05

  • Lieutenant
  • **
  • Posts: 54
    • View Profile
    • Twitch
Re: [0.96a] MagicLib v1.0.1 (2023/05/07)
« Reply #23 on: May 08, 2023, 02:18:43 PM »

Breaking support for every mod out there hurts my soul :( theres so many older mods i love to use.
Logged

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.0.1 (2023/05/07)
« Reply #24 on: May 09, 2023, 12:47:21 PM »

MagicLib 1.1.0 dev02
This is an experimental update that allows un-updated mods to work with updated MagicLib.
It has been released on the Discord for most of a day and seems fine, but if there is any weirdness or MagicLib crashes, please report it.

https://github.com/MagicLibStarsector/MagicLib/releases/download/1.1.0-dev02/MagicLib-1.1.0-dev02.zip

Changes
- Most older mods are no longer broken by MagicLib and may work with just a mod_info.json file edit (unless broken by something other than MagicLib).
- Mods with code that referenced MagicBounty and haven't been updated will not work.
  - Mods that just add bounties are fine; it's mods with code that used MagicBountyCoordinator, bountyData, etc that need to be updated.
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.1.0 (2023/05/09)
« Reply #25 on: May 09, 2023, 05:56:08 PM »

MagicLib 1.1.0
(no changes from dev02)

Download: https://github.com/MagicLibStarsector/MagicLib/releases/download/1.1.0/MagicLib-1.1.0.zip

Changes
- Most older mods are no longer broken by MagicLib and may work with just a mod_info.json file edit (unless broken by something other than MagicLib).
- Mods with code that referenced MagicBounty and haven't been updated will not work.
  - Mods that just add bounties are fine; it's mods with code that used MagicBountyCoordinator, bountyData, etc that need to be updated.
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

Zelrod92

  • Ensign
  • *
  • Posts: 21
    • View Profile
Re: [0.96a] MagicLib v1.1.1 (2023/05/16)
« Reply #26 on: May 26, 2023, 07:22:20 AM »

hello I keep getting this error when playing and I think it might come from MagicLib.

1172137 [Thread-9] INFO  sound.H  - Playing music with id [battle_ambience_01.ogg]
1172181 [Thread-3] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.RuntimeException: Texture [trails_trail_zappy] from category [fx] not found
java.lang.RuntimeException: Texture [trails_trail_zappy] from category [fx] not found
   at com.fs.starfarer.settings.StarfarerSettings.o00000(Unknown Source)
   at com.fs.starfarer.settings.StarfarerSettings.class(Unknown Source)
   at com.fs.starfarer.settings.StarfarerSettings$1.getSprite(Unknown Source)
   at org.magiclib.plugins.MagicAutoTrails.createTrailSegment(MagicAutoTrails.java:147)
   at org.magiclib.plugins.MagicAutoTrails.advance(MagicAutoTrails.java:136)
   at com.fs.starfarer.title.Object.for$Oo.o00000(Unknown Source)
   at com.fs.starfarer.combat.super.new.super(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)
Logged

SpaceDrake

  • Captain
  • ****
  • Posts: 484
  • Piloting space mecha for fun and profit(?)
    • View Profile
Re: [0.96a] MagicLib v1.1.1 (2023/05/16)
« Reply #27 on: June 01, 2023, 01:22:44 AM »

hello I keep getting this error when playing and I think it might come from MagicLib.

1172137 [Thread-9] INFO  sound.H  - Playing music with id [battle_ambience_01.ogg]
1172181 [Thread-3] ERROR com.fs.starfarer.combat.CombatMain  - java.lang.RuntimeException: Texture [trails_trail_zappy] from category [fx] not found
java.lang.RuntimeException: Texture [trails_trail_zappy] from category [fx] not found
   at com.fs.starfarer.settings.StarfarerSettings.o00000(Unknown Source)
   at com.fs.starfarer.settings.StarfarerSettings.class(Unknown Source)
   at com.fs.starfarer.settings.StarfarerSettings$1.getSprite(Unknown Source)
   at org.magiclib.plugins.MagicAutoTrails.createTrailSegment(MagicAutoTrails.java:147)
   at org.magiclib.plugins.MagicAutoTrails.advance(MagicAutoTrails.java:136)
   at com.fs.starfarer.title.Object.for$Oo.o00000(Unknown Source)
   at com.fs.starfarer.combat.super.new.super(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)

That's actually a mod not implementing MagicTrails properly; try updating to 1.1.1, and if it still persists, contact the mod author to whom "trail_zappy" is meant to belong to.
Logged

Wispborne

  • Captain
  • ****
  • Posts: 400
  • Discord: wispborne
    • View Profile
Re: [0.96a] MagicLib v1.1.2 (2023/06/01)
« Reply #28 on: June 07, 2023, 11:13:39 AM »

MagicLib 1.1.2

Effects
- Fixed some effects being rendered twice (if they were added from csv, both new and backward-compat code loaded them).

MagicBounty
- Added two new text variables for use, and changed $faction to $targetFaction (backwards-compatible):
  - $targetFaction The name of the faction (with article) of the bounty fleet.
  - $givingFaction The name of the faction (with article) that's giving the bounty.
  - $rewardFaction The name of the faction (with article) that's giving the bounty reward (typically same as givingFaction).

https://github.com/MagicLibStarsector/MagicLib/releases/download/1.1.2-rc01/MagicLib-1.1.2-rc01.zip
Logged
Mod: Persean Chronicles | Mod Manager: SMOL | Tool: VRAM Estimator | Tool: Forum+Discord Mod Database | If I'm inactive for 3 months, anyone can use any of my work for anything (except selling it or its derivatives).

vicegrip

  • Commander
  • ***
  • Posts: 184
    • View Profile
Re: [0.96a] MagicLib v1.1.2 (2023/06/01)
« Reply #29 on: June 10, 2023, 05:21:09 PM »

I was wondering if I could get some help on using the "location_entitiesID" field for magic bounties. Does causing the fleet to spawn in a particular system require establishing a memKey at the start of the game, or could i use some other identifier? For example if I wanted the bounty to spawn specifically in Duzahk, and not any other uninhabited core system such as Penelope's Star, how would I do that?
Pages: 1 [2] 3 4 ... 7