#💻・modding-dev
1 messages · Page 116 of 1
pixel art is not easy 😭
eyah i know thats why i dont do it
Can you give suggestions on where I should patch into, directly into function Card:shatter(), or a function or anything that just simply calls shatter(), or somewhere else
I also may want to do card:start_dissolve because of its more subtle destruction sound and a different animation (I plan to have my ice enhancement use shatter and fire enhancement use start_dissolve)
i did it
tweaked it a bit to improve contrast
hold on what's with the gray borders or is that just discord mobile being funny
when making my first proper deck that isn't just a test (wanted to make it look nice at least as I'm using it in the meantime) I'll definitely lean on a much lighter pink, so that purple isn't forced down into being way too dark
could just be mobile being funny? if you mean around the card symbols and such though I also have no idea
I imagine it's probably something DSL related since the number cards especially are literally just recolours from the base set
the KQJ are of course taken from the collabs, albeit with different palettes
actually what did you use to recolour
ah
is this 2x
these are 2x yeah
has anyone thought of making a YOMIHustle balatro mod
like a joker mod themed around yomih
not quite sure if I need to be redoing them entirely at the larger size though; base card set doesn't
i might as a side project with my current mod
go for it
i feel like it would be cool (given im obsessed with both yomih and balatro)
how do I check for suits held in hand? the steamodded example mods don't go over shoot the moon or baron
i might make a plus version of the vocaloid mod I'm making
you could decomp balatro to see how those work
where it adds more content than just reskinning face cards
yessss
you can't decomp balatro
-# it's not compiled
kek
i know the feel
oh
then how do yall get the code?
code store, they only sell soup for some reason
you just extract the executable with something like 7zip
yea thats what i mean
why are you buying code at thee soup store?
they actually sell code at the clothes store
no, no, you buy soup at Code
already done clubs
should add an example for that though tbh
just tell me all twelve lmao
they're seliing code at the grocery store these days
oh hell yeah
omg im prob gonna do another all nighter
AAAA WHY CANT I SLEEP
kagamines diamonds?
i planned that yeah
its too late to sleep now its 6:35 am 😭
It will be a sad day when people forget these references
meiko queen of spades ,,,
one side is rin and the other is len
thought that'd be cool to do yeah
that is what i was imagining
two in one combo deal
diamonds were crammed as hell
the only reference i can see is that WHY ARE YOU BUYING CLOTHES AT THE SOUP STORE meme
these look so much nicer before balatro renders them
the second reference is the friends we made along the way (I accidentally said references instead of reference)
lolol
i don't want to just include vocaloid
valid
i mean the mod name is vocalatro and all
gotta get the whole vsynth group in
might not be able to fix everything
john vlatro
if I were better at pixel art I'd be making a pjsk deck
@glossy stone
only sad thing about a pjsk deck would be, well, one group has to miss out, and one member from each group also has to
i know -_-
well maybe the ones who miss out can be on jokers and bosses
e.g. cerulean bell can b-
SOB
the last lua thing I did was 10 years ago in gmod, time to relearn it!
pretty neat you can just extract this stuff though
MIZUKI AS THE CERULEAN BELL
myst yknow what after i get the herta im gonna make more art so i can release original sound for real 1000% this time
real
it's not dead i have just been doing everything BUT it
wxs and vbs have to get spots but it'd make me sad to have to drop one wxs member
make an hsr mod so you stop procrastinating
tomorrow imma extract the exe bc theres some cards that arent in examplemods
It’s evalute_play in state events you want
aventurine plays balatro #1
@glossy stone what would you say if i were to make a plus edition of the mod I'm working on to add content
what if i. reimplement decor guide
Cool beans!!
with the length of the game's code, I wonder if its under 120k tokens
tokens?
blegh
there are actual good uses that isnt the blatant art garbage
for instance you can automatically segment out useful notes and then have people fill in manually
why do you have a gif for everything sob
whats the point of ai if the hard work is done manually
yea thatd be cool, just getting notes for manual use
i am a bit silly
tho every AI isn't generative AI
I doubt the entirety of the code would be documented as fast
every time someone says AI people would think about genAI
but if you are interested in documenting all of it, that would be cool
my favorite AI is https://en.wikipedia.org/wiki/Allen_Iverson
Allen Ezail Iverson ( EYE-vər-sən; born June 7, 1975) is an American former professional basketball player. Nicknamed "The Answer", he played 14 seasons in the National Basketball Association (NBA) at both the shooting guard and point guard positions. Iverson won NBA Rookie of the Year Award in 1997 and was an 11-time NBA All-Star, won the All-S...
Ai Hoshino!!!
a LLM is just a next word predictor on drugs
plenty of IDEs have the bare minimum of predicting what you want to say and you save a few seconds of typing
why is his nickname The Answer
and also high contrast
Balatro Boss Blind
@glossy stone
realistically emu should be on queen (bc of the cover) but it's funnier with her on king
omg saki 
toya just makes sense as a jack
-# left side right side
precisely why rui and tsukasa are both kings
both would also work for jack tbf
thanks mizuki
mmmmmmm
tbf the mizuruian group is peak but it's making it harder to make other sets lmao
i actually don't have much pjsk knowledge LOL
like akinene would work so well with an
wonder if it would be able to figure out useless/broken stuff
there's a couple things like that in the code
I mean for what its worth you can just point those out and we could probably figure that easier manually
I have these things
emu my beloved ❤️
wondahoi
Masquerain spotted
(i think i might have turned modding dev into pjsk chat)
masquerain my beloved
tbf pjsk would make for a baller deck skin
it's just that someone's gonna get left out 💔
💔
kid named six suits
18/20
😭
fuck
kid named 60 suits
and include all the mikus
xela mentioned
hold on a moment
oh i forgot to make a high contrast version whoops
behold

anyway a pjsk deck skin would go hard
we'd have to commit to making it ten suits or something though lmao
Happy cards already use a heart symbol so we'd just carry Hearts over, so we'd have four regular card suits and four pjsk ones
Heart (red), Spade (black), Club (teal), Diamond (yellow), Cute/Penta (pink), Pure/Sprout (green), Mysterious/Moon (purple), Cool/Hexa (blue)
we'd still have to miss characters
i think i preserved the integrity better than the clubs
tetoeeeeee
ooh
awesome ui
peak ui
what the green box doing
glop
fire
glop
glop
glop
thoughts
hell yeah
hold on a second i know you
you do
hi
in fact i remember you
🔥
my thought is that this is a better hack
i think
nvmm stupid
I'm stupid
brain no worky
rip brain :(
I'm not good enough to say lmao
Me when I go to the tailor
don't even need that
just discard anything above 2-5 that you're not playing
it's definitely a bit awkward, but it's a pretty unique idea
oh lowest card
might be a bit too strong then lmao
could make it highest card in hand or shrink the options down from 2-5 to just 2
it'd be sorta like Baron, giving you xmult for holding a card, but it only goes off once
and during joker calc, so it synergizes better with flat mult jokers
ye
it's kinda like an inverse hack? but they reward the same thing (keeping your 2s around)
just one rewards you for playing it, and one rewards you for holding it
Would tackling this as my first game to mod be too much for a beginner or will I be able to be just fine
Balatro Moding is fairly simple on the scale of modding games
dont gain nothin in life by putzin around about it
just was wondering, that’s all, I’m barely getting a grasp on where to start
oh i just say weird things you'll be fine
The steamodded wiki has a lot of good info https://github.com/Steamopollys/Steamodded/wiki and there's some example mods https://github.com/Steamopollys/Steamodded/tree/main/example_mods/Mods
Thank youuu
still coming up with more jimbo ideas
Jimbo shuffle seems busted
yea just changed it to up to rare only but it still might be a bit much
cap of rare and chance to destroy itself is probably fine
Yeah or on sell effect
hmmm sell effect might be cool too
i think i'll do a different jimbo with a sell effect tho
ima just slap a 1 in 10 chance to self destruct after each round
or something like that
i just meant chance to hit itself with its effect
ohh that's kinda fire
super mario party jimboree
FR
Are the jimboree effects mutually exclusive?
yea the idea is it just iterates through the hand before scoring and applies stuff individually
Oh the chance is for each card
i just noticed the wording is confusing lol
changed it to each card instead of any cards
chance time
when you play all glass cards and you get hit with that
so your hand becomes shit
calculate = function(self, card, context, effect)
if context.cardarea == G.play and not context.repetition then
for i, playedCard in ipairs(context.scoring_hand) do
if playedCard == card then
local leftCard = context.scoring_hand[i-1]
if leftCard.base.suit == card.base.suit then
leftCard.config.center = G.P_CENTERS.m_fm_slow
card_eval_status_text(leftCard, 'extra', nil, nil, nil, {
message = "Slowed!",
sound = "fm_slow",
colour = G.C.BLUE
})
end
end
end
end
end
Need some help here, I'm making a Freeze enhancement that if a card to the left of the Freeze card has a matching suit, it will become Slowed. However, when it does get Slowed, its texture won't change, but in the deck it did.
On top of that, if I do actually play that Slowed card the next time it appears, then the textures pop up
Seems like the timing was off, but I don't know how to rearrange it
diamonds should have an abundance of choices
How do I add an effect to a custom joker (the in-game effect, not the text)?
programming time baby
https://github.com/Steamopollys/Steamodded/tree/main/example_mods/Mods the ExampleJokersMod here should be a decent guide to start learning about joker calculation
https://github.com/Steamopollys/Steamodded/wiki/Guide-‐-Joker-Calculation this is another page i check often
I've read both but don't really understand them. How do I use all of those contexts and effects?
one of your copy patches can't find the file it's been passed
I have to mention too that the most lua I've written is a Roblox script that changes one color💀
LOL fair
😭
so when you're creating the joker object you gotta add a function like this
calculate = function(self, card, context)
(do stuff)
that's where the magic happens
say you wanna recreate the default joker
first you have to check if we're in the joker calculation stage of calculating a hand
so you do
if context.joker_main then
and from there it's gonna ask you to give it a value to add to mult or whatever you're trying to do
in the case of a basic jimbo it would be just this
mult_mod is the +4 you apply (in this case it uses the stuff specified in the joker's config)
and the message looks convoluted but it's just telling the game to do a basic +mult effect
How do i check for cards (for example, +3 mult for every face card)?
You aren’t applying the enhancement correctly, you need to use set_ability
then you need to check if the game is going through the hand
in that case i think it would be if context.cardarea == G.play
card areas are basically different containers for cards so like your hand, jokers, consumables etc
and then you also have a value called context.other_hand that gives you a reference to the card that is being scored
leftCard:set_ability(G.P_CENTERS.m_fm_slow, nil, true) like this?
oh you can also check if context.individual
i think that's the better method
anyway you use context.other_card to check if it's a face card and apply mult if true
like i said the ExampleJokersMod explains all this in its code decently well
I'll read it again, thanks for the help!
What's the #1# used in line 29 of the ExampleJokers?
there should be a loc_vars function that gives that text a variable to show
so that's just saying to put the first value in that spot
in this case it's the mult applied by jimbo
loc_vars let you put changing values in your joker descriptions
as already said #1# is the first, #2# is the second, etc
you can put as many of those as you want
this is usually variables like a scaling joker's mult
Cool to know, that's definitemy useful
but even stagnant variables tend to use these too
yea for the sake of not having to change a number multiple times
if you use them for every variable you can, it'll work with Cryptid's Oversaturated and Glitched editions and Misprint Deck
it's also used in stuff like odds since all 6s exists
yeah
the example jokers mod has probabilities on it check that
and the #1# values can still be text formatted
Thanks for letting me know
always remember
this game is open source modding
if you wanna do something, and someone else already did it, go check their code
and then borrow it
and for legal reasons, by borrow it, i mean completely rewrite it from scratch
because otherwise that would technically break a rule
oh i might be breaking a rule by saying that isn't that accusing? that rule makes no sense to me-
you can accuse people in mods' dms
every game is open source modding if you try hard enough

if value then?
if not value then
oh my god i'm so dumb
if this shit crashes again i'm gonna be very annoyed
yeah it fucking crashed again
I literally just need to check if there is an edition or not
i'm not
then show the code maybe?
it's crashing on the line
if value.config.center.key == "j_splash" and not value.edition.key then
i'm trying to check if it doesn't exist
not (value.edition or {}).key
key is under edition
optional chaining in lua is cursed
you can also do something like not value.edition or not value.edition.key but gosh that's long
and imagine doing that for like
yeah key is the name of the edition I originally wanted to check if it was negative or not
but I should make it not override edition
not card or not card.config or not card.config.center or not card.config.center.config or not card.config.center.config.extra
not (value.edition and value.edition.key)
now this is lua gaming
not ((((card or {}).config or {}).center or {}).config or {}).extra
You can just do not value.edition in that check anyway
to be fair js had this same issue for quite a while
people love javascript too
to be fair I think you should be able to assume if you have a card it has a config and center value
?.
thats relativly nww
ik
i couldn't think of a better example
okay well that worked
now I can test that lovely patch I made like yesterday iit doesn't work
Also how cursed would it be to have a tab that doesn't actually render anything but instead opens a new menu
the cashout screen now displays
nothing in relation to the joker's end of round cash
but it's still there.
Sounds like a button
yeah so my cashout issue is still unresolved
the patch simply removed the text from cashout
Yes but it would be in the tab menu
specifically I want to have multiple tabs for DebugPlus's config
and I can do that fine with smods
but for the games built in settings
This menu is already tabful
So I'm thinking what if the DebugPlus tab just opened a new menu with all it's tabs
yeha that makes sense
How do I make a joker remove cards from your hand?
hold on what was the context for doing stuff when a blind is selected
whats the best way to run code after all mods are loaded/the game is ready
oh my god i typed blind_selected i' stupif
okay it's not selecting_blind it seems
fuc
how do i modulus in a shader? im trying %but it isnt working
okay it's setting_blind
mod(x,y)
i hatte shater
possibly modf
im not sure
ah nevermind
its fmod
The GNU C Library
oh wait
is that not it either
i frogot what a math is
okay nvm
yeah
its just mod()
what is the context for checking cards in hand?
How do I make a Joker remove cards from my hand after a hand is played?
as in destroy the cards?
Just discarding them
I already tried, but it uses its own event
makes sense i guess shaders only really use floats
context.individual and context.cardarea = G.hand
if any_selected then G.FUNCS.discard_cards_from_highlighted(nil, true) end this is what i see in the blind
oh my god thank you so much
but its probably lik
G.FUNCS.discard_cards_from_highlighted(nil, true)```
just guessing
G.E_MANAGER:add_event(Event({ func = function() this is what I found on blind.lua
dont worry about that part
i thing im messing something up here
thats the atlas right
yes that is deffinitly a spritesheet
how do i do thi
vec2 screen_coordsgood = vec2(mod(screen_coords.x / 1000, image_details.x), mod(screen_coords.y / 1000, image_details.y));
i think im moding the wrong things
i dont think my mod is moding at all
what the fuck
what are you trying to do???
shader moment
whar r u doing
misprint on steroids
he is done
my first 5 jimbos have been created
Hello, I come here this time to ask if someone could solve for me this very specific issue:
I have made an enhancement that scapes its mult based on how many cards with that enhancement are in your entire deck. The description works and updates as expected, but when the cards score, the mult that is applied lags behind one played hand. For example. In your first hand you have 1 card with this enhancement and as such it grants you +5 mult. In your second hand, you manage to create 2 extra cards with this same enhancement, granting you +15 mult (+5 for each card), but when the hand is played it only grants +5 mult. Finally, in your third hand you have the same amount of cards with this enhancement, that when played each score +15 mult as it should.
please help
How do I properly check for suits held in hand? Because
local suit = context.individual:get_suit()
if suit == "Hearts" or suit == "Diamonds" then
return {
mult = self.config.extra.mult,
card = context.individual
}```
gives this error:
Oops! The game crashed:
main.lua:3826: [SMODS RDJ "RandomJokerDice.lua"]:133: attempt to index field 'individual' (a boolean value)
Ah, I see...
context.individual refers to the context and not the other card.
It throws an error because a boolean doesn't have any other function/list/whatever inside it, only it's value.
You are trying to access this inner list/function/whatever, which doesn't exist.
there's no calculation here
further explain
you need to put the code in the calculate function
*So far the only thing I have ever made are jokes
So idk how enhancements really work.
they work almost entirely the samme
I don't know why you would assume otherwise and try and do everything in loc_vars, a function you should already have known about from working with jokers
except enhancements don't have card destruction outside shatter iirc?
because it decided to not work on calculations
if debug_mode then
SMODS.Enhancement({
key = 'fire',
config = {
mult = 0,
extra = {
b_mult = 5,
c_mult = 1,
}
},
loc_vars = function (self)
return {
vars = { self.config.mult , self.config.extra.b_mult , self.config.extra.c_mult},
}
end,
calculate = function (self, card, context, effect)
self.config.extra.c_mult = 0
self.config.b_mult = 5
for k, v in pairs(G.playing_cards) do
if v.config.center == G.P_CENTERS.m_sbc_fire then
self.config.extra.c_mult = self.config.extra.c_mult + 1
end
end
self.config.mult = self.config.extra.b_mult * self.config.extra.c_mult
print("mult | ",self.config.mult)
end
})
end
is this fine?
idk
eenhancement calculation is a bit scuffed in that it doesn't have every context and you can't return from it
-# for now
-# soon™️
you assign a value to self.config.b_mult on 2nd calculation line when that doesn't exist
i assume it's meant to be either self.config.extra.b_mult or self.config.mult
you're also using the prototype object
wat
you should be using card.
fact: i stupid
instead of?
self.
yes there's a self and a card don't change those in the function parameters
btw, it now doesn't work at all.
It just keeps the mult value at zero
if debug_mode then
SMODS.Enhancement({
key = 'fire',
config = {
mult = 0,
extra = {
b_mult = 5,
c_mult = 1,
}
},
loc_vars = function (self)
return {
vars = { self.config.mult , self.config.extra.b_mult , self.config.extra.c_mult},
}
end,
calculate = function (self, card, context, effect)
self.config.extra.c_mult = 0
self.config.extra.b_mult = 5
for k, v in pairs(G.playing_cards) do
if v.config.center == G.P_CENTERS.m_sbc_fire then
self.config.extra.c_mult = self.config.extra.c_mult + 1
end
end
self.config.mult = self.config.extra.b_mult * self.config.extra.c_mult
end
})
end
idk
is there a way to modify a card when it is drawn to the hand
you haven't put the code in any context
so yeah it makes sense that it isn't doing anything
guess context.individual?
I need to update it any time the player hovers over the card and when played, probably,.
you haven't replaced any of the self.s...
yes
ok
self refers to the prototype object that is used to create new objects, card refers to the actual object you're working on
wait so how do I check correctly then? because apparently the context for cards held in hand use context.individual
loc_vars should be function(self, info_queue, card)
something like other_card or something, I don't remember.
Hold on a sec.
Best I got is this for you.
probably you should just do context.other_card:get_suit
I am so god damm lost wtf
@bold sleet to make it do stuff right now though, you have to manipulate the effects table appropriately
if debug_mode then
SMODS.Enhancement({
key = 'fire',
config = {
mult = 0,
extra = {
b_mult = 5,
c_mult = 1,
}
},
loc_vars = function (self, info_queue, card)
return {
vars = { self.config.mult , self.config.extra.b_mult , self.config.extra.c_mult},
}
end,
calculate = function (self, card, context, effect)
if context.individual then
card.config.extra.c_mult = 0
card.config.extra.b_mult = 5
for k, v in pairs(G.playing_cards) do
if v.config.center == G.P_CENTERS.m_sbc_fire then
card.config.extra.c_mult = card.config.extra.c_mult + 1
end
end
card.config.mult = card.config.extra.b_mult * card.config.extra.c_mult
end
end
})
end
(if you want modify it and send it back, please)
if context.individual and context.cardarea == G.hand then
so here context.individual also becomes context.other_card?
oh right, it's card.ability not card.config
no, this one stays the same
context is a table of different values
ok
:3?
im trying to do the unmoving plain
this thing simply does not work at all.
if debug_mode then
SMODS.Enhancement({
key = 'fire',
config = {
mult = 0,
extra = {
b_mult = 5,
c_mult = 1,
}
},
loc_vars = function (self, info_queue, card)
return {
- vars = { self.config.mult , self.config.extra.b_mult , self.config.extra.c_mult},
+ vars = { card.ability.mult, card.ability.extra.b_mult, card.ability.extra.c_mult},
}
end,
calculate = function (self, card, context, effect)
if context.individual then
- card.config.extra.c_mult = 0
- card.config.extra.b_mult = 5
+ card.ability.extra.c_mult = 0
+ card.ability.extra.b_mult = 5
for k, v in pairs(G.playing_cards) do
if v.config.center == G.P_CENTERS.m_sbc_fire then
- card.config.extra.c_mult = card.config.extra.c_mult + 1
+ card.ability.extra.c_mult = card.ability.extra.c_mult + 1
end
end
- card.config.mult = card.config.extra.b_mult * card.config.extra.c_mult
+ card.ability.mult = card.ability.extra.b_mult * card.ability.extra.c_mult
end
end
})
end
should I decrease the cap
considering bean gives +5, I think thats fair
Let's see if it works...
I mean it still won't do anything
oh lmao i glossed over that
but making it do something is an easy line
I am loathed to teach people this convoluted method though
Eh, fair enough.
true, I'll keep it like that
but I don't know how to fix it up, tho
yes but it's a dumb way of doing it that's in the process of being rewritten
and it wont work when the changes are done
why are we gray mode
why is the jimbo there??
screen_coordsgood = screen_coordsgood + image_details.xy;
// printf(screen_coords.x);
// screen_coords = mod(screen_coords, image_details);
vec4 tex = Texel(texture, screen_coordsgood);``` why is my color getting removwd
-# bettercalc 2 done when
-# when I can work out this silly post trigger timing
What a useful function name
i think it should be icup
how do you spell that
i dont understand that can you spell it out for me
i don't get it either, can anyone please spell it
Mods, Sacrificial Dagger this user
screen_coordsgood = screen_coordsgood + vec2(mod(texture_coords.x, 71.0), mod(texture_coords.y, 95.0));
vec4 tex = Texel(texture, screen_coordsgood);```im not getting any color and i dont know whats wrong
alright chat how do I destroy jokers
like remove
probably look at sacrifical dagger
:start_dissolve()
you mean ceremonial dagger
What are you trying to do?
unmoving plaid
alright figured it out
Here
now how do I check for a sticker
I should check for eternal before destroying
or does it do that for me
either way I need to check the sticker
it does not do that
How are you trying to make the plaid?
A texture or directly in the shader?
in the shader
Okay then, you can just draw on top of the texture
Hi Marie
hi mag
oh fuck it's new day already
can i ask for an help here?
Going to bump this really quick. tl;dr despite patch looking good, vanilla functionality is still being retained with no signs of the newly patched code being run (no console messages)
Feel free
im playing the cryptid mod and it crash every time i play an hand, any help?
in the modding chat no one answer 🥲
You’d probably find more help in the Cryptid discord than here
how should i go about applying a random enhancement to a playing card?
to make sure it's compatible with other mods that is
Probably SMODS.poll_enhancement
I haven't dug too deep, is there anything obviously wrong with something like this, at least except for the cases where calculate_context isn't used?
aight thanks
-# I'm aware the original doesn't do this for consumables but why shouldn't it
G.GAME.starting_params.ante_scaling = G.GAME.starting_params.ante_scaling + card.ability.extra.BlindIncrease this isnt updating the current blind, how do i fix this
it updates the future blinds, but not the blind that you are in
i should learn how to make custom jokers one day
If you have some coding knowledge it’s not too bad to pick up
i had a very unfinished love2d project
forgot something
but yes i have some small coding knowledge
Can I take ownership of something during runtime?
and if yes, can I revoke taking ownership?
actually
no, you shouldn't need to modify center values at runtime at all actually
example steamodded code
taking ownership only ever changes the prototype, so even then it wouldn't affect existing cards
I have a config that takes ownership to inject some custom behaviors, and it's quite annoying that it requires restart in order to apply, so wanted to make it not require restart
you can just take ownership always and bypass the channge if the config is off
hmm, that might work, thanks!
Update steamodded
if card.ability.extra.counter >= 5 and context.game_over and G.GAME.chips/G.GAME.blind.chips >= 0.25 then
this line is crashing "Attempt to compare number with table" ??
counter is a number and it is 5 right now, strange though because this is exactly how mr bones does this check
Talisman moment
I think the only difference in how I’ve got it not is that cards don’t call their own post trigger, which seems correct to me, but they do in retrigger api, which is perhaps a bug?
yeah, wrap 0.25 in to_big
oh is it that easy
i'm going to make a check for talisman first though because if possible i'd like to avoid it being a dependency
then add this
to_big = to_big or function(num)
return num
end
yw
that does seem peculiar but i could see some use for it, like if you want to do something based on your own retriggers or something
Will take another look when my kid is in bed in ~an hour
Wdym
does start.dissolve() have any required arguments
probably not
-# you have kids?????????
card:start_dissolve()? no
how do i update it? just take off the old one from the folder and stick the new one in?
it's crashing
oh you know what it's fucking doing
Yeah
that stupid end of round triggering like 8 times shit
lovely
-# a two year old with another due in the next few weeks
oh i didnt know you had another coming congrats
is there a way i can get the end of round context to only trigger one time
i've been indirectly solving the problem by disabling the code after the first trigger
if context.end_of_round and not context.repetition and not context.individual then
local kyeeee = ""
if not TGTMConsumables.config.CursedRunes then
kyeeee = "SturdyGlass"
else
kyeeee = "SturdierGlass"
end
print(kyeeee)
info_queue[#info_queue + 1] = {
key = kyeeee,
set = 'Enhancement',
config = {extra = 1}
}
...``` this isnt working
another thought, should we skip again messages on empty evals?
set = 'Enhanced'
man
We do
Oh there’s some bad logic on the pushed version, it must be my local branch that is fixed
now it crash at random
oh alright, don't mind me then
What are the crash logs
ok now its nil in nil chance
that's an issue on sturdy glass' end
show sturdy glass code
the sturdy glass shows the right chances
okay but show the code
--glass
key = "SturdyGlass",
atlas = "Tatatro",
pos = {x = 5, y = 2},
unlocked = true,
discovered = true,
loc_txt = {
name = "Sturdy Glass",
text = {"{X:mult,C:white}X2{} Mult", "#1# in #2# chance to not give {X:mult,C:white}X2{} Mult"}
},
loc_vars = function(self, info_queue, card)
return {vars = {G.GAME.probabilities.normal, "5"}}
end,
config = {
x_mult = 2
},
calculate = function(self, card, context, effect)
if context.cardarea == G.play and not context.repetition then
if pseudorandom(pseudoseed("SturdyGlassDebf")) < G.GAME.probabilities.normal/4 then
effect.x_mult = 1
else
effect.x_mult = 2
end
end
end
}```
i also dont know wht i didnt use en_us
this is really bad
using separate localization might solve it? idk, but you should make the X2 mult a loc_vars too
im gonna fix this
this didn't work
and neither did this
it works for my 2 other end of round effects but idk whats up with this one
whats the crash and the code
[SMODS Tsunami "Tsunami.lua"]:1957: attempt to call method 'start_dissolve' (a nil value)
line 1957 is value:start.dissolve()
and it's in a for loop where value is Splash
is value a card object
yes
it looks for splash and destroys them
and it does destroy the splashes before crashing
can you show the whole loop
killflag was supposed to solve the multi trigger but it's not working
forgot prefix for the keys
what
mod prefix
splash isn't a modded joker
dont u take ownership of it
i was going to, but it crashed when i tried to do that
taking ownership shouldn't change it's id?
i still want to do that, but not right now
otherwise wouldn't it break find_card?
this is in context.game_over and not context.individual and not context.repetition
i'm not sure why that would be happening, but iirc the game always uses start_dissolve in an event, so you can try that i guess
okay
wait.
oh my god
this is actually nothing to do with the crash.
I copied the save code from Mr.Bones, which kills itself after activating its effect.
It's crashing because of self:start.dissolve() in there
peak
well fuck
Hey, is there a way to use... like, a dependency variable on SMODS.DeckSuit? I want the atlas to change based on whether or not Bunco is installed (you know, with the whole Enhanced Contrast thingy)
for whether or not bunco is installed you can check local buncoLoaded = SMODS.Mods.Bunco SMODS.Mods.Bunco.can_load
can_load*
i think i'm stupid guys i can't figure out how to apply an enhancement to a playing card 🥲
there should be an and between those
Great, I'll try it out!
iirc Card:set_base
so im using poll_enhancement to get a random enhancement how do i hook that up to set_base
my god i feel useless rn
oh looks like I was wrong
oh so it's setability
yeah i recalled incorredctly
card:set_ability(G.P_CENTERS[poll_enhancement()])
ohh thank you
i was getting all sorts of confused with all the centers and abilities and like why is this so convoluted help-
how would i detect the played cards in a hand's suit? I'm trying to make a joker that triggers when a flush is a certain suit but right now it only detects flushes in general
check the suit of a random scoring hand i guess
center is basically a blueprint for a card
or wait it could be a wild
and defines it's ability
oh my god i forgot to add return true in an event and the game started tweaking and crashed LOL
Okay, I'm getting an 'unexpected symbol near "if"' error. This is my first time making an if statement in Lua... is something wrong here?
buncoLoaded = SMODS.Mods.Bunco and SMODS.Mods.Bunco.can_load
SMODS.Atlas{ key = 'FoLKSpades', path = 'FoLKSpades.png', px = 71, py = 95 }
SMODS.Atlas{ key = 'FoLKSpadesHC', path = 'FoLKSpadesHC.png', px = 71, py = 95 }
SMODS.Atlas{ key = 'FoLKSpadesEC', path = 'FoLKSpadesEC.png', px = 71, py = 95 }
SMODS.DeckSkin{
key = "FoLKSpades",
suit = "Spades",
ranks = { "Jack", "Queen", "King" },
lc_atlas = 'FoLKSpades',
if buncoLoaded == true then
hc_atlas = 'FoLKSpadesEC'
else
hc_atlas = 'FoLKSpadesHC'
end,
loc_txt = "Friends of LK",
posStyle = 'collab'
}```
why does poll_enhancement return nil sometimes
i set guaranteed to true
OH NO
i set "guaranted" to true
good fucking job
you can't... syntax doesn't bend that way
and it STILL does nil
try hc_atlas = buncoLoaded and 'FoLKSpadesEC' or 'FoLKSpadesHC'
Alrighty
is there a way to change the "Saved by Mr. Bones" text
for a modded joker doing the same effect save
lovely
.
Okay, the game isn't crashing now, but it's just giving the regular 'HC' version, regardless of whether Bunco's loaded or not
oh wait... did I forget the local?
not sure why that would be
Specifxally change this to use another loc key
can the lovely patch pattern argument search across 2 lines
yeah
okay great
yeah i have no idea what I'm doing lmao
wdym by a flush being a certain suit?
does any one card in the scoring hand being that suit suffice?
I had a typo. I'm so sorry. But it works! Thank you very much!
does it have to be a common suit between all scored cards?
like all the cards in the hand played are one suit (in this case hearts)
how I pick a random joker in the joker tray that is not the joker itself?
you can iterate context.scoring_hand and check for each card individually if it's Hearts
local hearts = true
for _, v in ipairs(context.scoring_hand) do
hearts = hearts and v:is_suit('Hearts')
if not hearts then break end
end
You can get a list of highlighted cards using this, G.hand.highlighted, is there a similar way to get a list of every scoring card?
in joker calculation, context.scoring_hand
Thanks
if that's not available, you have to recalculate it
how do i pass loc vars into info queue
I still don't know where to put it
probably in the calculate function?
i know that
my new joker as per a friend's request
spoge
this is how i have it rn but it just crashes when i try to select a card
you need to check the context
what would i check
refer to this https://github.com/Steamopollys/Steamodded/wiki/Guide-‐-Joker-Calculation#stages-of-evaluation
Hay, I am curious, Does a template for making modded jokers exist? I am new to the moding scene
how to add custom localisation strings? i need a custom challenge rule
Steamodded has examples of Vanilla jokers
in Steamodded format
goes over pretty much every game mechanic, except held in hand cards
whenever calculate_joker is called, an argument called context is passed into it which contains, well, the context of the call. the joker then checks if the context is the correct for it to execute and if it is, executes. e.g. if it is called with the context selling_self itll execute and give the double tag
here are all the contexts (i believe)
thank you
also, you learn a lot from looking at other jokers from other mods
like, red cards code is in skipping_booster, throwback is in skipping_blind
Hey, sorry to bother, I'm trying to do something that I THINK should be simple, but I'm somehow not having any luck.
I'm just trying to have a joker that activates its' effect (like +3 mult or what have you) only if the Scoring Hand has a King and a Queen in it (so they need to count), and I THINK I got it partially working, but I'm not getting the benefits it should give?
Whenever it procs, the joker has a little yellow particle effect show up, which shows it does register the fact the scoring hand has a king and queen, but for some reason It's not actually giving me the mult bonus. I'm probably missing something obvious, but I can't figure it out 
Thanks. Yeah I just had some fun Ideas for overcomplicated jokers that I want to see in game
theres also a context specific to steamodded, joker_main, putting your code in there will execute it during the time jokers add their mult and chips
right now i have this but idk where the return goes
what is this joker meant to do?
if the played hand only contains hearts (so a flush of hearts), it triggers
yes but like, does it add mult? chips? if you properly set it up you would return the vars stored in config and a message to display
i would put all of that code inside the 2nd if and make your king and queen variables local
oh just do an if hearts == true then return {mult and stuff} end
np
... well nevermind, now it works after starting a new run and changing some things 
Whoops-
Like this, yeah?
yeah, you also don't have to do == true on booleans, you can just if king and queen then
Oh good to know
i'm adding a random enhancement to a card when it gets played but it only works visually when calculating the hand, is there a way i can fix this?
show code
because you have it in an event, it'll change after the score calculations are done
oh crap
I believe if you do it outside the event with delay_sprites set to true (third arg iirc) it'll animate correctly
okie thx i'll try that
couldnt you set trigger = 'before' or am i misunderstanding how that works?
yooooo ty
a copy of that is also on the wiki https://github.com/Steamopollys/Steamodded/wiki/Guide-‐-Event-Manager
can judgement tarot create eternal jokers?
How do I translate my mods (make it so the description changes depending on the language)?
Thanks!
Hello everyone. I've never coded before, but I'm having a lot of fun on Balatro lately and I wanted to try and make a Joker myself. I followed a tutorial read the examples in steamodded (thanks to the person who suggested that earlier to someone) and now it's working, but it's not doing what I want it to do. I know what probably needs to be changed, but I have no clue on how to do so.
anyone has a good tutorial on how to start modding balatro?
My Joker should add a card to your deck each time you select a blind. Then when you discard that card, it should destry it and gain x0.1 mult. Right now it creates a joker when you select a blind and adds x0.1 mult when you play a straight
What's the if to identify non-scoring cards?
well its making a joker cause of this line
wait
actually just try local new_card = create_playing_card() maybe
im pretty stumped on this
how do you make a joker give a booster pack ore cards and choices?
a specific booster pack
i swear why is SMODS wiki always missing specifically the stuff i want to see
what do you need?
you mean more*?
you'll probably need some sort of hook or lovely patch
stuff like actually seeing an SMODS.Joker page (which seemingly isnt there fsr)
cryptid mentioned
SMODS.Center
SMODS.Center
it contains joker in there
which Jokers are a subclass of, so it's contained
you could lua inject into game.lua to replace values listed here
(which tbf should probably somehow indicate it contains SMODS.Joker etc)
ah ok thx
might need to be reorganized into actual subpages
not sure how to do it with smods
oh no its a pack from my mod
honestly probably would work better yeah
i wonder why SMODS.Joker never even mentions calculate
if you just want to edit the base values i feel like that should be easy? making a joker to change it mid-run would be harder though
it does
tbf this is poorly organized
ah here ok thx
it really is 😭
a 4 yr old could organize it better
lmao alright
bet
LOL
It's creating a card, but it's not adding it to the deck
are you still calling add_to_deck()?
yep
add_to_deck(new_card)?
okay wtf.. i'm just looking at this and it seems like the amount of choices comes from the center table while the amount of cards come's from the booster card's ability
no it should be new_card:add_to_deck()
oh ok
its a function of card
that won't magically place the card in your deck, it just calls on-add effects
maybe try SMODS:add_card(new_card)
lol no
you just need to give create_playing_card an area to emplace to
it's the second argument
local new_card = create_playing_card(nil, G.hand)
G.GAME.blind:debuff_card(new_card)
G.hand:sort()
i think he wants G.deck? but yeah
i took that from certificate, adapt as needed
try the Steamodded wiki and/or some of Steamodded example mods
What's a good function to hook at the start of a run?
Ok, it has no animation for some reason but it's working, thanks
chat, how would one try to make an observatory-like joker
Maybe Back:apply_to_run ?
it seems context.other_joker does not work with planet cards
or im trippin
i mjean it has joker in the name so
yeah and context.joker_main works with planets too
istg if i have to lovely patch
😭
where can I find some example mods?
I realized that maybe Game:init_game_object works for what I want
Since it also needs to save per run
In Steamodded
inside of steamodded
if you have it installed just look in %AppData%\Balatro\Mods\Steamodded or smth similar (%AppData% has special meaning)
inside of steamodded theres a folder with the name smth about example mods
how can i make smods.eval_this work with blueprint
when i blueprint a card with it it just does the text on the original card
context.blueprint_card or card
new joker has been created
progress is going swimmingly
flower boy joker goes crazy
lol
perhaps looping G.consumeables.cards
it's gonna all be jokers based off of albums
keep the weezer one unchanged
im planning on it
hell yea
weezer
TYLER THE JOKER
we need goblin joker
thats so good
IS THAT WEEZER
yes
i didn't even know you could do that
This helped me debug why the mult tag was black instead of white, thank you
you can do that?
i mean, thats what like, square joker and half and photograph do
they why, when they're flipped, they retain their size
i didnt even know you could
idk if smods has functionality for that but you could prob lua inject it
anybody know why im getting this everytime i go play a hand?
i just recently modded this game for the first time so i dont have much mods installed yet and when i went to test it out i get this
weird that it didnt show what mods are installed, it normally has an extra context part of the crash log
at first it was for mikas mod collection but i uninstalled it and still get this
do you have talisman and divvy's history
-# if you do, disable Talisman
i dont have any mod installed, i just installed the steam mod injector for the game to get it setup for mods and whenever i tested a playthrough i just get that
you installed SMODS and lovely right
did you install lovely\
bc SMODS needs lovely to function
"If you previously installed Steamodded without Lovely, you must first remove that installation by verifying your game files on Steam: Library > Balatro > Properties > Installed Files > Verify integrity of game files."
ok ill do that
then you install lovely FIRST before steamodded
heres the link https://github.com/Steamopollys/Steamodded/wiki
thats the guide to installing steamodded, itll tell every step
I lowkey forgot how to add a seal 😭
btw how do i use remove_from_deck in jokers? i cant find it on the SMODS wiki
its either not there or just another one of those stupid organization problems
OH I FOUND IT SRY
NVM
local prime = {1,2,3,5,7}
print(context.other_card.rank, prime[context.other_card.rank])
if prime[context.other_card.rank] then
how do i get the cards rank? this is just returning rank=1 and so prime=true for everything
ok so the problem i was facing was i did not put the steamodded main folder in the mods folder
now its working
nice
its .value to get the rank
i just tried that actually and it was returning nil
btw do i define remove_from_deck in calculate? like
function remove_from_deck(self, card, from_debuff)
-- insert the code i was gonna do
end```?
isnt start_dissolve enough to delete jokers?
oh no im trying to do something when the joker is removed
oh ok
according to people (and the wiki) thats the purpose of remove_from_deck
odd
gotta say, the entire enviroment is pretty confusing. i am struggling. remove_from_deck sounds like the action, instead its the trigger
first i learnt that 'start_disolve' is the method to remove
ikr
and the wiki is organized in a very confusing way
like shouldnt the center methods according to specific centers be included IN THAT CENTER'S SECTION?
the docs say what elements are needed but dont explain what they are or do
like imma bout to rewrite the wiki just so i can read the thing /j
best way to learn is by inspecting other people's mods imo
mood
how would I make a joker trigger when a hand is played but before it's scored like midas mask?
context.before and context.scoring_hand
k
ikr
and if they do its very vague explanations that dont clarify a lot
ya
they dont want us to mod balatro 💀
it would benefit from showing usage examples
yea
also be nice to have page for object outlining all fields and methods
eg>
Playing Card
fields:
.rank
explanation
.suit
blablabla
also also
the whole config, return values stuff is bewieldering. why do we need multiple alternately named references to a single constant that we cant directly use?
Lmao
No problem boss
Hay, I am newer to modding and I was wondering if I could get some help with something. I want my joker to play a sound effect when triggered. If someone could push me in the right direction that would be great

