#[API] - Loading and Config API

1 messages · Page 1 of 1 (latest)

fading spade
#

Hello y'all. I've been really getting into balatro modding but didn't like a lot of the boiler plate I was having to write. So I created two separate api's to make creating mods easier! The loader-api is designed to allow for more complex mods without having to specifically load every file. And the config-api is designed to make creating config tabs for mods easier. I've tried my best to document how to use them, but feel free to contribute with PR's or github issues if you do end up using them.

https://github.com/jlwoolf/balatro-loader-api
https://github.com/jlwoolf/balatro-config-api

Here's one of my mods that utilizes both for refernce:
https://github.com/jlwoolf/balatro-dna-splice

GitHub

A Balatro API to simplify and standardized mod development! - jlwoolf/balatro-loader-api

GitHub

Contribute to jlwoolf/balatro-config-api development by creating an account on GitHub.

GitHub

Contribute to jlwoolf/balatro-dna-splice development by creating an account on GitHub.

marble shale
#

reequiring lovely is probably not recommended as most mods don't need lovely

#

in the example metadata

#

also that version for smods might not work

#

also polluting the global space isn't the greatest idea

#

it would make more sense to just do smth like SMODS.current_mod.loader_api_config = ...

#

then you can just go through mod objects when someone inits

#

also config.lua is special in smods and smdos will load it automatically and use it's return for the defaults in SMODS.current_mod.config

#

also you can use SMODS.load_file to load files. It takes a second arg for the mod id and resolves paths for you

#

also it makes the stack traces a bit betteer