A balatro sound loader.
https://github.com/Goldofleaves/Tonsmith
#Tonsmith
1 messages · Page 1 of 1 (latest)
I have an idea. Make so we can make soundpacks and change them with an in-game menu.
Examples: https://cdn.discordapp.com/attachments/1209506360987877408/1404131370774564864/2025-08-10_23-56-10.mp4?ex=689a12be&is=6898c13e&hm=7170d57e2f5947ee25b64afa435423faf9d7b2e8cb7975f6f30c3f27c821386a&, https://cdn.discordapp.com/attachments/1333809003829923900/1403986238624497754/2025-08-10_14-17-28.mp4?ex=68998b94&is=68983a14&hm=385e3e8c85deab45e901b4ca72c665def77a72d7bffe9dad4e344618becbd295&
you can just edit the files
Why is this so deeply satisfying
no lmao
instant instal
amazing
i dont know how i should react to that
-# this mod has gained more traction than FG wtf. Is FG really that fucking horrid?
you onto nothing
?
do we make a server lmao
Alright.
If you find out how to find the path the mod is located in tell me.
I want to know.
can we react with a different emoji 💔
So do I remove alt SFX from FG, @weary trout?
No
ok
Nuh uh
TODO: Custom Soundtrack
I still want to do it myself becuase uh... funsies.
what about the sound effects from cryptid
ill consider
make something like malverk
Alright.
@forest wyvern i invited you to the repo
ok hold on
TODO: request BMM, add readme, make a thumbnail for the mod
evil
It's still a work in progress.
alright
were litterally making evil malverk
So you can change whatever sound you want
indeed
i will work on the wiki once jogla is finished with the front end
same as how you download any other mod lol
Update front end is taking a while because get_UIE_by_ID is being special.
@weary trout I'll do a quick wiki page thing while you try to figure stuff out.
no like
the github wiki
about how to make
an sound pack
btw i forgot to add it to the zip file but you do need BSFX as an dependency
Amazing
I made a wiki page anyways.
Did you make the github wiki?
I can't make it because erm... perms.
jsut gib perms
yay oko
im here...
hello BepisFever (Ygg, B:SR, Stacked)
raise fist
d
t
the back end is solid enough that we can have a wiki
(dont worry, when the sound replacer is finished, we will have the current sound as a built in preset)
No longer need to type BSFX.toggle_pack("Example") every time I want to test it.
we swear we are working on it.
trust
Cool name
Woah, real 1.0.0 is here!
https://github.com/Goldofleaves/Tonsmith/releases/tag/v1.0.0
-# play fool's gambit, goldenleaf will go fucking insane and kill the rest of the dev team otherwise
its true
Okay I'm gonna give my honest opinion on the mod (before this version released because idk what's on that place)
The way the default SFX is more sci-fi is something I don't really like but that's my problem
The other thing is that some sounds (noticably the booster opening sound) are louder than others
But it's overall good
It's satisfying
@weary trout I fucking told you to level the sounds.
sci fi is awesome though,,,,
i will
Some of them fucking blast my eardrums.
thats future goldenleaf problems
Do it now and I'll upload a patch.
I have to close my ears whenever I open a pack lmfao
That's T-now goldenleaf problems.
We are very sorry for this.
Bump!
Egg pin this
uh... a soundpack I made while testing and for the funsies.
Now that we have a proper release, here is a discord server.
https://discord.gg/ArM93SJtNR
if you make a soundpack, we strongly encourage you to post it in the server
By "better SFX" I was expecting something that gives balatro vibes lmao
-# I know the name got changed but I'm talking about the experience I had before the update
But whatever
Who cares
Should have removed ping actually
to_big = to_big or function(x) return x end``` ass wiki
note: I will continue development, but for any inquiries you may have, go ask me.
oh
It has taken me like an hour or so, but now the UI isn't stupidly large.
basic config menu
new release
this is still tonsmith's greatest achievement
peak
real
hey guys what sfx can be added in this game that can work
Oh!
I'd say any SFX you want.
You can check the built-in soundpack to use as a reference.
ohh I see thank you !! I will try to see if it works
like other games soundtrack could feel nice too :)
If any issues arise, do tell.
Also, if you want, you can join this place thing.
sure !
I myself do not know how to do SFX. I have ported some SFXs other people made.
Just uh... try to not blast people's eardrums.
Is there a list of music mods that are ported over to this?
not much right now
but the discord is the main way for sharing soundpacks rn so you can check that out
I am working on porting some. If you can provide links to these mods I will ask the creator(s) if I can port 'em to Tonsmith.
Otherwise you can port them yourself.
here's mine
You can upload these here for everyone to use :3
it increases tonsmith's value, too
maybe, please?
oh im not done yet
hold on
there's alot more
Let them cook fr
:3
can i see more progress™?
i just woke up
and i havent made progress since im asleep
heres the progress
yummers
can you make a condition where it only plays when you enter blinds
mmm yes
woah, slightly better UI!
Now you can access the mod config from the soundpack menu and there is an actual search feature!
B-Side
Epic Boss Music
Opandora's Box
Cryptid(?) iirc it has a different main menu theme?
Bakery
GitHub
A music replacement mod for balatro. Contribute to afterlightgames/b-side development by creating an account on GitHub.
GitHub
Adds the orchestral score of the Balatro theme from The Game Awards to all boss antes. - WalWalrus/EpicBossMusic
GitHub
Opandora's Box - A Balatro mod. Contribute to ohpahn/opandoras-box development by creating an account on GitHub.
I'll look into porting B-Side and Bakery
i ported the entire OST from opandora
I don't think you need to port epic boss since the mod itself has their own config
did you fuck up with bossa nova's pitch
fixed it dont worry
Well, I guess @bitter crest has me covered on the porting aspect.
New Tonsmith release!
https://github.com/Goldofleaves/Tonsmith/releases/tag/v1.2.0
Now there should be less shenanigans when loading modded sounds and what not.
If you find any issues, let me know.
will it fuck my port
got you covered
depends on how you have your TNSMI.Pack
I think it should be backwards compatible, tho.
May I have a look at it?
sure
It shouldn't break.
Also, I believe the mods field should be {Vanilla}, since it only changes vanilla stuff
oh i thought its the source of the song
<3
Yeah, the documentation isn't clear.
I'll fix that, probably
Remind me in the next revision.
btw
here
@forest wyvern i cant do the main menu theme btw, no check for it and main is just going to play it every conditions
You can add checks, tho.
You just slap one of these into the sound you want and presto, conditionals!
Also, don't even bother setting a stupidly high number, Tonsmith will just use your pack priority as the actual number.
So long it returns anything that isn't false or nil, Tonsmith will pass the conditional.
give me like an example
hold on
TNSMI.Pack{
sound_table = {
{key = "key", select_music_track = function () return true end}
}
}
It hasn't been fully tested, so shit might not work as expected.
If issues arise, do tell me so I can look into it,
wahoo!
mario sounding ass
the pack is done
soundpack released for future newcomers
The miku one is very good if you want to go deaf.
Oh, was B-Side already ported?
It got ported a few hours ago, I believe.
Join the discord server and see for yourself, dunno
Looks like it was, awesome
Good job on the sound manager this is just what I needed
Also thanks jogla for bringing it to my attention
<3
tonsmith
yup
here
it got expired
it did
I saw
thanks
Enjoy the few soundpacks there are.
btw i actually made my own mod
ah
bk
did you noticed the mod i made?
Yes
Very useful mod
Anyone else encountering missing sounds?
- money
- drawing cards
- chips?
No worries, shoot a ping when it's fixed
It has been found that the source of the problem is a faulty soundpack. (I tried removing every soundpack from my mods folder and Tonsmith worked just fine).
It's BossaNovaMusic from 0PandoraBox, could another person test as well?
I will later.
Unrelated, how to remove sound files from other mods without breaking it?
Game crashes when the sound folder is removed
What do you mean?
wdym
I'm pretty sure you can't delete the whole folder since it needs that to function
But could you not just delete the contents of that folder?
Sound files from other mods are already in Tonsmith's Sound Packs, want to remove them from the original
Wanted to disable the music from Lost Edition, but removing the sounds folder leads to a crash
Ah.
Basically, TNSMI.Pack uses SMODS.Sound, and because of how SMODS.Sound works, the game will crash if it can't find the file for whatever sound.
If you want to remove a certain sound/music from a given pack, you will have to remove the entry from the TNSMI.Pack call.
a cheesy way to remove the sounds is to add a file that is silence in your files and replace those sounds for that
Support to do just this might be added in the future.
I'd say this is the better (intended) option.
I guess I know what I'll be doing this weeked.
Rewrite half of Tonsmith's code, again! Yipee
Not removing from Tonsmith's files / soundpack
I want to remove sounds from another mod, in this case Lost Edition
Ah, then yeah.
Just make a soundpack that replaces the desired sound with just a silence file.
Support for this exact function is NOT planned for Tonsmith.
Are the extra files in sound packs needed?
- arcana
- boss
- celestial
- shop
Think they're just copied from main.ogg
They are different tracks, but you can make them point to the same file.
@quaint sundial
tonsmith
Tonsmith
TNSMI revival
Is it really going to be revived?
Okay aside from the known bug of not yet figuring out how to make the option cycle shoulder buttons dynamic without reloading the page, all of my contributions should be done? Ish?
Okay lastly, I updated the Spanish localization with some of the changed entries I made. I'm not a Spanish speaker so it was mostly a best guess based on similar instances of words I could find
Ah
I will take care of the spanish localization.
@lofty herald Is it ready?
u sure this is how it's supposed to look?
Are you using a 4K monitor?
Hmmm given the other one looks correct, I'm assuming the export for the 2x version of the default one is wrong
But also I should clear the default ones anyway since they're test objects
Yep, my mistake
Whatever the reason, You're seeing the 2x version of sprites and the 2x for the default image is wrong
I can fix it when I get outta bed, plus I have to get rid of the 10 or so declared dummy soundpacka
Mainly with dummy packs and spanish localization for whatever reason.
....huh
ye
I wonder why I didn't encounter either
mods probably
I did revert the English text back to being labeled default so that it falls back on it
And the dummy packs...... Hm
Also whatever you did, you need to add or remove soundpacks for this thing to work
Yeah, I noted that in an earlier PR
I have to figure out what the fuck you did to the mod.
It correctly updates the option cycle text and the active colors, but for whatever reason, it won't seem to update the interactive state
No like, the entire thing.
You basically re-wrote the entirety of TNSMI.
So now I have to figure out how it works now.
yipee.wav
Loading is basically identical, call TNSMI.SoundPack{} with a key and a sound table.
The main changes are:
- priority for soundpacks is no longer determined or saved in a separate value.
TNSMI.config.loaded_packsis the currently loaded soundpacks in priority order, and every time this is updated,TNSMI.save_soundpacks()runs through them in descending priority and fills in any sounds they replace, ignoring lower priority sounds if they've already been filled - TNSMI now uses
SMODS.GameObject, which means more direct support for localization and UI. So the author/description has been moved to be similar entries as Jokers - a bunch of UI generation functions and callbacks were changed essentially to wait for player input before doing as any reloading of packs or priority
- Upon opening the menu,
create_UIBox_soundpack()is called. This creates a priority CardArea, and the number of cardareas specified in the config rows, then places them in the UI - Every time it needs to reload the list of available soundpacks, it calls
G.FUNCS.reload_soundpack_cards()which specifically regenerates the cards in the config rows - The SoundPack priority is only changed when the menu is opened, a pack is toggled (callback
G.FUNCS.toggle_soundpack()), or a pack is dragged to change priority (G.FUNCS.TNSMI_change_priority()) - Soundpack cards are handled by the
create_soundpack_card()function which creates the "fake" card and gives it a dummy center referring to the SoundPack, which handles the sprite atlas for the cover art, the hover behavior, and the click interactions automatically
- Upon opening the menu,
Also, show me your mods list and I'll match the dev environment as much as I can to fix bugs
I still have to figure out how to consistently replicate it.
got it
Still checking the code to be able to modify it in the future and what not.
Nodding nodding, understood
I have fixed the thing by moving a single line.
"shit problems, shit solutions"
at this point you are basically a Tonsmith dev, btw
Like, over half of the code of TNSMI is yours now, is it not?
shrug I admittedly didn't even intend or expect it to get merged. My goal was basically just to fulfill the specification for user use for providing it with Cardsauce/Arrow
Oh!
That..... was way easier
Huh
You see...
Tonsmith's code was a fucking dissaster.
Like, it was stitched together so fucking badly.
And a re-write was intended at some point.
You quite literally came in clutch for that.
So uh... yeah.
Well, in that case, let me go in and document the functions better
Now I don't understand the code if 'my' own mod.
Currently fixing a git conflict thing
because I am stupid af
Hmm, for legacy support, I might re-add TNSMI.Pack as basically an alias for TNSMI.SoundPack
Calling one just calls the other
Oh, okay
Oh wait
lmao
I know why it crashes @forest wyvern
It's because I took out the localization definitions for the dummy packs without actually taking out the dummy packs themselves
That's my bad
I made one already for the fixed sprite size
I am juggling rollbacks and shit because I may or may not have pushed things to main instead of dev.
Right now it's saying im 2 behind the main branch, but what's on the main branch looks like stuff from a few PRs ago
Hold on Im closing the one pull request for a bigger one
Okay, made a new pull request, and it's actually targeting the dev branch now
This should, as far as I know, have all my changes
merged and hopefully it works..?
Main still seems broken, since main.lua seems to still have my version
So almost there
Nodding
Then yeah dev branch should be everything
That last PR added a bunch of comments explaining some specific choices I made for functions
huh?
I don't fucking know
That means there's a syntax error, but nothing showing up on my end
I just cloned from your repo
oh lmao I know why
"please fix"
Like I said, your main branch is broken, and my repo's main branch is synced to yours
I don't fucking know
Mine is actually in the branch VG/code-refactor
I do not know
You might have to roll back or something idfk
Sorry for the trouble 😭
you're fine, git is Like This sometimes
Yeah somehow there's a weird frankenstein of the orignal utils code and the refactor code
sorryw
Although I did just encounter a bug I need to fix, which is that it's trying to load the dummy packs from my saved configs after they were removed
So a similar bug would probably occur if you disabled a mod that added a soundpack
Try now
That's vanilla sound, yeah
ah
huh.....
I think I know
Go into your balatro > config directory here and delete this file:
santa mierda
It's the old saved config from the earlier version, and I didn't add the default balatro being part of the default config until later
Will maybe look into that.
So it'll get recreated on next load
oh I can fix that
sounds don't get replaced when loading the game
and a wack ton of extra bugs probably
that's.....
it sounds like you're using an earlier version of my changes somehow, cause that also was something I didn't add until later?
I do hear the replaced sounds upon loading from my current repo
Possibly since it uses the postInitSplash function it's being overriden by something else?
lemme pull again
Changed it so that it's just empty when there's nothing to display
Just make it say page 1/1
Or make it so it blacks out like the other two buttons..?
Could def do that yeah
also this lol
Yeah no clue. I tried calling recalculate() but seemingly that's still the result
????
odd
I'll probably re-make the sprite myself.
Mainly because golden leaf just took a random sprite from FG
Ah I see
Weird, it's somehow introduced a bug where sounds aren't resetting when packs are unloaded. Investigating,,,
There, fixed
@forest wyvern I also fixed the issue of sounds not being loaded on start. I was initially calling them in an overriden function initPostSplash without realizing that wasn't a vanilla function and was instead implemented in my API and called from prep_stage
k
Plus some more outlying bugs and edge cases such as fixing an issue when no other soundpacks are loaded, since I'm not including Fool's Gambit OST with my provide version
The double tab
...whoa
ooop yep, I see it. It's correctly loading the audio tab, but it's not setting the game tab as unchosen
btw, check if folden geaf has given you perms and shit to directly edit stuff in the main repo
So we don't have to juggle the two repos.
oko
fucked up menus when changing rows 'n stuff
It also affects card and button size.
It should affect the card and button size, they scale a little smaller when you expand the rows to make sure they fit on screen
So the right one looks like relatively expected behavior. The left one not so much
It so wideeeee
Im having trouble on my git even setting the remote URL to the main repo it seems
Probably remove the scaling feature.
I def can, but I doubt 16/4 is gonna fit
The default setting is the recommended one, but shit can go off-screen intentionally if you make the menu too large.
It is just meant to hold as many packs as possible in one screen.
If you are maxing it out, you should expect the menu to be stupidly large.
It's not that it's stupidly large, it's that it's completely unusable
(this is with the scaling turned of)
Set max size to smaller numbers
Like 12x3
(allowed max size)
The old numbers were meant to be compatible with the old UI
The largest it can be while still fitting entirely within my monitor (1440p) is 2 rows, 9 columns
And it clips the top ever so slightly
Scale down the cards slightly, maybe?
Also the middle looks so empty.
Max 2x8, min 1x4..?
I don't know if we need that setting at this point.
This is 3/8 with the packs sized down
mmmmmmmmmmm
They're a tad small for my tastes so I can cap it at 2/8 like you said and make em bigger
i am eepy af
Go sreep
Can you cramm the cardareas closer together?
yep
2/8
noices
And yeah it's empty just cause it's scaling to the column size. I thought it was more user friendly if the pages stay the same size even if the final page can have less on some rows
So your eyes aren't moving around as much if the last page suddenly squishes
Plus recommended setting looks nice
Recommended size looks nice.
The larger sizes are just if you really want.
i.e. have a shit load of soundpacks or something idk
I am going eep
I'll check back tomorrow
Night!!
I am alive now.
I made a couple more changes to huddle the packs closer together, plus a few more buggixes
All of it is in my fork/open PR
ok
So the main things that still need figuring out are basically all related to the option cycle:
- fix the option cycle not updating its interaction state when a search query changes the page number between 1 and 2
- fix the option cycle for some reason having an extra space when the search list is updated from 0 to 1 or greater