#💻・modding-dev
1 messages · Page 549 of 1
am I using the new (to me. i havent updated smods in ages) probability syntax wrong? it seems like this is how youre meant to use it so idk why it's showing 1 in nil
it is 100% looping through the entire deck every time quantum enhancements are checked
that WILL cause mega lag
I'd double check card.ability.odds
This occurs even if I comment out the actual deck code, it still causes lag with the Joker present on its' own on other decks.
that seems very strange
btw, is there a way to take ownership and/or overwrite an atlas?
this surely isn't the right way, but it's the only one I could make work
SMODS.Atlases['casl_sleeve_atlas'] = nil
G.ASSET_ATLAS['casl_sleeve_atlas'] = nil
SMODS.Atlas{ key = 'casl_sleeve_atlas', px = 73, py = 95, path = 'sleeves.png', prefix_config = false }
you just need the last line iirc
raw_key?
prefix config should be a table though, right?
I don't remember because I don't use it 🙃
i think false works
docs said it can just be set to false but who am I to trust the docs
-# But yeah, I have 0% idea what's up with my mod causing lag when a specific Joker is involved or how to do the enhancement sharing deck better...
-# Partially considered making my quantum enhancement optional feature a toggle so that the two items don't get initialized.
logs say this (and the textures indeed don't change); using raw_key instead or combined with prefix_config seems to do nothing
INFO - [G] 2025-08-27 00:24:28 :: WARN :: Atlas :: Object casl_sleeve_atlas has the same key as an existing object, not registering.
INFO - [G] 2025-08-27 00:24:28 :: WARN :: Atlas :: If you want to modify an existing object, use take_ownership()
an attempt with take_ownership
SMODS.Atlas:take_ownership('casl_sleeve_atlas',
{
path = 'sleeves.png',
mod = SMODS.current_mod
}
)
results in no changes to the textures
I wonder if it's because it's a modded object?
rq question how would i make a joker emplace a copy of used spectral cards
well the problem is that consumable types dont have those
so if you have the same key it will be treated as the same
What controls the position of pop-up messages (e.g. when a Joker makes a card score)
but that's a bug for modded Consumeable Types
message_card?
yeah it might be too late to change without breaking stuff
not the position of the message relative to the card
just add the prefix yourself
I mean, different mods overwriting each other's Consumeable Types is already breaking stuff
just redefining a vanilla atlas sure works without issues yeah
I'm sorry if this sounds stupid but I don't know how to properly use this
For example, the message displays below Jokers and above playing cards
same way as ghost deck
instead of spectral is your key in lowercase
from what I remember, consumable types weren't prefixed because having to type your mod prefix in every situation where you need to reference the type would be a massive pain so people just need to use unique keys
i just prefix them
the seven billion Zodiac mods:
Thanks
yeah I prefix mine too
🤷 So I'm not sure what to do with the QE stuff.
stone card not updating front after changing enhancement
how do i fix this
the number on the card does not update
it stays blank
QE are just jank and make the game lag, I don't think there's much you can do about it
I love my consumables to have other mods label because my name wasn't unique enough
...I'd at least think others using QE are less laggy than mine...
do you have any optional card areas turned on by chance?
togabalatro.optional_features = function()
return {
cardareas = { deck = true, discard = true },
retrigger_joker = true,
quantum_enhancements = true
}
end
Yes.
do the new probability functions automatically apply probabilities.normal?
how does this look?
I made it apply to the three Shop CardAreas
I can PR it to SMODS
-# tomorrow
yes
awesome
deck in tandem with quantum enhancements is probably causing a big chunk of the lag i think
try turning the deck off and testing it again
I've tried doing this, didn't seem to work. Not sure what I'm doing wrong
Commenting out cardareas = { deck = true, discard = true }, reduced the lag, sure.
I'll probably rework the only Joker that checks for context.cardarea being G.deck or G.hand, then.
bump
if context.using_consumeable and context.consumeable.ability.set == "Spectral" then
local copy = copy_card(context.consumeable)
copy:add_to_deck()
G.consumeables:emplace(copy)
end
this solution actually doesn't work and returns this crash :/
it's context.consumeable iirc
does anyone know the opacity of the glass joker
I am trying to create an info-queue styled (aka detailed_tooltip) hover-on-HUD for my "overshoot" UI thing, but so far, the best I can do is a modified version of the poker hand HUD (tooltip).
To try to allow this tooltip appearance and possibly formatting, I tried to reverse engineer the generate_card_ui to only obtain the necessary elements for the UI, but doesnt work out so far (results in a crash).
function create_UIBox_detailed_tooltip_fake_unik(tooltip)
local full_UI_table = {
main = {},
info = {},
type = {},
name = 'done',
badges = badges or {}
}
local desc_nodes = (not full_UI_table.name and full_UI_table.main) or full_UI_table.info
if full_UI_table.name then
full_UI_table.info[#full_UI_table.info+1] = {}
desc_nodes = full_UI_table.info[#full_UI_table.info]
end
localize{type = 'MiscDesc', key = tooltip.key, nodes = desc_nodes}
full_UI_table.name = localize{type = 'name', set = tooltip.set, key = tooltip.key, nodes = full_UI_table.name}
if full_UI_table.name then
full_UI_table.info[#full_UI_table.info+1] = {}
desc_nodes = full_UI_table.info[#full_UI_table.info]
end
localize{type = 'MiscDesc', key = tooltip.key, nodes = desc_nodes}
local desc = full_UI_table
return {n=G.UIT.ROOT, config={align = "cm", colour = G.C.CLEAR}, nodes={
{n=G.UIT.R, config={align = "cm", colour = lighten(G.C.JOKER_GREY, 0.5), r = 0.1, padding = 0.05, emboss = 0.05}, nodes={
info_tip_from_rows(desc.info[1], desc.info[1].name),
}}
}}
end
I'd also tried reverse engineering/copying aiko's descriptiondummies, but it didnt work out
and the closest suggestion was trying to look into yggdrasil's code, but didn't have much clue
UI in question: #⚙・modding-general message
and part of the UI code as well:
hover = true,
can_collide = true,
id = 'unik_overshoot_desc',
unik_fake_tooltip = {text = localize("overshoot_unik_" .. G.GAME.OvershootFXVal)},
does anyone know the opacity of the glass joker
<@&1133519078540185692>
all the crypto. its mine
vonnegut mining crypto
does anyone know the opacity of the glass joker
Anyone willing to help me out a bit? Someone pointed out my mod may need to be updated and my PC shit itself a while ago. Anyone know how to fix? Been a while
I dunno. Similar question with Sonic X mod I made a while ago. I may look into this.
so I finally got back to working on my mod and I'm still struggling with the same issue regarding context.post_trigger
it seems like the code is never being read which leads me to believe the problem is either context.card_area = G.jokers or not context.blueprint
but I feel like neither of those should be issues, so idk if it's a bug or I'm misunderstanding something about the game
(all of these are passed through the and operator in a calculate function)
is it possible to add perma repetitions now with the 0827
yes
it's cardarea
also i don't think you need the area check at all
let the numberslop begin
where glop
...huh, how do I adapt this for SMODS.scale_card...
if context.using_consumeable and not context.blueprint then
card.ability.extra.curchips = (G.GAME.consumeable_usage_total and G.GAME.consumeable_usage_total.all or 0) * card.ability.extra.bonuschips
end
key = 'helluvaquipsL1',
type = 'loss',
extra = { center = c_star },
loc_txt = { ['en-us'] = { "Fuck!", } }
}```
Can someone tell me what I'm doing wrong with the new JimboQuips feature? It's telling me it has a nil value for the quip.
very balanced :3 (obviously this won't be a real joker)
-# operation function to rescue---
SMODS.scale_card(card, {
ref_table = card.ability.extra,
ref_value = "curchips",
scalar_value = "bonuschips",
operation = function(ref_table, ref_value, initial, change)
ref_table[ref_value] = initial + (G.GAME.consumeable_usage_total and G.GAME.consumeable_usage_total.all or 0)*change
end
})```
Like this
The message doesn't reflect the new card.ability.extra.curchips value... and the initial value in operation is not of use to me due to the Joker scaling regardless if owned or not.
Give it a custom message too
I left the initial bit in my mistake, apologies
The message uses the pre-scaled value... do I also need to change the vars to include the change itself?
scaling_message = {message = localize{type = 'variable', key = 'a_chips', vars = { card.ability.extra.curchips } }, colour = G.C.CHIPS }
You’d put the calculated value in there, but this isn’t really a scaling joker tbh
...yeah, isn't...
It’s just passive based on a value
+15 chips when consumable used vs 15 chips for every consumable used
Now, I have a different one that uses either 3xvalue or value by itself conditionally when scaling.
for k, v in ipairs(context.removed) do
if v.config.center ~= G.P_CENTERS.c_base then
SMODS.scale_card(pcard, {
ref_table = card.ability.extra,
ref_value = "xchip_mod",
scalar_value = "xchip_increase",
no_message = true,
operation = function(ref_table, ref_value, initial, change)
ref_table[ref_value] = initial + 3*change
end,
})
else
SMODS.scale_card(pcard, {
ref_table = card.ability.extra,
ref_value = "xchip_mod",
scalar_value = "xchip_increase",
no_message = true,
})
end
end
...I'd just rather not invoke the "Upgrade!" message per card destroyed like before the change to a singular one.
Do you categorise this as one scaling event or a scaling event per card destroyed?
Per-card, but I'd rather not spam messages.
If Balatro was written by VivziePop
That all looks fine then apart from the bottom one should have operation = "X"
Also, this is anew feature only for dev
the new smods update is out
fr
...why? I want to add 0.05 to current XChips, not multiply by that value.
Oh wording is funky I guess
That's the goal if I can get it to work xD
I misinterpreted
Any clue what I'm doing wrong?
if context.remove_playing_cards then
for k, v in ipairs(context.removed) do
if v.config.center ~= G.P_CENTERS.c_base then
-- Add 3x0.05.
SMODS.scale_card(pcard, {
ref_table = card.ability.extra,
ref_value = "xchip_mod",
scalar_value = "xchip_increase",
no_message = true,
operation = function(ref_table, ref_value, initial, change)
ref_table[ref_value] = initial + 3*change
end,
})
else
-- Add 0.05.
SMODS.scale_card(pcard, {
ref_table = card.ability.extra,
ref_value = "xchip_mod",
scalar_value = "xchip_increase",
no_message = true,
})
end
end
end
Easier detection and manipulation of scaling Jokers.
the one million calls to cryptids scaling function:
Look in here
So i should edit the cards that change their own values with said function?
It's an opt-in feature, but yeah, go read that discussion post.
Reading all that, theres a lot of changes ill have to make.
oh, you can use scale_card over stuff that resembles card.thing = card.thing + card.delta?
yea
and by using scale_card, it allows other modded content to detect when (and even modify how) your card is scaling
I did need to do that for a joker
I don’t think you necessarily have to change anything, it’s all just optional/ease of use stuff really
There is the code i have conflicts
And the optional ones will be usefull for some jokers i have to do
God...
card.ability.extra.Xmult_current = card.ability.extra.Xmult_current + (context.ending_shop and card.ability.extra.add_shop*8 or context.playing_card_added and context.cards and #context.cards and card.ability.extra.add_shop*#context.cards or card.ability.extra.add_shop)
Nothing Ever Happens joker: all scaling jokers no longer scale, prevent the next change in ante, self destructs
What really? Let’s go
how do i make it so a joker triggers its effect more then once with it visably triggering in game?
Hi friends! I have an issue that needs fixing
wait hold on
nevermind i fixed it
so like retriggering jokers?
kinda? i want the joker to retirgger itself without doing so infittly
if context.retrigger_joker_check and context.other_card == card then
repeat{
repetitions = 1
}
end
prob smt like that
where would i add this?
at the very top of the function
the order shouldnt matter
nevermind again hold on
my yveltal.lua file now has a nil value where its mult should be. how can we fix this?
the game crashed with unexpected symbol near { line 33
download lua extension
me?
no, @knotty steppe
oh
well that wasnt me that was just what joker forge generated the file with
ok so what do i do here
add x_mult_inc = 0.1 in config = { extra = {...
ah
Talisman needs to be updated for latest stable.
oh. thanks.
is talisman updated for latest smods? (the scale_card changes)
Twin, you need to close the function with end, you're only closing the if statement rn
there is more down the line
bro put repeat
Could you share it?
dont roast it too hard its my first
bro put repeat
you put repeat
yea?
i think that is supposed to be return
it wokrs thx
what
why did that get blocked
hmm today i will make a balatro mod 
github randomly deciding to screw me over:
remote: Invalid username or token. Password authentication is not supported for Git operations.
ouggghh not this again
it works but now there is a long pause before it rins
is it because i told it to run 500 times
hmm perhaps
why does it pause
how do i fix this again i know i've done this token stuff before but i do not remember how
i knwo its becuase the number is 500
but why does bigger number make pause
calculating
but the calculationg screen is only up for a split second
dunno then
the background is placeholder until i muster the strength to make my own cool space pixel art, all credit to the absolute beasts who made lost edition
It's because it usually takes some amount of time for bigger calculations
I don't know the specifics but yeah
I love your jokers
thank you thats so kind wtf
Like seriously, there's not one joker I've seen from you where I've been like "that's silly..." or "I don't know about that..."
:,D
bumping again i just want to code stuff not deal with github being dumb and bad
There's another, even with the latest Tailman installed.
Someone ping me if you find what it is.
what swrong with my code to be causing this? I have talisman enabled if thats the issue
might have to update it though
I remember hovering something before it crashed.
It like had an edition.
is this from your mod
I didn't make any of these mods.
then #⚙・modding-general
Gotcha.
Talisman's up to 2.3.4 rn.
how do i have the button rendering behind the card......
i have it rendering the same as .children.use_button and you can see that its behind the card (SELECT)
do it in the drawstep
time to learn and become even stronger
there's a drawstep for buttons that replaces that
i use the same priority here to draw my button
https://github.com/nh6574/JoyousSpring/blob/eaa54d065b5ab61f809615ed006709c6aff40233/src/states.lua#L415
this?
yes
-# ...how safe is playing a sound on a crash screen, anyway... 🤔
i figured this out a couple of days ago lol
smt like this, right?
sounds right
actually idfk why i added the not not
Any specific purpose in mind?
Just curious
Though the current implementation works only if you crashed after initialization.
How are you able to add that sound effect
That video in particular uses play_sound(sfxkey)... but I am gonna use NFS instead.
could be because of multiple draw functions? idk ive seen you using that a lot recently
No, I removed all the SMODS.DrawSteps I added, and it still lags.
the local crashdata = love.filesystem.newFileData((togabalatro.nfs or nfs).read(togabalatro.path.."/assets/sounds/macperforma5400.ogg"))
has anyone had an issue with jokers seemingly randomly no longer loading into the game? I've got this joker which has worked fine, and nothing has changed on it looking at my old commits but it is no longer showing up in game.
is there something I could've written in another joker that is causing it not to load?
Do you have another joker with the key thrifty_joker?
vscode search shows no other occurence of that string
I updated my mods and the problem seemed to fix itself.
hmm testing adding another joker that is a duplicate of an existing working joker with a new key & name it doesn't appear, it looks like I just can't load more than 24 jokers
but adding bugged code into thrifty_joker or the duplicated joker causes the game to crash?? i am so confused
found it, was a duplicate key no idea what with
Hey I remeber someone here posted tutorials for how to do designs for cards with templates included but I can't find it, does someone have it? I kinda want to have my own custom facecards and jokers
...well damn, how do I access the global hand_chips and mult from here then...
SMODS.scale_card(card, {
ref_table = card.ability.extra,
ref_value = "chips",
scalar_value = "hand_chips",
scalar_table = "_G",
operation = function(ref_table, ref_value, initial, change)
ref_table[ref_value] = initial + change
end,
no_message = true
})
isn't scalar_table supposed to be type table?
-# oops.
it happens to the best of us lol
To be fair, it's like 7:29 AM and I've yet to go to bed, basically almost done converting all the scaling I use to SMODS.scale_card...
hello friends I have a couple things I'd like to discuss and hopefully fix
first of all
the joker I'm testing, Dialga, is supposed to take you back one ante if you defeat a boss blind with it in the leftmost joker position
and it does go back one ante
but the game immediately puts me forward another ante
how can i prevent this
Go back 2 antes?
how did i not think of this
Or, with new contexts...
if context.modify_ante and context.ante_end then return { modify = -1 } end
?
can you do that?
i don't think you can do that, context.ante_change runs after the ante actually changes
-# Just thinking, I've yet to use such contexts, but I am too tired to experiment currently with 'em as I'm prepping an update.
hi i just started modding and my game crashes as soon as the deck is rolled out
https://hastebin.com/share/hicocahazu.yaml
its only 4 mods and i only downloaded stuff that the github for the main overhaul said was compatible
Hastebin is a free web-based pastebin service for storing and sharing text and code snippets with anyone. Get started now.
Also why are you using a function to check the position instead of just doing if G.jokers.cards[1] == card
i didnt code it, i just generated it using jokerforge
also something weird happened while i was testing it
i used Deck Creator to get a deck with Dialga in it to playtest it
but it ended up giving me some... interesting shop choices
for some reason Jimbo just kept showing up
You should be using DebugPlus
alright thanks
disabled everythng but maximus and its causing the crash all on its own
whats "quip"
So I know how to make a deck, how do I make it so that all playing cards are aces?
apply = function(self, back)
G.E_MANAGER:add_event(Event({
func = function()
if not G.playing_cards then return false end
for k, v in pairs(G.playing_cards) do
SMODS.change_base(v, nil, "Ace")
end
return true
end
}))
end
i assume
alright folks, i think i figured out what is wrong with my mod.
so in jokerforge i undid all the ways that my jokers could appear in the shop. they can't be found in the shop, buffoon packs, or judgement.
HOWEVER, It may have removed them from the pool of jokers available, but they haven't exactly removed them from the instances in which they were supposed to appear
so it puts them in the shop, the packs, and in judgement, but THEN it reminds itself that it can't, and just replaces them with Jimbo.
so how the hell do i fix this
in_pool = function() return false end?
i found how the hell i fix this
jokerforge just reset the rarity weight to 1
for some reason
even though i put it to zero
so i set it back to zero so now they shouldn't appera
ok new problem
so what I intended to happen was for Arceus to destroy Giratina after the end of the shop
but that doesn't happen
Yes, you need your mod prefix.
my mod prefix is "legendar". does it include the "j" in the beginning?
It would be j_modprefix_key
cool thanks
alright something new happened
well its not new
yveltal is still displaying nil mult in its description even though (I think) i fixed it
I'm very new to modding, can someone help me out on how make a mod to change pre-existing code (For example, the code responsible for what boss blinds do)?
SMODS.Back {
key = "truekinda",
atlas = "atlas_truekinda",
pos = { x = 0, y = 0 },
config = {},
loc_txt = {
name = "True Kinda Deck",
text = {"Start with {C:hearts,E:1}Spinel{} and {X:hearts,C:clubs,E:1}Gar{X:clubs,C:hearts,E:1}net{}",
"And a deck of 52 Ace Cards consisting of only the {C:hearts}Hearts{} and {C:clubs}Clubs{} suits."}
},
apply = function(self, back)
G.E_MANAGER:add_event(Event({
func = function()
if not G.playing_cards then return false end
for k, v in pairs(G.playing_cards) do
SMODS.change_base(v, nil, "Ace")
end
if v.base.suit == 'Spades' then
v:change_suit('Clubs')
end
if v.base.suit == 'Diamonds' then
v:change_suit('Hearts')
end
return true
end
}))
end
-- I feel like there should be a loc_vars here somewhere.
}```
what do i do with the loc_vars
No, you don't need a loc_vars
Sorry, just a quick question; any way I can make it so a Joker has no text box in the UI?
You mean no description?
yeah,
i can't copy the error log for some reason
I want to get rid of the white part here so it's just the Joker name and badge.
You would probably hook generate_card_ui and do something with full_UI_table.main
items/deck.lua:36 "attempt to index global 'v' (a nil value)"
this is line 36: if v.base.suit == 'Spades' then
Thanks, I'll take a look at the docs!
Yes, those checks are outside the loop.
so do i put the change_suit inside the change_base?
No, you move the for loops end to after the last if
oh
i see
so
i didn't know i actually did it
so what happened is that
they're all in a for loop
I'm still trying to edit my consumabletype's shop_rate for a specific deck and i'm failing quite miserably. From what I've seen it's pretty simple but I'm most definitely doing everything wrong
In apply you would do G.GAME.key_rate = number
consumabletypes also require a prefix? From what I've been told just the base key is enough
alrighty
Yeah that worked, thank you a lot!!!
How do I make multiline mod description without this white background thing?
I've already asked this before but how do i tie a joker to another one's existence? So if the main one gets sold the linked jokers get removed automatically.
Destroy it in remove_from_deck
what does ante_end detects
It's when the ante is changed when the ante ends.
alrighty
hello there, this joker crashes the game when i play a hand after its gain Xchips effect has been triggered, is there a way that i can fix it ? (ping me pls)
thanks
is it context.other_card.ability.perma_retrigger
No, it's card.ability.perma_repetitions
thanks
how can i get key of a random owned voucher?
G.GAME.used_vouchers is a map, not a list, so you want
local _, voucher = pseudorandom_element(G.GAME.used_vouchers, 'seed')
it work, thanks ❤️

using tools like debug plus to check what the code is actually doing at any given moment is a vital programming skill
Wdym font color
Text color
Font refers to the text style I believe
There’s an SMODS.font
That’s why
Can you just tell me how to change the rarity badge text color
TEXT color, not BADGE color
how do you check if a card has no enhancement
if not next(SMODS.get_enhancements(card))
thanks
does this look right
No, it would be if not next(SMODS.get_enhancements(context.other_card))
wheres the code that creates the buy button when the card is highlighted in shop?
G.UIDEF.card_focus_button
how do you check if the played hand contains another, again?
Another what?
config = { extra = { mario = 1, numerator = 1, denominator = 3 } },
loc_vars = function(self, info_queue, card)
return {
vars = { card.ability.extra.mario, card.ability.extra.numerator, card.ability.extra.denominator }
}
end,
calculate = function(self, card, context)
if context.individual and context.cardarea == G.play and not context.blueprint then
if not next(SMODS.get_enhancements(card)) and SMODS.pseudorandom_probability(card, 'meth', card.ability.extra.numerator, card.ability.extra.denominator) then
context.other_card.ability.perma_repetitions = (context.other_card.ability.perma_repetitions or 0) +
card.ability.extra.mario
play_sound('tngt_hellomario', 1.2)
card:juice_up(0.5, 0.5)
return {
message = localize('k_upgrade_ex'),
card = card
}
end
end
end
}
any ideas why this isnt working
next(context.poker_hands["name"])
if next(context.poker_hands["Four of a Kind"])
schweet, thanks :D
and you're positive that would also trigger if a 5oak is played, eg.?
smashing, thanks ^u^
it should be context.other_card in get_enhancements
so like
you can write all your thoughts in one message
context.other_card and SMODS.pseudorandom_probability(card, 'meth', card.ability.extra.numerator, card.ability.extra.denominator) then
?
oh okay
also the probabilities doesnt change by 6s
althought i already defined the num and den
Yes, you're not using SMODS.get_probability_vars in loc_vars
example being?
local numerator, denumerator = SMODS.get_probability_vars(card or self, 1, yourOddsVariableHere, 'your seed here')```
OHHH okay
wait where do i put this
in loc_vars
This is definitely very unbalanced in late blinds but I might nerf it to decrease by 2
Might rework it to percentage though instead of fractions
does context.mod_probability have context.other_card or an equivalent to it?
asking this once more how the fuck do i do the token thing i still cant figure it out even when i generate a token with github it still doesnt accept it
Salty ghost, how your hotpot thing going?
I have a project hosted on GitHub. I fail when trying to push my modifications on the master. I always get the following error message
Password for 'https://git@github.com':
remote: Invalid usern...
i paste in the token for the password and it just gives the same exact error :(
tried this before too
both when i have the extra couple characters at the beginning and when i dont
is there something else i'm missing?
absolutely nothing i can figure out about what i'm doing wrong
i've tried doing ssh stuff too but it kept completely failing horribly
Then something may be up with your config entirely... assuming you've attempted generating fresh SSH keys and such? https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/reviewing-your-ssh-keys
yeah ive tried, also didnt work
okay so how do i unfuck my config then
and which config do i unfuck
So I did some trickery to the exe of balatro to load smod on this console without lovely injector
Wanted to get cryptid mod working
But couldn't get tailsman to load
Kept giving an calculation error
talisman is a lovely mod
how come my edition's dynamic text doesn't show when it's actually on a card?
i think that's a bug with editions
is there any way to fix it or am i a little Fucked
I think @chrome widget had this issue?
got 0 clue
i just want to make my mod already :(
info_queue is wonky
I don't think it even supports main_start and main_end
¯_(ツ)_/¯
it does
uh, then no idea what's wrong with main_start above
like i said i think it's a problem with editions specifically
I could get cryptid mod to load on the device
yeah that's because the talisman patches are not loaded
How can you duplicate a playing Card in a deck?
copy_card.
managned to get the patches load but game just opens and closes
rip
I've managed to get the exe of balatro to load smod without the need of lovely injector
which is a good start
wait do i need to like. give the token more perms because its a private project or something?
not sure what permission thatd be though but it probably has things to do with how the project is private
since its failing at a git clone
The generate_ui code for tooltips specifically doesn't support this kind of thing. I had to add support for that myself AFAIK
Use this patch:
sorry for actually horrible "screenshot" i dont have access to discord on my laptop rn
how does one make this so you have to select a joker rather than a card
cuz consumables kinda go over my head and i dont think theres anything from vremade i can look at
taking a picture of my screen hurts i promise it wont happen again
Change G.hand to G.jokers
if i add a sticker to a joker do i have to manually write code to do any animation or effect or does it just do it when adding stickers
hi guys 👋
Yes, adding a sticker just puts the sticker on the card.
Sorry for the ping want to make sure my reply to this doesn't get lost
nw, thanks for the patch
i have this effect that's supposed to trigger on blind start when it's the only joker, but it doesnt trigger if the ceremonial-esque has destroyed a joker before
despite it visually being the only joker there
Does ceremonial effect leave behind ghosts?
if something destroys another card when blind is selected it will probably destroy it in an event so it will not register as destroyed until after the context is calculated
you need to also check if card.getting_sliced is not true
do you guys happen to know how packs decrement their selections? ie when you hit use on a consumable in a select 1 of 2?
ive added a button to one card and it seems to ignore that
but it doesnt trigger even in the blind after
Yes, it happens in G.FUNCS.use_card
Awesome thanks
how are you checking
also hi somecom how are you today
Hi N
hii dilly
it's sending
wifi is slow down here
Hi Winter
hi N
i just got mcdonalds ice cream
I could go for a chocolate brownie blast from the local Sonic Drive-In
Hello goddess of the northern mountains, feller of legions
Commander of this realm
What legions am I felling?
all who oppose you
hi winter do you need one to oppose where do i sign
Oh I thought the Burning Legion was invading again
how can i make a voucher detect whenever a joker is destroyed then add its key to the G.GAME.chak.banned_run_keys[v.key] var
@red flower no idea if the reply notif happened because internet so here
actually just how can i make a voucher detect whenever a joker is destroyed then get that joker's key
i read everything anyway
how would i change this so it doesn't prevent every grass card from gaining 0.1x when one reaches 1.5x?
oh ok
vouchers have calculate afaik
Anyway I'm the artistttttttt rn
swaq
good luck with the artisting winter
why do you do this in a loop
good luck winter
hi diddy
its in the blind context
@manic rune its you all over again
but if you're checking if there's only one joker you dont need a loop
?
wdym
Here's some art I've made recently
ok what did you show me lol
I was asking how are you checking if it's the only joker
amazing
This some heat
is that a fucking jojo reference
the for loop yeah
goes through checks if the number of jokers is 1 and that joker is this card
in the year of the lord 2025???
I'm making a JoJo mod
ok then if the number is one the loop will only do one iteration
So..... like yeah
so you dont need a loop
yea winter has made a flames mod
ive played a wee tiny bit of it so far cause life has distracted me
so how would that format
if #G.jokers.cards == 1 then
if the joker is calculating then it's there so you dont need a check for it
but you can add G.jokers.cards[1] == card
i seee
Special attention to Prideful Jokestar cause of the fizzling neon sign effect
is it me or the background of this card is really bright
can u teach me how to get good at art
3:
Most everything I do involves a lot of stealing and a lot of trial and error
now to check if any card is going to be destroyed then you do need a loop
local count = 0
for _, joker in ipairs(G.joker.cards) do
if not joker.getting_sliced then
count = count + 1
end
end
I don't actually consider myself a good artist or even an artist at all
I Make Art but those are kinda different things IMO
i want to get better at Art
same
i feel like mine's just
ight
mine is bad ugly bad terrible
well destruction works fine
its just supposed to transform when it's the only guy, which works great if it hasnt previously destroyed the joker beside it
I also have some decent non-Balatro illustrations that I've made (some of it explicit unfortunately so I can't publicly share it). I mostly just like drawing cool clothes
nice
my dms are open 
woah explicit material
I mean sure if you want, assuming you're an adult
Horrible
my bones are killing me
Hope you become a centenarian
this is my third vessel im cooked
enjoy being a kid
can confirm bepis made yggdrasil from the womb
we got taxes
👆
wasnt it recently
smh
bepis we said happy birthday right 
i did
mhm
i have to get you a present tomorrow
ok phew
no its fine lol
im waiting for my pay before i get you anything
dilly get yourself a tag
doctored
tagless
i'm tryna make a trigger for this enhancement to send to another joker for when the mult on this enhancement goes up but it's getting triggered every time a card with the enhancement is played regardless of being in boss blind or not
i dont know what tag to use
are you resetting the flag
any way that i can make it so jokers within the table G.GAME.chak.banned_run_keys[] render with a sticker/overlay when you view them in the collection
not entirely sure what you mean by this so probably not
I had to dig around for one of my better digital pieces since I couldn't find it on my phone. This is also the character design used for this card in my mod
very cool shader
Thanks
don't think so, what do i need to do for this?
set grass trigger to nil after the hand is played
ah yeah that fixed it thanks so much
alright ive successfully done what i needed for packs and shit thanks @daring fern for your help again
just had to go to da dump and find it
how should i trace a crash that is just instantly closing the game? no crash screen lol
Typically means infinite loop
i seeee
Not a lot of ways to run out of memory otherwise
Are you using quantum enhancements for something?
i am not
i have a few mods and my hand i'm playing doesn't really seem to be any different from what i've been playing for the last couple ante's
redownload smods and update talisman/cryptid
oh wait maybe I am misunderstanding your issue
i am not using talisman or cryptid
you crash when playing cards?
yes but this wasn't occuring just a moment ago with essentially the same hand
i think the only thing different might be the boss blind hmm
ah no it wasn't the boss blind
i guess i should manually figure out what the crash it? there's nothing in logs or i checked in the wrong place :c
If it only started happening a moment ago, what's the most recent code you changed?
i haven't changed code in these mods, they are not mine
i just needed debugging help so i asked here
Oh, I see
what are the shader keys for the default balatro shaders that i can use in the edition 'key' parameter
foil, holo, polychrome, hologram, booster, debuff, voucher, negative, negative_shine
Sorry I was in class but I’m glad you got it fixed
ty
no worries thanks for your input!
how to do effects at end of ante?
Check for end of round and boss blind
woah
that is new right
Lmaooo
how do I make SMODS.destroy_cards(SMODS.find_card('j_[prefix]_key')) bypass eternal stickers?
Hey N
hi
Is there some SMODS.x that still needs documentations
I’ll check myself
is there a way to set a rarity text color to a hex color?
how would I handle that in this instance?
how does deck.cards work in challenge definition? i might be stupid but i dont quite get the control tables explanation
where is a card's calc_dollar_bonus stored?
Card:calculate_dollar_bonus(), with the SMODS custom function it calls being SMODS.Center:calc_dollar_bonus() if it's defined on the item
neither of these handle adding it to the cashout right? because i only need the number it returns
If you need the number it returns you just call it directly
alright nice
The actual round eval behavior is handled by eval_round() and a UI function I can't remember the exact name of thats something like add_round_eval_row(type)
...
add_round_eval_row({dollars = ret, bonus = true, name='joker'..i, pitch = pitch, card = _card})
...
trying to make a custom class but it seems like it failed to inject stuff, G.P_QUESTS was completely empty
G.P_QUESTS = {}
-- maximum quest difficulty
AF_Mod.max_difficulty = 3
-- class definition
AF_Mod.Quests = {}
AF_Mod.Quest = SMODS.GameObject:extend({
obj_table = AF_Mod.Quests,
obj_buffer = {},
vars = {},
config = {},
set = "Quests",
class_prefix = "qst",
required_params = {
"key", "atlas", "pos"
},
difficulty = 1,
get_obj = function(self, key) return G.P_QUESTS[key] end,
register = function(self)
self.name = self.name or self.key
self.difficulty = AF_Mod.clamp(self.difficulty, 1, AF_Mod.max_difficulty)
AF_Mod.Quest.super.register(self)
end,
inject = function(self)
G.P_QUESTS[self.key] = self
end,
delete = function(self)
G.P_QUESTS[self.key] = nil
local j
for i, v in ipairs(self.obj_buffer) do
if v == self.key then j = i end
end
if j then table.remove(self.obj_buffer, j) end
self = nil
return true
end,
-- TODO: use whatever the fuck SMODS.Center does
process_loc_text = function(self)
SMODS.process_loc_text(G.localization.descriptions.Quest, self.key, self.loc_txt, "name")
-- SMODS.process_loc_text(G.localization.descriptions.Quest, self.key, self.loc_txt, "text")
end,
calculate = AF_Mod.noop,
completed = AF_Mod.returnTrue,
-- misc. fields
reward = nil,
curse = nil,
})
-- Calculate shouldn't return anything under most circumstances
function AF_Mod.Quest:calculate(context, key)
return G.P_QUESTS[key]:calculate(context)
end
function AF_Mod.Quest:completed(key)
return G.P_QUESTS[key]:completed()
end
AF_Mod.Quest({
name = "avoid",
key = "avoid",
atlas = "quests",
pos = {x = 0, y = 0},
difficulty = 2,
config = {
poker_hand = "Pair",
was_played = false,
},
loc_vars = function(self, info_queue, card)
-- make this return poker hand stuff
end,
completed = function(self)
return not self.config.was_played
end,
calculate = function(self, context)
print("Calc")
if context.before and context.cardarea == G.individual and context.poker_hands[self.config.poker_hand] then
self.config.was_played = true
AF_Mod.kill_you()
end
end
})
anyone know what the issue might be
wait nvm
i never loaded the file containing the quest
😃
is there a way for me to reference the price of playing cards in the shop?
is it possible to dynamically change the cost of a consumableType ? (a.e cost of a card from this set goes up by 5 for every card bought from the set)
Yes
There’s a mod that has this feature for a joker but i forgot what it is
Definitely possible
fair enough, but im asking if theres a simple method or smth im overlooking before i engage with jank
hey is there a blank mod template somewhere?
pins dont have anything and id like a good place to start
hook set_cost
was already planning on doing that if there wasnt a method i overlooked, but thank you nonetheless
a blank mod template is an empty file :p
this might help https://github.com/nh6574/VanillaRemade/wiki#4-basic-mod
well no a blank mod template is the framework of a json file :P
true
"description": "This is my really cool balatro mod. It has XChips and Reverse Tarots."
😭
"i'll have, uhh... xchips"
"how original"
"with reverse tarots"
"daring today, aren't we?"
i hate that images load half the time
oh no im 50% this its over
This might be a dumb question, but can i code mods in python?
does no_message in scale_card also override any custom messages?
no the game is in lua
yes
it wont play any message on your card
however i managed to mod the game from only python knowledge so it should be pretty doable with that imo
because lua is very similar
i should make this the entropy mod description instead
my mod has like 25% of this because it only has xchips if you have another mod that adds xchips so i think im not cooked
Ok, i want to do a discord presence bot that displays my jokers and the blind/ante i'm at, but this is going to be my first project ever, and i have no idea on how to start
idfk how discord rich presence works at all
or how discord presence works at all internally
is there any "vanilla+" mod that doesn't have XChips 😭
is this fine or is it too confusing?
you dont need scaling message here do you
yeah you do
message_key = "a_mult" works doesnt it?
it's a custom value
or something like that
no because dagger is wierd
damn
and shows its new total value
i can also do this
you'd need it anyway because its 2 x cost
I think dagger is a bad example for how to use scaling
i would put it in every scaling card
it hits every mark for how things are usually not handled
oh this is for the actual code not the wiki
hmmm
:jimbo_spin:
hi aure!!
hello
how would i even do the food joker thing where they dont scale or show a message if the next scale would make the value be below 0/1 or something. if i just do the thing that the current vremade food jokers do it wouldnt account for the possibility of scaling modifications changing if it should be destroyed or not
hello modding people
i am in fact modding
lets go with this for now because it's easier and I'll change it if people dont like it
if i wanted to add a variable that persists during the current game could i just do G.GAME.[whatever] = [whatever]?
yes
yippie
guys don't forget to update your SMODS again
is creating a context as simple as just hooking a function and calling SMODS.calculate_context in it?
pretty much yeah
thats awesome actually
there's a bit more work you have to do if you want to be able to return anything (and i'm not fully sure how that works, i just fucked around until it did what i wanted for my contexts), but yea if you don't need to return anything in the context it's that easy
that's not entirely true
all the standard calculation returns will be handled just fine
oh right sorry, yea i was referring to custom returns (i set up contexts to modify dice rolls like you can modify probability, and trigger dice rerolls)
i imagine it has something to do with the return_table parameter in calculate_context but thats all im getting out of it
iirc the documentation said there were maybe two different ways to do it but only the return_table parameter worked for me
theres documentation for it?
I don't think it was a wiki page, possible I was just looking at the code or maybe some comments in the code
thats just for scoring returns though i imagine
nope
okay the return table is literally just returned from calculate_context apparently
thats good
what does that mean I just update steamodded
something in your lovely patches is out of order. did you delete the old steamodded before putting in the updated folder?
yeah like everytime I update Steamodded
have you updated your other mods?
might be that something broke from the smods update. Try removing mods to see what's failing and see if you can update it
I update all of these mods
I'm pretty sure its not from Giga, All-In-Jest and Cryptid
This is my first time creating a custom edition, how do I make it so it just has no edition?
nvm got it
does SMODS.find_card just look for the card at all?
or does it also check for whether the card is debuffed?
if you have the specified joker, but it's debuffed, would find_card return true, or false?
try it and see
does balatro not support .mp3 files
it supports oggs
use them (they are more efficient)
alright
iirc it's just wav and ogg
according to smods docs, mp3 is supported but not recommended. iirc i copied that from the old sound docs which were made by Steamo + i never tested it myself. so no guarantee there
it does check, it has an argument to not check
hm. i don't think i did adding a new hand right
(mousing over it just crashes the game)
i'm trying to load them with love but it doesn't work for some reason . i'll troubleshoot it more
crashlog
did i fuck shit up with the hand def or with the lang?
that seems to be the localization
how do you make a deck start you with a specific joker?
did you read any deck docs
there's also the magic deck example
Idk how but removing PTA and doing CTRL+Z correct everything
here's my default localization json's contents, what did i fuck up?
descriptions = {
misc = {
poker_hands = {
vtude_fullhome = 'Full Home'
},
poker_hand_descriptions = {
vtude_fullhome = {
"5 cards with at least 3 different ranks of {C:attention}4{}, {C:attention}1{} or {C:attention}3{}",
"{C:inactive}(Must be enabled by an ability)"
}
}
}
}
}```
can i see the code for the poker hand
https://github.com/nh6574/VanillaRemade/wiki#what-are-optional-features curious question about the quantum_enhancements, is there a way to make a joker that enables it (and disables when removed or debuffed) and is it like where you can add several enhancements?
hand itself probably doesn't work yet as i'm still actively working on it
key = "vtude_fullhome",
chips = 80,
mult = 8,
l_chips = 35,
l_mult = 4,
visible = true,
example = {
{ 'S_4', true },
{ 'H_1', true },
{ 'D_1', true },
{ 'S_3', true },
{ 'C_3', true },
},
evaluate = function(hand)
if #hand < 5 then
return {}
end
if not SMODS.find_card("j_vtude_scratchedjoker") then
return {}
end
local candidates = { [4] = {}, [1] = {}, [3] = {}}
for _, card in ipairs(hand) do
local id = card:get_id()
if id == 4 or id == 1 or id == 3 then
table.insert(candidates[id], card)
end
end
local available_ranks = {}
for rank, cards_list in pairs(candidates) do
if #cards_list > 0 then
table.insert(available_ranks, rank)
end
end
local total_ranks = #available_ranks
if total_ranks < 3 then
return {}
end
return {hand}
end
})```
is your prefix vtude
yes
are you sure
not relevant but it should be if not next(SMODS.find_card("j_vtude_scratchedjoker")) then
(visible being true is also temporary for debugging the lang issue, as well)
what's the name of the file
which file?
the one i replied to, the localization
path for lang is /localization/default/en_us.lua
oh i didnt reply to that one lmao
that's wrong
ah
what should it be?
it should be localization/en-us.lua
hand still displays as “ERROR” and crashes when moused over
has anybody got the .fs files for the shaders that balatro uses?
or is that just in the source code and i can look myself or what
game files
is the lang file itself malformed or something?
did i format it wrong
is it now in localization/en-us.lua
for the first time ever i will have to go into balatro source code
yeah it is
can you take a screenshot of the file structure
i yhink i have some commented shaders if you want them
that would be wonderful
no idea, it looks fine to me
do i need to point to it in my mod json or something
no
am i allowed to put these .fs files in jokerforge in some way. i want the jokerforge shader editor to get presets from base balatro, idk if that is considered piracy or not lol. its not like i am sharing the code directly to the user but it will be in the codebase
are you sure i formatted it right?
Theremst me.
i think sharing those files entirely might be too much
yeah if its on the github it might cause worry
i will burn that bridge when i get to it
misc shouldnt be inside descriptions
hm
i take it aces are not 1 then in the example card format
ace is A
how do existing contexts (like mod_probability) handle getting multiple of the same return value from different jokers (or other things)
the last one takes priority usually
for those contexts, the result of the previous one is changed in the context
it works!
okay now for making sure the hand actually works when played, i'll see you when i have more problems
yeah they weren't commented give me a minute jayden lol
no worries lol
okay damn it still does not actually play....
guess i've got more to do on the code side of things
Can I use other mod's atlases?
you can
if it exists and it's loaded
you would have to disable the automatic atlas mod prefix in prefix_config and then add the mod prefix manually though
what happens if the target pattern for a patch exists multiple times in a single file? will it only apply to the first instance, or to every instance of the pattern?
hey uh
i'm having issues with my booster pack
the actual item is named correctly
but when you open it up
i think group_name should be elsewhere if youre using a localization file
hm?
apparently it has to be in misc.dictionary under the pack's group_key
so like
misc.dictionary.p_shark_spell_normal.group_name?
wait fuck i think i know why this isn't working its because of the card:get_id()
what does card:get_id() return for aces?
im guessing it's not 1
or just misc.dictionary.spell_normal.group_name
misc.dictionary[group_key]
14 i think
@vast bough start by extra.fs
ah. is there a related get_rank that would proc on both aces, and stuff like unstable's 1 rank? or something else along those lines
nope
you are the goat
you can get a rank directly with card.base.value
or exists for exactly this reason
just check if its an ace or unstable 1
?
whats that return for aces though
N im ngl you need a nice personal website instead of a card
can i see your pack code
because im guessing its not 1
buy me a domaine jayden
/j
get_id is 14 base.value is "Ace" iirc
i will buy s.com
there's the key but there's also the different key that's returned in loc_vars
you should have a group_key in your pack definition
i just bought my domain because it was cheap
yeah jaydchw.com was like a tenner a year its not bad
and what should that be
just
spell_normal
it can be whatever you want, but youll probably be reusing it across all packs of the same type
same
and then to get the group name text in the game you just need misc.dictionary.<group_key> in your localization
okay cool
sell it to me half off
now completely unrelated - how on EARTH do you add a sticker to a joker
only thing i can think of is set_badge but idk how to use that
namely eternal
i will let you have half of it
:set_sticker
card:set_sticker("eternal") should work
:set_eternal also but idk if thats recommended now
oh wait i think it's add_sticker
uh how do i turn on debug mode or whatever to see my own debug print statements
whats that for
DebugPlus
shaders?
it's the rarity and mod names at the bottom of the card
and i assume the opposite is remove_sticker
yes
bump
ohh okay
whatr im looking for is info queue right
every
okay
there's a times parameter
yes
flipside shaders i gave to jayden to reference
i dont mind pings btw sometimes i will nott see things , but yuh, ty
if i want it to apply to each one i should just not have a times parameter right?
hey chat. long time no see. i've been wondering why my toggle dosen't save when changing screens or restarting. does anyone know? i've now read the ui page thrice and im still stumped :/
create_toggle { col = true, label = "", scale = 1, w = 0, shadow = true, ref_table = reddit_config, ref_value = args.ref_value },
okay how the hell are none of these debug prints triggering
key = "vtude_fullhome",
chips = 80,
mult = 8,
l_chips = 35,
l_mult = 4,
visible = true,
example = {
{ 'S_4', true },
{ 'H_A', true },
{ 'C_A', true },
{ 'S_3', true },
{ 'C_3', true },
},
evaluate = function(hand)
if #hand < 5 then
return {}
end
if not next(SMODS.find_card("j_vtude_scratchedjoker")) then
print("SCRATCHED JOKER NOT FOUND!")
return {}
end
local candidates = { [4] = {}, [14] = {}, [3] = {}}
for _, card in ipairs(hand) do
local id = card:get_id()
if id == 4 or id == 14 or id == 3 then
table.insert(candidates[id], card)
end
end
local available_ranks = {}
for rank, cards_list in pairs(candidates) do
if #cards_list > 0 then
table.insert(available_ranks, rank)
end
end
print("FULL HOME RANKS FOUND ARE " .. available_ranks)
local total_ranks = #available_ranks
if total_ranks < 3 then
return {}
end
return {hand}
end
})```
theres just
nothing in the log at all
oh i just have them off by default sorry
(yes i know that right now this would detect too much stuff i'll work on that once the hand actaully works)
I have a question about shader cuz I was trying to make one that makes the color golden and it then it goes to green
vec4 effect(vec4 colour, Image texture, vec2 texture_coords, vec2 screen_coords) {
this is where I would change the colours?
And do I need a dissolve mask function or I can just change the color since It's a simple shader
You got me curious
the hand shows up in the run info menu so why isnt the evaluate ever running??
evaluate = function(parts, hand)
yes you need the dissolve but you can just copy it
get a weirder username
oh is the whole part thing mandatory
ok thanks
do i have to split it off into its own function
wait does this mean i do have to code in the animation or
is only the function to shift the color needed and dissolve mask and the main effect function or is there other ones too btw
you can reference from the shaders i sent and the examples in smods
no, the function signature needs to be the same or parts will be treated as hand
Good idea but I think it's too late for me
ah
what's args.ref_value
ok good news it actually ran it bad news i did the ol compare number to table thing again my debug print statement crashes 😭
should have directly sent everything. it's a string
local create_config_toggle = function(args)
return {
n = G.UIT.R,
config = { align = "cl", padding = 0 },
nodes = {
{
n = G.UIT.C,
config = { align = "cl", padding = 0.05 },
nodes = {
create_toggle { col = true, label = "", scale = 1, w = 0, shadow = true, ref_table = reddit_config, ref_value = args.ref_value },
}
},
{
n = G.UIT.C,
config = { align = "c", padding = 0 },
nodes = {
{ n = G.UIT.T, config = { text = localize(args.translate), scale = 0.45, colour = G.C.UI.TEXT_LIGHT } },
}
},
}
}
end
SMODS.current_mod.config_tab = function()
return {
n = G.UIT.ROOT,
config = {
align = "m", r = 0.1, padding = 0.1, colour = G.C.BLACK, minw = 8, minh = 6
},
nodes = {
-- Rectangle???
{ n = G.UIT.R, config = { align = "cl", padding = 0, minh = 0.1 }, nodes = {} },
-- Bonanza Packs
create_config_toggle({ ref_value = 'enable_bonanza_packs', translate = 'b_reddit_enable_bonanza_packs' }),
-- Joker Overrides
create_config_toggle({ ref_value = 'enable_joker_overrides', translate = 'b_reddit_enable_joker_overrides' }),
-- Joker Overrides
create_config_toggle({ ref_value = 'enable_dev_jokers', translate = 'b_reddit_enable_dev_jokers' })
}
}
end
coding in the animation isnt too hard, theres a lot of pre-existing functions for animations. Card:juice_up is probably the one you want though since thats the basic jiggle animation
whats the sound i gotta play for adding the sticker
and im guessing reddit_config is SMODS.current_mod.config?
no idea
idk, theres no sound specifically for it in vanilla, i'd just try some sounds and find one you like
actually. my stupidity. the error wasent in syntax but the scope
i did not know that actually
okay cool i dont know what I'm doing
it didn't add the sticker lmao
gold_seal
oh wait
whats a sticker?
here's my code i gotta go
i thought yall were talking about seals
i have discovered that i think it is practically impossible to render love2d shaders natively in web
it works...
you are making shader forge????