#💻・modding-dev
1 messages · Page 477 of 1
that seems like a balanced nonshowdown crimson heart, yeah
right there with ya
maybe change it to "must submit" instead of just "submit"
aside from UI this should be the last thing I need to get the mechanic working tho
The only reason I left it as just "submit" is because it allows you to play if you don't have any jokers
Technically you can also sell all your jokers and it'll let you play, since it can't gate you if you have no jokers to submit
When do i put my config vars in extra?
I try to do it all the time, but it doesn't really matter where at the end of the day
You have returned a non-nil value in context.repetition
You need a context check.
also it keeps upgrading when played, its not supposed to
but... i have 4 😭
or do you mean for the return
Yes.
Essentially, you're returning an empty table, which is not nil
ooh right
because context.repetition is added to the context
you might want to add and not context.repetition
tomorrow i will check if add_to_deck functions work for consumables
also realised i would end up skipping the second if with my change, hopefully this will work?
honestly, I'd probably get rid of the ret variable altogether, there's no reason why both if statements need to share it.
true
if context.final_scoring_step and context.cardarea == G.play then
card.ability yada yada
return { message = "Upgrade!", colour = HEX("A681FF") }
end
ye ye, ik
now i need to figure out why it's upgrading when being played (its only supposed to do that in hand)
unless these changes fixed it
yw
poker hands with enhancements can be amusing to code
I have some cool combo and we'll balanced ideas for jokers and spectral cards. If some Wana add them to there mod then I can share these ideas (don't need any credits or something). Just let me play these ideas once they finished.
Another cool blind
usually dont post too much about the art of my mod here bc im in more of an art focused community than a coding one so it goes there instead but
im really happy with how this deck turned out it was really intimidating
I have some cool combo and we'll balanced ideas for jokers and spectral cards. If some Wana add them to there mod then I can share these ideas (don't need any credits or something). Just let me play these ideas once they finished.
@vast bough very few options to modify game variables like “joker slots”
oh does {T:classprefix_modprefix_key} not work with seals?
Does context.full_hand include debuffed card?
Do I need if ... and not v.debuffed then under for _,v in ipairs(context.full_hand) do?
yes
my love for vanilla would never allow me to
fair tbh
Does anybody know how to get Vouchers to show up properly in loc_vars' info_queue?
Here's my current code. Note that add_loc_vars is a method I wrote that adds onto loc_vars, injecting the table it returns into { vars = ... }
I have been able to get Tarots to work properly like so: table.insert(info_queue, G.P_CENTERS['c_star']), I just don't know what to do for Vouchers.
retextured wild card
did you try the same for vouchers?
Oh wow. That actually worked. I seriously wasn't anticipating that, because I thought vouchers were a wholly separate class
What about blinds though? There's a nasty one: THE WHEEL, which crashes because it doesn't have access to vars.

Oh.
It also works the same.
Wow.
G.P_CENTERS saved my ass.
When i assert it game crashes and says:assertion failed!
Assert what?
assert this func
Yes, HAce isn't a valid rank.
Yes, it would be modprefix_HAce
lemme try it
that would be G.GAME.round_resets.ante
thanks it works
hello gng, this is my first time coding game files and making mods, how do I make a file for my mod that I can share with other people
check the pinned post in #⚙・modding-general
Aright thx
uhh how can i make the description text update live to the current mult
you need a main_end with a text node using ref_table and ref_value
i just realized i wrote that in the most obtuse way
but im on my phone so its the best i can do to explain :3
Wait, no, nevermind, I was wrong. G.P_CENTERS causes the blind info to disappear. Still in need of help, thanks!
blinds are not supported because blinds are not located in P_CENTERS
they're in their own block
Ok, so either I have to brute force make infoboxes for blinds or avoid The Wheel at all costs?
does P_BLINDS not work?
also i think wheel is hardcoded to 1 in 7
so you can just put that in
P_BLINDS definitely does not work. It returns empty infoboxes that say ERROR
bump
current score as in chips earned this blind so far excluding what the current hand will earn?
chips earned this blind so far
okii
yes G.GAME.chips
whats the llm policy for balatro code?
i want to convert the translation code to rust for my project and was thinking of speeding it up by just letting an llm do the conversion (its pretty good for doing quickndirty language conversions). is that okay? i can also just run an open-source llm locally to do this so the code isn't sent anywhere
I don't think there's one stated but I would keep it local if you're sending it game code
don't think I've come across this error before
o
(in the return is fine)
Do I just use . instead of : for both
Game:start_run = function might not work with the :
it would need to be function Game:start_run i think
o
you can also have . and add self back
okii
hey all, i'm looking to make a mod that makes cards like Rebate, Ancient, Castle ect have a legendary-style overlay to show what is currenlty being buffed, I have had little success so far with my limited knowledge of programming in general and mostly using chatgpt to help me out. So far I have had success in adding the soul overlay to a joker but am not able to get it to update at all, any suggestions for where to go from here?
Suddenly everything that was working just fine before is now breaking 
GAME doesnt exist on loading files
and hud might not exist wherever youre calling the function
O
It worked yesterday 
tho now it just crashes whenever i try to set that value
does anyone know a way to add a copied card directly into the scoring hand? for instance, if DNA copied a card during the before scoring step, instead of being added to the players held hand, it would be added directly into the scoring hand?
i've been able to get the soul_pos overlay working, it just doesnt ever update to match the rebate buffed rank
you can add a card to G.play but I think you would need to patch stuff into the calculation pipeline to make it score
iirc i think talisman checks the playing hand multiple times
i might be wrong but my understanding is that the soul_pos overlay is a shader and so should be able to be updated dynamically
it's not, it's a sprite
i see, would what i'm trying to achieve be easier with shaders? is that even possible?
I'll give that a shot
thanks :)
nah, I think changing the sprite is probably easier, I just don't have what the syntax would be rn
some thing like card.children.soul_sprite:set_sprite_pos()
amazing thanks, will give that a try
im pretty sure card.children.soul_sprite doesnt exist tho i dont remember what the name was exactly
yeah, this worked but like you said it doesn't actually score. I do have talisman installed as well, I don't think it's re-checking the played hand.
I'll try and figure smth out, thanks again :)
also make sure you're adding it immediately and not in an event
or it will just add it visually
wb the copy_card:start_materialize() event?
that ones fine probably
is there a context/way to check if cards are drawn specifically after a hand has been played?
context.hand_drawn
you might need to add G.GAME.current_round.hands_played ~= 0
all of a sudden my lovely window is just showing INFO - [G] nil nil endlessly, have i accidentally enabled something?
i'd like it to not happen after discards
did you add a print anywhere?
yeah i added a couple of debug prints to try and figure out if the joker is updating at all
ohh then idk
probably a flag on context.pre_discard might work
yeah it was that debug print that was doing it after all, how silly
HUD would be a nil value here...?
yes, the hud is made when the function returns
I have some cool combo and we'll balanced ideas for jokers and spectral cards. If some Wana add them to there mod then I can share these ideas (don't need any credits or something). Just let me play these ideas once they finished.
oki
Lemme try
I don't remember what I was doing before everything just started not working for no reason despite not touching it
Do you guys know how to make the joker wiggle when it gets trigger?
thats UI
most returns in calculate do it automatically
but card:juice_up()
help. balatro is for some reason not loading SMODS.Language
is mail in rebate referred to as j_mail or mail_card? how would i find this out for sure?
mayb?
en-us?
whats the normal values for the scale and rot amount though?
leaving them empty
either look in game.lua, the localization file or here https://github.com/nh6574/VanillaRemade/blob/main/src/jokers.lua
(its j_mail)
dunno then
what about juicing up for cards like walkie talkie?
the one that wiggle every time a certain card is played
if you use calculate correctly it should do it for you
is there a context for when any Joker's add_to_deck or remove_from_deck is called?
No way salty ghost pfp updates comes more often that I do my mods updates
context.card_added for the first
i dont think so for the second, you would need to check being sold/destroyed individually
Without context... that sounds wild. 😂
what's the context for a Joker being destroyed?
In the next SMODS release, context.joker_type_destroyed iirc
also, is there a way of detecting if a Joker gains an edition?
rightright
mm, this is. too open-ended for my liking ;u; i'll omit it and come back to it
(deck ability: +1 Joker Slot per Holographic or Polychrome Joker)
hooking set edition
gotchagotcha
yeah anything that requires modifying any slots or values dynamically at all times is a pain
i got the blueprint mod and it makes blueprint and brainstorm dynamically change sprite based on which joker they're copying, how is it achieving that so smoothly? I cannot for the life of me figure out what i'm doing wrong
Managed to get pretty much everything working except this and some of the weird UI stuff Im not sure how to word
would this not be how it would work
(ignore ALLOY.health on line 53 it's supposed to be G.GAME.health i grabbed the wrong screenshot)
i mean if it doesnt work then probably not lol
i never tried returning anything in a calculate_context hook you might need a dummy object
In the definition it seems to return a table of something
Somewhere I guess
You mean a dummy object like I do like
local obj = calculate_context(self, context, return_table)
return obj
Or smth?
no i mean making a hidden joker
sometimes i returns it and sometimes it adds it to return_table i think im not sure how it works
the return is not the same as a joker tho
I thought this was gonna be a pretty simple mechanic when I started trying to make it 
In my mind it's just
You start with 100 HP
If you lose a blind, subtract the percentage of difference between your blind score and the required score from your health
If your health reaches 0 or below, you lose
Tho i guess it does involve basically rewriting the entirety of the lose mechanic so it's not really that simple
i will be adding hp to my mod someday too :3
:3
Theoretically how would I make that hidden joker in the meantime
Just to make it go by easier
am i doing calculate wrong? why my jokers aint juicing up
even if i put it in it only does once
making a cardarea that has that joker and adding it to the calculation pipeline
i would ask Ice who was talking about doing that recently, I've never really done it
what if you remove the card = line? also what does it do in general

So I don't know why this is happening but my badge color is blue
I didn't even define a color yet (because idk where that would even be)
yoooooo now it works
ty so much
finally
@hushed field please give me your wisdom 🙏
Hmmmmmmmm I'm trying to decide what to do art-wise for an equivalent blind that prevents cards from scoring their base chips without debuffing them. Because unlike the no-suit blind, I can't just obscure the number or all indication of the number of the rank, since that's used for hand type detection
there's some particularities with it that are kinda wonky, or I'm forgetting a step, but I'm currently literally just setting up a card area off screen and putting an endless joker called 'handler' in there, haha
the handler joker itself is literally just a joker. I've just made sure it's not retriggerable or blueprintable, just to be sure, and that it's not in_pool and not in the collection
hmm
my code for the cardarea is this. I don't do anything besides setting this up in a hook of Game:start_run
Oh
That actually doesn't seem too bad
How would one make the joker be not in the collection
no_doe?
that's to make sure cryptid doesn't mess this up
no clue why they don't just use no_collection for that, but that might be due to age, or something
does SMODS Center:extend have a badge color function?
It doesn't specifically do badge color, but it has a function for setting the badge of the card type
And then there's a further set_badges function to add additional badges
i dunno what part of the code did this but i just want it off this blinding blue
OH MY GOD MY JOKER DOES SOMETHING UNINTENDED BUT ITS SO FUNNY SO IM KEEPING IT IN
IF YOU HAVE 2 OF IT, IT JUST CLOSES YOUR GAME
IT DOESNT EVEN CRASH
IT JUST FUCKING CLOSES 😭
sounds like a stack overflow
Is this your mod badge?
added a warning 🔥
The first version of my mod is complete, any information on how to get it on the balatro mod manager?
Then what it is?
It's a badge similar to a consumable's
A rarity?
no
Oh so it's a type badge
yes
it should be, Mathguy let me use their contracts mod as a baseline to make this but idk what he did to get it looking like that (and when I asked, they have no idea either)
You set the color of consumable types when you declare them using SMODS.ConsumableType
They have a primary_colour and secondary_colour property and I believe those are used for the badges
Just confirming but it's supposed to look like this right? It doesn't seem to trigger the joker for some reason (tho the joker works fine if I summon it in like G.jokers or smth)
(Sorry for pinging and pestering u i dont kno who else to ask :<)
Submit it to the mod index
i'm not using smods.consumable type though
Since it's not a consumable
Oh then I can't help you. You'd probably be better suited asking the original author to help you look
how do I make it so a joker only retriggers these 4 specific jokers
how do you see what the current ante is?
G.GAME.round_resets.ante iirc
You want to remove the badge entierly? Also what kind of object is it
Is there a way to make add_caed only give cards which have been unlocked? Because I am trying to make a deck that gives you a random legendary joker out of the ones you have discovered
i dont think so, you would need to filter them yourself
Ok thank you
Hi N
hewwo
How are you my friend
Eh
I haven't been sleeping well lately :(
damn..
Its okay though...I will find a way to explode soon and then I will sleepy weepy
lets find it together
Thats so romantic
is there a way to make a joker modify the size of a blind directly? like not just multiply it like add a specific value to the blind size
🤑
G.GAME.blind.chips = G.GAME.blind.chips + value
G.GAME.blind.chip_text = number_format(G.GAME.blind.chips)
can i set a custom message for context.debuff_hand for when you have a hand selected
for a joker, not a blind
local possible_jokers = {"j_rose_placeholderrose", "j_rose_placeholderrose2"} -- add more keys as needed
local random_key = possible_jokers[math.random(#possible_jokers)]
SMODS.add_card({key = random_key})
this code is supposed to create a random joker from the list, but it only makes the j_rose_placeholderrose
is this a thing in CardArea i would need to modify so that the joker triggers when held there
you need to patch it into the smods calculation
pseudorandom_element should be used here I think
thanks 
psuedorandom should replace math.random?
return debuff_text
local possible_jokers = {"j_rose_placeholderrose", "j_rose_placeholderrose2"} -- add more keys as needed
local random_key = pseudorandom_element(possible_jokers, "seed")
SMODS.add_card({key = random_key})
that worked, thank you
is there a way to change the sell value of a card?
change card.sell_cost BUT if :set_cost is called on the card it will reset
if you dont want that either use card.ability.extra_value or hook :set_cost
alrighty thanks
The HP mechanic finally workssss
Now I just have to solve the janky UI appearance

I don't suppose it would work to have there be a child node of a text node
is this about the text centering thing?
well for this
Essentially two things
The first is that the "20" should be in the center
and the second is that the width of the red thing should scale with the HP to fill the bar
you could try adding offset = { x = number, y = number } to the text but idk if thats the best solution
theoretically I could do some left alignment if it was a child of the text node and that would be fine
true
It would be half of the max length minus the current length i think
maybe
how can i put a random edition on the last card triggered
i guess it uses a different system
what i'm gonna ask might be way too much but is there a way to implement a new font?
oh hell yeah
(documentation pending)
that's really cool
the invention of SMODS might be the third most important thing in the universe after fire and balatro
this is how i do it https://github.com/nh6574/JoyousSpring/blob/c0a24f9ba7e75f51d8ec09f22f12329c7a837cca/src/card_ui.lua#L3
then i use {f:joy_font}
soon™
and the font files go in assets/fonts?
yes they do
alright thanks a lot 🙏
...tried to add a new rarity and
it no work :(, game crashes when i hover over the joker i gave the rarity to
what if you add
pools = {
["Joker"] = true
}
still crashes
same error as last time i think
colors shouldn't be strings
if you wanna use a hex code wrap it around HEX()
do you guys think this will work
ill take it here we fuckign go
wait
push first in case something goes wrong
ok now
why are you there stop that
buffoon didnt crash
standard im begging you
WHAT MORE
😭
something about pools??
i dont even have the guy that fucks with them how
also hi astra
you wanna throw my cornflakes into oncoming traffic while youre at it
Fish food for the cars
They are close enough
true
Cars would eat oversized fish flakes (aka corn flakes)

I said that with purpose goddammit
goodness
alright fair
as for a modding question
astra have you
added a button to a card before
Kind of but also not really
how kind of is kind of
For Horoscope cards I changed their pack buttons to Select instead of Use, but now there’s API for doing that and I forgort how I did it in the first place 
just delete everything and copy how i did it :3
do u mean u dont read the joyousspring code every day
im busy reading the hyperfixation code every minute
no
do you have any idea why it does that at all
oh god
is there a way to change the loc_txt of a joker in the add_to_deck function?
do you take ownership of them
not really, but you can change the description using a key to a localization key in loc_vars
only by kind
did you disable the badge there
right, kinda forgot about that 😭
did not know that was a thing so no
is it the same var
wait what are you doing to it now
i think you add , true at the end
trying to get it to stop crashing packs
also hi
oh youve gotta be kidding me
i did that with the other ones too am i just stupid
no youre very intelligent
Hi!!!!!!!!!!!! 
trying to make it so the button only tries to ui itself when the card is a joker in the joker area that you own and is not ijiraq and is also rarity 4
_ _
Hmm okay yeah use_and_sell_buttons has an early return for pack cards
currently setting up the n method which works because it's n
though honestly I think you should just change the card.area.config.type == 'joker' to card.area == G.jokers because the G.pack_cards area can be 'joker' type but G.jokers is the only area you really want it to be valid in
i would just try the other one if you were already doing it
i would love a button API
couldve sworn there was a conversation about just that
i would use it if it makes buttons work with a controller
i cant figure that out
or anything to do with playing with a controller
Controller thing kinda complicated
tl:dr you can't have option cycles in a row at all, because in this case they're basically unusable on controller
my mod is not playable with a controller because the summoning overlay just doesn't work
and cards that have multiple buttons dont work either
I’ll try this and if it doesn’t work I’ll try n’s
good thing it’s a laptop and not a pc because if something happened to my code 
Tat's why when controller is used I should adjust menu to looks like this. Looks not great but at least usable
have any of you experienced errors like this: #1209564621644505158 message ?
with what you see or with-- the power just went out
oh power's back lovely
no lovely's the code injector
oh right
i think ive seen other people with the same one before with cryptid
i would try checking on the cryptid server
Even now on latest steamodded present an issue with deck spawning on top part of screen first
Getting a strange error ever since implementing that new cardarea
happens when I hit new game like 50% of the time
do you have what that smods line is
is this the lovely dump
giggle
yeah i think it does something weird when starting/ending a run with extra cardareas
gotcha
I've been looking around and haven't seen much
weird
also do you guys have any serious wants for this lovely debugger thing I'm working on?
eg. things that really suck about working with patches that could be improved by tooling
i read about it on the lovely discord but im stupid so idk what it would be for :3
basically a debug ui. it would hook up to lovely running in the game and allow you to step through patch application with a before / after diff
and some other general dev tools
oh
I mean I'm hooking it anyway
thank uuu :3
oh that sounds cool
I'm starting to grow less bothered by the off-center text for the health thing
But changing the width is a must
is there a good way to change the width of a UI node dynamically
nothing I've tried has done much
(tho I think once that's done I'll release the mod and then do anything else after)
oh bepis did a progress bar
you can ask him
👀
it's a PR on smods too
@manic rune meowwww
i ask for thine wisdom 🙏
honestly if this gets merged some day i might do a mechanic with it in my mod
Yea
alright everything’s still up after this long it should be safe for me to do stuff again
js asking, would anybody be able to teach me how to mod balatro sometime? js to add some simple jokers and editions and stuff
Oh snap I didn’t realise the progress bar was a smods pr
I have completely missed that 🥲
poor bepis
i think i messed something up lemme recheck my code
ah i forgot to divide by 100
:3
i LOVE typos
abiliy
yo thx
that's a new one
Actually in hindsight i wonder if I literally just needed to activate that one boolean
Instead of writing 60 lines of code
why is it still scoring after the cards were destroyed?
what would i need to do to avoid that?
also wth
Use context.destroy_card
right
did this
mod badge is now gone
works fine on:
Buffoon
Celestial
Arcana
ipairs crash on Standard Pack
What does the crash log point to?
sorry i was handling a matter uhhhhhhh
like the line? or
Yeah that crash points to a vanilla file
oh ik i just wanted to make sure you meaent the line
ill grab
(ive seen this crash before unfortunately)
Well Rarities are pools so it probably has smth to do with that
Nothing in this code speaks out to what casued the error. Further down in the crash log might tell you what's doing it
What values am I supposed to return for context.check_enhancement?
{m_modprefix_key = true}
And if it's a vanilla enhancement, would it just be something like {m_gold = true}?
well it looks like something with create_card in utils
Yes.
Alright, then something else must be the problem
Is the game hard crashing or is it just not doing anything?
It's not doing anything
Code?
Hold on a second
crashes right when the cards would show up
wait i have ram now i can just show you
I have reason to believe you've misspelled the rarity or forgot to put your mod prefix ahead of it
calculate = function(self, card, context)
if context.check_enhancement then
if context.other_card.config.center.key == "m_gold" then
return {
m_steel = true
}
elseif context.other_card.config.center.key == "m_steel" then
return {
m_gold = true
}
end
end
end
Do you have quantum enhancements enabled?
Oh, you have to enable them? How do I do that?
SMODS.current_mod.optional_features = function()
return {
quantum_enhancements = true
}
end
Im still missing context. Did you want to change stuff about playing cards?
it shouldnt even be messing with the boosters
and you're absolutely certain this is related to what you just did rather than a problem that could've existed for some time before?
Thank you :)
ive only done 2 things with standard packs
-
a function i made to mess with weights of packs, this instance only applying within a joker's add_to_deck
-
an ownership of them that should only apply while in possession of a different joker
'Standard' is not a valid set/pool key for playing cards
It's 'Base' or just 'Playing Card' to randomly choose between base or enhanced
also I would recommend making the append key for the default behavior 'sta' because that's the vanilla key and it would prevent compatibility breaks
each is different yeah
went off the vremade voucher cause it used the 1 2 thing
did not put together that vremade is vremade
Typically if there's some kind of alternate behavior vanilla keys them differently except for Telescope celestial packs which uses 'pl1' just like the regular behavior
👋
Hi dilly
i see smart people in chat
hi dilly
how is everyone
drawing cards
coding buttons
draw me next and put me in your mod
button me next and put me in your mod
also hi smt i hope you are well
id rather die and it is not your fault
D:
where can i even see the vanilla append keys
either in the SMODS game_object.lua file since all packs have been taken ownership of, or in vanilla Card:open()
oh youve gotta be kidding me
I want to replace the " self.ability.set == "Enhanced" " part to a certain suit, how do I do that
What is the goal?
To have spades not be debuffed
@modern kindle check out my no suits atlas
I don't know code lmao
This shit looks clean as hell
Then why are you patching? Because SMODS has a function for this.
thanks for the free atlas pal
(looks awesome)
What's the function
I was looking at other mods codes (Extra Credit) and saw how they made certain cards not debuffed
SMODS.current_mod.set_debuff
Welp
In your case it would be something like: ```lua
SMODS.current_mod.set_debuff = function(card)
if next(SMODS.find_card("j_modprefix_key")) and card.playing_card and card:is_suit("Spades") then
return "prevent_debuff"
end
end
Wellpppppp
which do standard packs normally use (guessing the latter)
No, they use create_card((pseudorandom(pseudoseed('stdset'..G.GAME.round_resets.ante)) > 0.6) and "Enhanced" or "Base", G.pack_cards, nil, nil, nil, true, nil, 'sta')
Standard packs select their set before returning the card table yeah
I would recommend if you're taking ownership to use the same code just in case
i didnt know i wasnt until now
I do not recommend using vanillaremade as a basis for take ownership
it changes a lot of stuff to make it simpler and also i make mistakes :3
n would never make mistakes
setting the created card's append to ar3 instead of ar2 in case of omen globe
Wtf N makes mistakes? No.....
Yay this works
Thanks my goat
Idk where to find these functions so
every time i have helped anybody here i made one mistake, eventually the combination of all mistakes will create a computer virus that installs joyousspring
Some of them are here: https://github.com/Steamodded/smods/wiki/Mod-functions, but most of them aren't.
Oh yea? Well I've turned the VanillaRemade link into an affiliate link for my own benefits 😈
Holy shit
I should actually read things
How do I make my Joker's description have an info card like this?
In your loc_vars function you add to your info_queue
info_queue[#info_queue+1] = G.P_CENTERS.m_steel
Aha, thanks!
My very duct taped wrapped joker
I wonder if it would look better with multiboxes
True
In my very biased opinion it absolutely would
Ofc the multibox porter would agree
Here's the code cause yes ```lua
SMODS.current_mod.set_debuff = function(card)
if next(SMODS.find_card("j_inc_incognito_joker")) and card.playing_card and card:is_suit("Spades") then
return "prevent_debuff"
end
end
SMODS.Joker{ -- Incognito
name = "Incognito",
key = "incognito_joker",
blueprint_compat = true,
eternal_compat = true,
unlocked = true,
discovered = true,
atlas = 'incognitojokers',
rarity = 4,
cost = 20,
pos = {x = 0, y = 0},
soul_pos = {x = 1, y = 0},
config = { extra = { xmult = 1, odds = 7 } },
loc_vars = function(self, info_queue, card)
return { vars = { card.ability.extra.xmult, (G.GAME and G.GAME.probabilities.normal or 1), card.ability.extra.odds } }
end,
calculate = function(self, card, context)
if context.destroy_card and context.destroy_card.should_destroy and not context.blueprint then
return { remove = true }
end
if context.individual and context.cardarea == G.hand and not context.end_of_round and not context.blueprint and
pseudorandom('j_inc_incognito_joker') < G.GAME.probabilities.normal / card.ability.extra.odds then
if not (context.other_card:is_suit("Spades")) then
context.other_card.should_destroy = true
card.ability.extra.xmult = (card.ability.extra.xmult) + 0.5
return { message = "YUM MULT!", colour = G.C.BLACK }
end
end
if context.individual and context.cardarea == G.hand and not context.end_of_round then
if context.other_card:is_suit("Spades") then
card_eval_status_text(context.blueprint_card or card, 'extra', nil, nil, nil, {message = "71!", colour = G.C.BLACK})
return { xmult = card.ability.extra.xmult }
end
end
end
}
Very duct taped
Idk how to do this tho
I assume it's a localization thing cause I did that
Basically you put your text in multiple table, each table is a box
your_joker = {
name = "joker",
text = {{"box1"},{"box2"}}
(You can ofc multiline in each box)
pain
oh my god i have to do that three more times
Why not use a lovely patch?
i'm stubborn
unrelated note why does this keep going yellow
well i know WHY cause it tells you (redundant parameter)
but i cant find WHERE and every time i think ive solved it i come back later to it yellow again
Took awhile but my goat 🙏
"cant you hook the SMODS.four_f-" was i just supposed to know there was a four_fingers function /lh
Nice
true, I don't think it's documented, but it's this one
are we fr
there is one for showman, four fingers, shortcut and "wrap_around_straight"
which is always false apparently
hhhhhhhhhhhhhhhh
Prob to allow for a center object to make it true
thank you srock 
np tomatose
i update these credits daily at this point curse you 4 am coding
can i just set this up in overrides like this and itll hook
example
no, you'll be overriding it completely like that
removing the functionality of the four fingers joker for example
if that's what you want sure
local variable thing it is
better?
unless i need a param? i dont see one
Replace the 5 with the bcofcthereis call
hi eremel
do i not need 5 returned at all then
Well the original function will return the 5 (or 4 if you have four fingers)
If you don’t return that result you’re ignoring four fingers
i seee
I have no idea where they’d fit on the wiki though
wait how the heck would the others format
cause showman and shortcut returning numbers doesnt sound right
normally I’d just look but I didn’t even know they existed until a few minutes ago
plus they don’t seem return a search result in the dump? Function formatting wise at least, cause I see the showman one get used a few times
Niche Functions tab maybe?
though I don’t know if there’s enough to warrant their own tab
i feel like if theres something that doesnt warrant its own tab it can just go in an 'other' tab with other things that are in a similar vein
I mean yeah thats obvious enough
I guess mine would be if they want their own tab on the wiki rather than a conglomerate of stuff that doesn’t fit
….which in turn would also have a fit in the wiki
I guess it just comes down to quantity
Yeah but I don’t want the other tab to just turn into a list of all the functions because lots and lots of them don’t really fit anywhere
They might end up in calculation maybe
Junk Drawer tab /j
the dump only includs stuff that was lovely patched, they're in Mods/smods/src/utils.lua near the bottom
to answer your question, the others return booleans, four fingers is the only one that returns a number
i do think the utility tab needs some more categories or something
does anyone know of an existing mod that dynamically updates a joker's sprite based on some value changing during the game? can't figure out how to get my mod to change anything mid-game
i recommend looking at core switch or cassette block from Celeste Card Collection
amazing thanks!
i have a weird issue with this joker, where if you sell it it works as intended (sort of? the next cards in the shop appear a bit closer together but aside from that it functionally works fine and it fixes itself on leaving the shop) but if you reroll it keeps the extra shop slots for one extra reroll. does anyone have any experience with working on changing the shop dynamically like this?
does anyone know why my game crashes on startup?
Yes.
👂
What does your SMODS.four_fingers hook look like?
Remove the first callings of the functions and move the () to the functions in the returns.
my joker seems to be crashing when it activates
SMODS.Joker {
key = "s_puppet",
atlas = 'Joker',
pos = { x = 4, y = 3 },
blueprint_compat = false,
rarity = 3,
cost = 6,
config = { extra = { seal = 'fnaf_guard' } },
loc_vars = function(self, info_queue, card)
info_queue[#info_queue + 1] = G.P_SEALS[card.ability.extra.seal]
info_queue[#info_queue + 1] = G.P_CENTERS.m_fnaf_kid
end,
calculate = function(self, card, context)
if context.individual and context.cardarea == G.hand and context.end_of_round then
if SMODS.has_enhancement("m_fnaf_kid") then
if context.other_card.debuff then
return {
message = localize('k_debuffed'),
colour = G.C.RED
}
else
conv_card:set_seal(card.ability.extra.seal, nil, true)
return true
end
end
end
end,
}```
Yes, conv_card doesn't exist.
I have some cool combo and we'll balanced ideas for jokers and spectral cards. If some Wana add them to there mod then I can share these ideas (don't need any credits or something). Just let me play these ideas once they finished.
which one should be them?
also this joker adds a custom seal to a custom enhanced card when its held in hand at the end of the round
context.other_card
Also it would be SMODS.has_enhancement(context.other_card, "m_fnaf_kid")
why are non-jolly/m jokers not debuffed in this boss blind?
...
recalc_debuff = function(self, card, from_blind)
if (card.area == G.jokers) and not G.GAME.blind.disabled and (card:is_jolly() or (Cryptid.safe_get(card.config.center, "pools", "M"))) then -- since this is a cryptid addon we'll use cryptids function for this
return false
end
if (card.area == G.jokers) and not card.key == "j_chicot" and not card.key == "j_crp_jean_antoine" then
return true
end
return false
end,
...
im doing stuff with deckskins right now, if im using pos_style with a table how can i get it to work with numbered ranks? it works fine if i use ranks which are words but not numbers. like Jack = { atlas = skin_lc, pos = {x = 10, y = 0} } works but 2 = { atlas = skin_lc, pos = {x = 10, y = 0} } doesnt
It would be and (card.config.center.key ~= "j_chicot" and card.config.center.key ~= "j_crp_jean_antoine")
so just like
...
recalc_debuff = function(self, card, from_blind)
if ((card.area == G.jokers)
and not G.GAME.blind.disabled
and (card:is_jolly() or (Cryptid.safe_get(card.config.center, "pools", "M"))))
and (card.config.center.key ~= "j_chicot" and card.config.center.key ~= "j_crp_jean_antoine") then -- since this is a cryptid addon we'll use cryptids function for this
return false
end
return false
end,
...
Yes.
non-jolly jokers are still fine, it appears
this is the full code
SMODS.Blind {
key = "monochrome_m",
name = "Monochrome M",
pos = { x = 0, y = 8 },
boss = { min = 2, max = 10, showdown = true },
atlas = "blind",
mult = 0.13,
recalc_debuff = function(self, card, from_blind)
if ((card.area == G.jokers)
and not G.GAME.blind.disabled
and (card:is_jolly() or (Cryptid.safe_get(card.config.center, "pools", "M"))))
and (card.config.center.key ~= "j_chicot" and card.config.center.key ~= "j_crp_jean_antoine") then -- since this is a cryptid addon we'll use cryptids function for this
return false
end
return false
end,
debuff_hand = function(self, cards, hand, handname, check)
if not (handname == "Pair") and not G.GAME.blind.disabled then
G.GAME.blind.triggered = true
return true
end
return false
end,
get_loc_debuff_text = function(self) -- we do a little cryptid stealing
return localize("bl_crp_debuff_monochrome_m")
end,
boss_colour = HEX("4f6367"), -- balatro black (*monochrome* m)
crp_credits = {
idea = { "Unknown" },
code = { "ScarredOut" }
}
}
Have you tried using context.debuff_card instead?
is there a way to make boss blinds not appear naturally?
Yes.
never used it before; most of this code was from somebody else, as seen from the credits. the only reason i knew this blind wasn't working properly was because of an exattox video 😭
how?
I'd assume something to do with the function in_pool(self)
-# and a "red x" react in 3... 2... 1...
in_pool = function(self) return false end
oh yeah I've got a challenge that replaces regular blinds with boss blinds and boss blinds with final boss blinds
I'll have to figure that one out
Speaking of which, I have a very similar problem! My mod has the ability to replace small and big blinds with boss blinds, but when I beat a boss blind that has replaced a small or big one, the Ante increases, when it very well shouldn't.
Here is my lovely.toml:
# Prevent Boss Blind from increasing Ante if it is not the last round of an Ante
# TODO: None of the patches in this section work, Ante still increases
[[patches]]
[patches.pattern]
target = 'functions/state_events.lua'
pattern = "G.GAME.blind:get_type() == 'Boss'" # Multi-line from line 111
position = 'at'
match_indent = true
payload = "BlindStation.FUNCS.get_current_blind_type() == 'Boss' and false"
[[patches]]
[patches.pattern]
target = 'functions/state_events.lua'
pattern = 'G.GAME.round_resets.blind == G.P_BLINDS.bl_small' # Multi-line from line 258
position = 'at'
match_indent = true
payload = "BlindStation.FUNCS.get_current_blind_type() == 'Small'"
[[patches]]
[patches.pattern]
target = 'functions/state_events.lua'
pattern = 'G.GAME.round_resets.blind == G.P_BLINDS.bl_big' # Multi-line from line 260
position = 'at'
match_indent = true
payload = "BlindStation.FUNCS.get_current_blind_type() == 'Big'"
and BlindStation.FUNCS.get_current_blind_type():
---Returns the current Blind type.
---@return string str The current Blind type, either 'Small', 'Big' or 'Boss'.
BlindStation.FUNCS.get_current_blind_type = function()
return G.GAME.blind_on_deck or 'Small'
end
oh these patches aren't working because you're using pattern patches and you're not looking for full lines
Though in this case I do actually want to use pattern patches, because the patterns appear 2 times each
Regex patches can match for sections within a line of code, but pattern patches won't
Ah, alright.
So if you actually want to do that replacement with single patches, you'll need to either make a regex search for it or just use separate pattern patches (which is a little clunkier but might be faster performance wise, for as much as that matters)
I think you need to use single quotes.
Nope, I had to double escape (\\)
It all works now!
Well, kind of. The ante doesn't increase but the blind UI still resets. More troubleshooting to do!
note that toml has raw strings '''text with \ backslashes and "quotes"''' so you don't have to do that
I am aware of those, but am only using them for multi-line strings
How can I get the mod prefix of an object? I am trying to use SMODS.create_mod_badges, which passes in a SMODS.GameObject that I want to determine the mod prefix of.
how to get the poker hand the player used the most ?
have a method or function for this ?
wow 12:00
ty very much
ohhh really, vanillaremade
you got a crash report or any code?
here
You need to account for if get_card_areas is null
actually that would be if the deck is null, not get_card_areas
No.
Code?
how to i get the level of specific poker hand ?
--Thank you PERKOLATED and HPR
function Card:resize(mod, force_save)
self:hard_set_T(self.T.x, self.T.y, self.T.w * mod, self.T.h * mod)
remove_all(self.children)
self.children = {}
self.children.shadow = Moveable(0, 0, 0, 0)
self:set_sprites(self.config.center, self.base.id and self.config.card)
end
local mainmenuref2 = Game.main_menu
Game.main_menu = function(change_context)
local ret = mainmenuref2(change_context)
local newcard = SMODS.create_card({key='j_tngt_wherethefuck',area = G.title_top})
G.title_top.T.w = G.title_top.T.w * 1.7675
G.title_top.T.x = G.title_top.T.x - 0.8
G.title_top:emplace(newcard)
newcard:start_materialize()
newcard:resize(1.1 * 1.2)
newcard.no_ui = true
return ret
end
G.GAME.hands["handname"].level
tyyyy
What is that line in the lovely dump?
which
Line 1972 in src/utils.lua
to get the level of the players most played poker hand, i would do
G.GAME.hands[G.GAME.current_round.most_played_poker_hand].level?
No.
cant find any lua named utils
local tempplayed = 0
local hand
for k, v in pairs(G.GAME.hands) do
if v.played > tempplayed and v.visible then
tempplayed = v.played
hand = k
end
end
local level = G.GAME.hands[hand].level
Try looking in your smods folder.
found it
what is v.played
and v.visible
It's how many times the hand has been played, and if the hand is visible or not.
What function is this in?
function SMODS.get_card_areas(_type, _context)
Have you tried using Card() instead of SMODS.create_card?
havent thought of that
hold
Code?
function Card:resize(mod, force_save)
self:hard_set_T(self.T.x, self.T.y, self.T.w * mod, self.T.h * mod)
remove_all(self.children)
self.children = {}
self.children.shadow = Moveable(0, 0, 0, 0)
self:set_sprites(self.config.center, self.base.id and self.config.card)
end
local mainmenuref2 = Game.main_menu
Game.main_menu = function(change_context)
local ret = mainmenuref2(change_context)
local newcard = Card({key='j_tngt_wherethefuck',area = G.title_top})
G.title_top.T.w = G.title_top.T.w * 1.7675
G.title_top.T.x = G.title_top.T.x - 0.8
G.title_top:emplace(newcard)
newcard:start_materialize()
newcard:resize(1.1 * 1.2)
newcard.no_ui = true
return ret
end
Card(G.title_top.T.x, G.title_top.T.y, G.CARD_W, G.CARD_H, G.P_CARDS.empty, G.P_CENTERS.j_tngt_wherethefuck, { bypass_discovery_center = true })
cheers
tysm
i keep the local newcard?
Yes.
alrigh
same utils crash
Try removing the newcard:start_materialize()
sure
Does SMODS have documentation on Card Packs?
You mean booster packs?
yeah sorry
same crash
And I'm assuming I'm able to take control of Booster Packs as well?
Yes.
But you would use take_ownership_by_kind
Where is Game:start_run ran?
Trying to do a UI thing but the UI hasn't loaded inside the start_run function so i wanted to place it after
But then won't it check if the played hand is the hand with the highest level?
G.FUNCS.start_run
No?
Is it possible to destroy a card that's not drawn yet?
Yes.
The same as any other card.
71x95?
Yes.
I have the following code in one of my files:
local video = love.graphics.newVideo(mod.path .. "assets/video/video.ogv")
This successfully loads the video for me but crashes the game for my friend. I am on Mac and he is on Windows so we suspect that may be the issue but does anyone know why it isn't working/how to fix?
hi is there any way to hide custom deckskins in settings?
the idea is to apply to run custom deckskins playing certain deck
what function is undoing this so I can redo it manually
it's a bit annoying
(also idk why it brings up the error calling recalculate it literally doesn't work and resize it if it's not in the code)
Actually I guess it is incredibly janky and breaks sometimes so I guess it's not entirely without basis
But compared to just not working at all, the health bar at least moves
I am going to assume with the benefit of the doubt that the reason I am experiencing so much frequent trouble with UI is just due to my inexperience
But I would not be surprised if it wasn't
(The funny thing is that the text doesn't move but that would actually be a good thing if the health bar actually worked properly)
don't think you thought that one through very well buddy
"say something only the real Odd Todd would know"
"man i love the number 4--"
BANG BANG BANG
what does the modded one do? (I'm assuming one of them you added)
showman(?)
came back to developing balatro mods after helping out someone else adding more content and i want to add more, starting with a deck. even though i tried following the lua already provided by both vanilla remade and the mod i'm apart of, the game crashes as it expects a '}' to close a '{' at the term 'unlocked' which is really dumb. here's the code i have for this deck right now for some more context:
key = "OyasumiDeck",
loc_txt = {
name = "Oyasumi Deck",
text = {
"Start with {C:attention}MARIs Picnic{}",
"and only have Spades in the deck",
},
},
order = 1
unlocked = true,
apply = function(self)
G.E_MANAGER:add_event(Event({
func = function()
if G.jokers then
local card = SMODS.create_card({
set = "Joker",
key = "j_tinsdumb_marispicnic",
area = G.jokers,
})
card:add_to_dec()
G.jokers:emplace(card)
end
for k, v in pairs(G.playing_cards) do
if v.base.suit == 'Clubs' then
v:change_suit('Spades')
end
if v.base.suit == 'Diamonds' then
v:change_suit('Spades')
end
if v.base.suit == 'Hearts' then
v:change_suit('Spades')
end
end
return true
end
end
}))
})```
even after adding the check_for_unlock part of the deck code which i forgot to add here it still crashes regardless by the way
Have you tried installing the Lua extension?
your probably assuming i'm using visual studio correct?
No, I'm assuming you're using visual studio code.
i'm using notepad++, sorry
insane
perhaps i should consider getting visual studio code then?
its free, and the Lua extrension could help with exactly your problem
It'll put error lines everywhere if your syntax is off
but i want to at least make sure that my deck works as it should before i put it in the repository though
why would working in VSC stop you from doing that
I meant you don't HAVE to switch, but it is very useful
n++ hate is crazy
I'm not hating on Notepad++, I use it all the time, just not for writing code
usually for HTML, CSS, XML, stuff like that
I mean n++ has syntax highlighting and whatnot
Well it appears this gentleman has a syntax error that isn't being caught
just out of curiousity, do you code in Notepad++
only for Lua
I can't code without an IDE anymore lol, too used to them
I was devastated when I figured out JetBrains doesn't have anythin for Lua
You can configure n++ to work like an IDE
It's like Vi except it has UI and is slightly worse
yeah I suppose
no hate towards it, I just recommend VSC since its what I use and its free
You missed a comma after order = 1
Is there a way to use the value in the SMODS.current_mod.config_tab to toggle the SMODS.Music?
okay i'm getting somewhere
Yes, you check for the config in the function.
now it's saying that '}' is expected at line 360 near end at line 336
here's the code right now
aaand i just noticed i misspelt deck
yippee!
You don't need to check for the suit, you can just do v:change_suit("Spades")
like this?
yeah bc if its a Spade already the change is redundant, but doesn't do any harm
Yes, also, if you right click, you can click Format Document and it will make everything more readable.
Is it this easy? (I have CFG defined as local at the top of the file.)
Yes.
would it make only one copy for each playing card instead of four
just asking before i restart balatro to apply the changes
which do you want? do you want 52 Spades or only the original 13?
if not v:is_suit("Spades") then
v:start_dissolve()
end
Thanks, I'm currently losing my mind that this is fully functional.
also w skins (Silksong tomorrow)
okay, i think it's ready for this deck to go into the mod i'm a part of now, thanks for the help!
although the last thing i need to do is creating a design for the deck
i'll probably do the lightbulb that's present in white space considering the deck is an omori reference
bump
I feel bad for asking for help so often
I feel like I should have gotten the hang of this by now
yeah no im going to bed and figuring this out tomorrow nice try
is there a way to make something run in a deck only starting at ante 2? like using if ante >= 2 then
Yes.
wichc?
wich*
wich way
how
sorry i dont speak english very well :(
sorry for mistakes
if G.GAME.round_resets.ante >= 2
ok
ty
its not working, do you know why? @daring fern
my code here, wait 1s
apply = function(self)
if G.GAME.round_resets.ante >= 2 then
G.GAME.modifiers.boss_rush = true
else
G.GAME.modifiers.boss_rush = false
end
end
this is a deck
The ante is never going to be above 2 when the deck is applied.
oh
im dumb sorry
lol
what do i use instead of this?
is there any method to do this when a new round starts or somenthing like that ?
idk sorry
Yes, use calculate
does it work in this case?
Yes.
ok
ty very much
youre incrible bro
hey bro, sorry for brothering, but i need your help
if I lower the ante and go back to 1, it doesn't return to normal
you can help ? @daring fern
Code?
calculate = function(self, back, context)
if G.GAME.round_resets.ante >= 2 then
G.GAME.modifiers.boss_rush = true
else
G.GAME.modifiers.boss_rush = false
end
end
Yes, calculate needs to be called for it to change.
so how could i make this work?, or would there be a btter method than calculate in this situation?
You wouldn't and no.
so there's no way to fix this if the ante goes down?
sad
but ok
ty :d
No, if something calculates after the ante goes back then it will work.
wdym
If you select a blind for example.
oh ok
could there be some kind of hack or workaround to make that happen?
How can I get the value of a sold joker during context.selling_card?
context.card.sell_cost?
perfect, ty
I have some cool combo and we'll balanced ideas for jokers and spectral cards. If some Wana add them to there mod then I can share these ideas (don't need any credits or something). Just let me play these ideas once they finished.
hey, Im making a mod with two friends, one is an artist, the other is a programmer and im a programmer too, if you want to share your ideas, if they're good, theyl probably get into the mod, it already has a lot of stuff, it's pretty balanced and cool
Can I dm you ?
currently we hve 6 pages of new jokers
ye
and others things obvious
how exactly does one implement ^mult
can someone help me with a blind that selects a random (visible) hand, debuffs it, and does this every time you play your hand?
sorry for brothering you again, but can you help me? @daring fern
Without Talisman?
this is my code actually
config = { extra = {
visibleHand = {},
randomIndex = nil,
chosenHand = nil
}},
set_blind = function(self)
self.config.extra.visibleHand = {}
for k, v in pairs(G.GAME.hands) do
if v.visible then
table.insert(self.config.extra.visibleHand, k)
end
end
self.config.extra.randomIndex = math.random(#self.config.extra.visibleHand)
self.config.extra.chosenHand = self.config.extra.visibleHand[self.config.extra.randomIndex]
G.GAME.blind_message = {
message = localize(self.config.extra.chosenHand, 'poker_hands'),
colour = G.C.RED
}
end,
drawn_to_hand = function(self)
self.config.extra.visibleHand = {}
for k, v in pairs(G.GAME.hands) do
if v.visible then
table.insert(self.config.extra.visibleHand, k)
end
end
self.config.extra.randomIndex = math.random(#self.config.extra.visibleHand)
self.config.extra.chosenHand = self.config.extra.visibleHand[self.config.extra.randomIndex]
end,
debuff_hand = function(self, cards, hand, handname, check)
return handname == self.config.extra.chosenHand
end,
can someone help me?
if context.after then
_, blind.hand = pseudorandom_element(G.GAME.hands, "seed")
end
if context.debuff_hand and blind.hand then
return {debuff = true, debuff_text = localize(blind.hand, 'poker_hands'), debuff_source = self.key}
end
```?
Yeah, I figured it out actually don't worry
return { mult = (mult ^ card.ability.extra.emult) - mult }
works fine
Yes, but that would make the mult sound.
I can return a custom sound
And show a mult message.
remove_default_message
However with a custom message I can't figure out how to have a custom value
with localization
I tried message = localize("a_emult") and a_emult = "^#1# Mult" in the localization file
it just. directly prints out ^#1# Mult
Is that in v_dictionary?
why does it have to be in the v one?
For variables.
whats that thing that jokers do where they like, shake briefly when something happens
im struggling to remember jokers that do it but i remember its just like a Thing you can make them do and thatd come in handy here
ok now it just says ERROR
its debuff any hand and not only the visible ones, do you think my code was a little bit right?
whats the process for doing it remotely again?
basically trying to do it before it gets destroyed by a deck ability
Also, it would be localize({type = "variable", key = "a_emult", vars = {card.ability.extra.emult}})
thanky ou
ohhhh wait its that thing ok
if context.after and not blind.disabled then
local hands = {}
for k, v in pairs(G.GAME.hands) do
if v.visible then
table.insert(hands, k)
end
end
blind.hand = pseudorandom_element(hands, "seed")
end
if context.debuff_hand and blind.hand and not blind.disabled then
return {debuff = true, debuff_text = localize(blind.hand, 'poker_hands'), debuff_source = self.key}
end
```?
I'm still hung up on the blinds refreshing when I beat a Boss before I'm supposed to. Here are my patches, the top one is the one that's not working:
# Prevent Boss Blind from increasing Ante if it is not the last round of an Ante
# TODO: Fux Blinds refreshing when a Boss Blind is beaten before it usually is, the below doesn't work
[[patches]]
[patches.pattern] # Double escape
target = 'functions/state_events.lua'
pattern = 'G.RESET_BLIND_STATES = true' # Line 94
position = 'at'
match_indent = true
times = 1
payload = """if BlindStation.FUNCS.get_current_blind_type() == 'Boss' then
G.RESET_BLIND_STATES = true
end"""
[[patches]]
[patches.regex] # Mid-line match, double escape
target = 'functions/state_events.lua'
pattern = "G\\.GAME\\.blind:get_type\\(\\) == 'Boss'" # Multi-line from line 111
position = 'at'
match_indent = true
payload = "BlindStation.FUNCS.get_current_blind_type() == 'Boss' and false"
[[patches]]
[patches.regex] # Mid-line match, double escape
target = 'functions/state_events.lua'
pattern = 'G\\.GAME\\.round_resets\\.blind == G.P_BLINDS\\.bl_small' # Multi-line from line 258
position = 'at'
match_indent = true
payload = "BlindStation.FUNCS.get_current_blind_type() == 'Small'"
[[patches]]
[patches.regex] # Mid-line match, double escape
target = 'functions/state_events.lua'
pattern = 'G\\.GAME\\.round_resets\\.blind == G.P_BLINDS\\.bl_big' # Multi-line from line 260
position = 'at'
match_indent = true
payload = "BlindStation.FUNCS.get_current_blind_type() == 'Big'"
The function is the following:
---Returns the current Blind type.
---@return string str The current Blind type, either 'Small', 'Big' or 'Boss'.
BlindStation.FUNCS.get_current_blind_type = function()
return G.GAME.blind_on_deck or 'Small'
end
oh ok, makes sense
but, i dindt understand the last part, the one bellow
That's the part that debuffs the hand.
hey y'all, is there a card.children.center:set_sprite_pos equivelant for changing soul_pos? (i found it it's card.children.floating_sprite:set_sprite_pos)
shouldnt it be
debuff_hand = function(handname)
if handname == blind.hand
end
?
What
No.
why
It could but it's better to use calculate
oh, ok
how do i make it so every time it selected a hand for debuffing, it shows on the screen which hand its debuffed ?
ok one last weird question, if i wanted to have the joker being destroyed show an exclamation mark message below it, what would i put here? i assumed card = joker_to_destroy would be enough but it's not showing any message anywhere
message_card = joker_to_destroy
ohhhh ok
oh theres so many places i can add that
not here specifically but i wanna have better indication of whats going on yk
with my other jokers
is it possible to do that ?
this isnt giving any message for some reason, does it need to not be part of the event or something?
or maybe the joker being destroyed stops it from giving a message?
set_blind = function(self)
local hands = {}
for k, v in pairs(G.GAME.hands) do
if v.visible then
table.insert(hands, k)
end
end
self.hand = pseudorandom_element(hands, "seed")
end,
calculate = function(self, blind, context)
if context.after and not blind.disabled then
local hands = {}
for k, v in pairs(G.GAME.hands) do
if v.visible then
table.insert(hands, k)
end
end
blind.hand = pseudorandom_element(hands, "seed")
end
if context.debuff_hand and blind.hand and not blind.disabled then
return {debuff = true, debuff_text = localize(blind.hand, 'poker_hands'), debuff_source = self.key}
end
end,
this is my code, when I enter the blind nothing happens, but when i play a hand, it shows the last hand I played (or maybe just a coincidence) for any kind of hand I select and it debuffs every single hand i play
try it
also it looks like you didn't actually destroy the joker
Yes, move it out of the event.
idk if im dumb, if its really hard, if iam an idiot or what
or maybe its sleepiness
it definitely does destroy the joker i think? it looked like it did and i had a run prior where the joker appeared in the shop again
why exactly is this not upgrading
it's SUPPOSED to upgrade whenever your least played joker hand is played
this has the same outcome i fear
hurm i swear i heard that you had to do something other than start_dissolve to destroy a joker
whatever clearly im wrong LMAO
do you put the amount of retriggers a joker does in the config = { extra = { ?
Just a quick bump, anybody got any clue about this one thing hanging me up right now?
Yes.
so just retriggers = 1?
Yes.
Yes.
oke
SMODS.Joker{ --TheInnerEye name = "The Inner Eye" key = "innereye" config = { extra = { retriggers = 1 } },
oke
bump
There are a few rather specific things you need to do, I’d probably just recommend waiting for me to port some actual blind customisation over
What are you referring to?
guhh how do i custom sounds
Ah thank you! I couldnt find that page for some reason

