#💻・modding-dev
1 messages · Page 474 of 1
Yeah you can do that
the sell button updates states but the shed doe- oh my god is it the state function
do i need it after all
I would say look for the vanilla code for a number of the transformation Tarot's or whatnot because I believe those deselect automatically after they're done
That said yeah you could use the state function for this if you really wanted
But honestly not recommended since you want to get rid of the entire button
ok thank goodness
If it had a transform back function, then you'd probably use it
it will not
I would look it up but I'm not on my PC to have the source code handy
Err
Wait let me look up the Cardsauce repo
i mean i have the source up i just need to know where to look lmao
would it be the defs or just ui.lua
okay i decided im scrapping the "seal that discards the card to the right of it when it's discarded" idea for now. i may come back to it in the future when i have a better understanding of the balatro code
now to come up with a new seal idea...
Call G.jokers:unhighlight_all() after the transformation code
oh that is the most obvious name ever okay
after the eventchain but before the return true, right?
it's a chain of E_MANAGER events, but here's the last one
i should start sending these messages with pictures more
You could possibly unhighlight before the flip events and it would look better?
you guys arent magicians lmfao
Since it's not gonna flip with the UI then
oh i just meant like functionality but yeah i can def do that easily
since i have the event that goes before the flips anyway, i can just slide that in here
i've a video to illustrate the issue i got, which i don't even get it since it's literally took from Vanilla's remade but modified to work on the scoring hands
oh hey deltarune theme- oh except specifically that guy i guess
its too clean, thats the problem
b-side mentioned 🗣️
no i just have no idea what game the club king is from (and why specifically the club king lmfao)
Tenna is just too goated for his own good
chapters 3 and 4 deltarune
do you play deltarune or got the intention too ?
cuz
spoilers
Oh yeah Deltarune I'm gonna play it soon

Gonna be annoyed at Tenna when I get to Ch 3 though
now im forever gonna wonder who tf that is until i finally play it
oh boi, jumpscare for it lmao when it'll happen
impossible, he's too funny to be annoyed with
i already know tenna cause that guy been around since sweepstakes
Also for some reason the issue got somewhat even more confusin it doesn't even flip twice again it just rank up AGAIN
He's a Tumblr sexyman. I am annoyed by Tumblr sexyman by default
Every time a sexyman drops, I am reminded how much Tumblr (and also everyone else) doesn't care about women
why not have a table that adds the first 3 played cards it and then the rank up only updates the cards in that table?
or you know social media in general
Yeah
probably i should that, but that doesn't explain still why the cards rank up Twice
like i legit don't get why, it shouldn't do that
and i tried blocking some parts of the code and it jsut doesn't make it better
jedi it's right there
ope
granted it IS a lua file so if youre on mobile i apologize
just there
where context check
?
you need a specific context, cardarea is too generic
wouldn't G.play work ?
no, there are multiple contexts with cardarea == G.play
basically, there are contexts and contexts attributes: cardarea is an attribute, youre missing the main context
it needs to be one of the ones listed here https://github.com/Steamodded/smods/wiki/Calculate-Functions
context.cardarea == G.play is like a "this manner specifically" attribute for an certain existing contexts
ahhh okay
what have you done
killed kitty

as i said i just retook from the VanillaRemade and edited it a bit, I DID tired using context.before so the cards would change before scoring
...then i just realise now i did that but in the same if line and not before
shit
i'll go test
good thing john remade came to save you
and also look about it for the calculate as well
Yeeeep
got a lot of saves from my jokers
I'm still dying trying to solve this dumb button I want
im glad mine works now
now i dont ever have to do it again
now the card is being drawn in the middle of the screen and never leaving
hi 1up
what did you used for spawning the card ?
i know i had that issue before and using SMODS.add_card{ fixed taht
it was there but also non existing
don't mind the print statement at the top
so this function is being called, and I modeled it after the use_consumable function
I think there might be something wrong with the line:
SMODS.calculate_context({ using_consumeable = true, consumeable = card, area = G.jokers })
since Jokers aren't consumables, but I don't know what I'd replace it with
Bump
For clarification, clicking the button just changes a boolean, it doesn't actually do anything to the size
Or it shouldn't
I have no idea why it does or what the process is behind that
so this allows me to buy memory joker even with 5/5 jokers, but it still calls alrt_no_space any ideas?
youre missing the part it destroys the consumable
i have it like that in my mod so its not that
heres how i did it
https://github.com/nh6574/JoyousSpring/blob/c0a24f9ba7e75f51d8ec09f22f12329c7a837cca/src/pendulum.lua#L79
so like card:destroy() after the line I mentioned?
remove it?
ok it's not staying in the middle anymore, but I also don't want it to be destroyed if I can manage that
oh sorry i get it
call the function in the else when you return
not before
you want it to go back?
yeah, basically you can activate the card occasionally on a cooldown
then replace that for G.jokers:emplace(card)
Hello friends and pals
I tried that before, it stays stuck in the middle
any idea why the way i had it didnt work?
because you were calling the function at the beginning so the original calls alert no space before it runs your code
ahh, so return a table like this? return {false, alert_no_space(params)}
function G.FUNCS.check_for_buy_space(card)
local ret = cfbs(card)
if card.config.center.key == 'j_tac_herald' then
if G.jokers.config.card_limit > G.jokers.config.card_count + 1 then
return true
else
alert_no_space(card, card.ability.consumeable and G.consumeables or G.jokers)
return false
end
elseif card.config.center.key == 'j_tac_memory' then
if 1 == 1 then
return true
else
alert_no_space(card, card.ability.consumeable and G.consumeables or G.jokers)
return false
end
else
return ret
end
end```
okay ill give it a try!
this worked for me draw_card(G.play, G.jokers, 1, 'up', true, card, nil, false)
without the emplace
this worked!
ok yeah that was it
In the end i just had to add a simple context.indvidual and now it seems to trigger properly even though it does score right after their previous rank now, i might rework on this a bit but at least it's working more properly, thanks !!
but it still resulted in one of the most confusing bugs I've ever seen in any kind of code:
gotcha gotcha
also i suppose from what i see there's no way to make a context.after/before to change the played cards before scoring ? Since context.individual seems to be the only one that does work
I used it in one of my Jokers
for my other mod
oh ? i tried to use it but it wouldn't do anything, it'll only rank up and everything with context.individual only
if context.after then
local _suit = pseudorandom_element({"Spades", "Hearts", "Clubs", "Diamonds"}, pseudoseed("err"))
local _rank = math.random(2, 14)
for i = 1, #context.scoring_hand do
G.E_MANAGER:add_event(Event({trigger = "after", delay = 0.1, func = function()
local _card = context.scoring_hand[i]
_card:flip()
local suit_prefix = string.sub(_suit, 1, 1).."_"
local rank_suffix = _rank
if rank_suffix < 10 then rank_suffix = tostring(rank_suffix)
elseif rank_suffix == 10 then rank_suffix = "T"
elseif rank_suffix == 11 then rank_suffix = "J"
elseif rank_suffix == 12 then rank_suffix = "Q"
elseif rank_suffix == 13 then rank_suffix = "K"
elseif rank_suffix == 14 then rank_suffix = "A"
end
_card:set_base(G.P_CARDS[suit_prefix..rank_suffix])
_card:flip()
return true end }))
end
delay(1.5)
end
this works fine for me
granted, this uniformly randomizes the suit and rank, so its a bit simpler
if you don't want that then maybe try the individual approach
maybe i should still check about it, as far as i see you definitely simplified the thing, it's only a context after, no individual or anything, just the cotext scoring hand for afterwards
maybe i'll test it out later on
appreciate the help thanks
can challenge jokers start with rental like they do eternal?
yeah after and individual dont happen at the same time, if you had a cardarea check that might also have been the problem
that explain a lot more, still gotta get used to the for i = ^part too
no
(without doing it yourself with a patch/hook)
am i doing this right? the joker's effect involves destroying face cards, and face cards get destroyed once you acquire it. will doing this have it factor in the cards it destroyed when it was taken?
(it being the calc context, that's the new thing)
i think destroy_cards does it automatically
Yeah
but if it doesnt you also need to pass the cards to the context
i thought it would too, but the card's values didnt increase
Perhaps your calculate code is a little off?
how could i patch into the smods class to allow rental to be a valid var for jokers
it might be called before it's in the joker slot
Oh yeah that's true
Add to deck is called before the card is in the proper location
cardarea check should fix maybe?
(which is annoying)
Typically card creation calls it before it calls the CardArea:emplace
For
Reasons
what can i do then? is it just impossible, or so complicated that you might as well just cope
you can just copy the calculate code into add to deck
what does patches.regex do? ive only used .pattern thus far
same thing but it takes regex
i forgot... the most obvious thing... im too used to doing mental rocket science
ok so i am trying to make a joker like faceless joker and i am using vanilla remade as a guide, but i want it to work with steel cards instead of face cards, how can i detect facecards? i tried using is_steel and m_steel, am i doing something wrong?
SMODS.has_enhancement(playing_card, "m_steel")
yess thank you
for _, playing_card in pairs(G.playing_cards) do
if SMODS.has_enhancement(playing_card, 'm_steel') then
steel_tally = steel_tally + 1 end
end
also this if you wanna tally them steel style
thanks so much for the quick help you two i appreciate it !
Such helpful pals
make sure you check for the existence of G.playing_cards and that tally variable is local as well
(you dont need to do the former if it's in calculate)
hi dilly
Am i doing this right (for temporary hands/discards?) Also how do i use pseduorandom?
wait what about the message though? you cant return in add_to_deck
wait actually no easy fix disregard
does anyone know what the keyword for playing cards would be here?
or if there is one at all

- yes
- what you have but you need to divide G.GAME.probabilities.normal / odds
so G.GAME.probabilities.normal /2 for 1 in 2
is there a global "all Jokers" pool that includes the legendaries too
or something like that
ooh, and i just realised the string for pseduorandom is the seed. Thank you!
set == "Base" or set == "Enhanced"
you can also check for card.base.name
for what
so this should in theory work?
i think so yes
buh
like there's a pool for what can appear in the shop or in arcana packs for example, I just want to know if there's a pool that contains every Joker or if I have to make it myself
G.P_CENTER_POOLS.Joker
oh its without the s
ah
its supposed to replace serpent naneinf
try :set_rental(true)?
actually what does context.removed use so i can put that instead
cause obv i cant use a context in atd
although, now that I think about it, how does this interact with blinds that hide cards? since the "remaining cards in deck" doesn't update when you draw a face-down card?
btw is there any documentation for how to create a custom Deck? i want to make a deck that forces the shop to have only jokers of one kind of rarity, is that something that can be done?
it an array of the destroyed cards
but also they have mini tutorials/examples in their example mod
is back another word for deck? i saw this but got confused
https://github.com/nh6574/VanillaRemade/blob/599f32c1caeee6f17e64d849c36768435f77d418/src/backs.lua
alternatively n remade the backs with a coat of less-thunk paint
I was gonna say remade was probably the wave
ohhhh thank you so much ! ill look through that
is it just removed_cards?
do you know what would be the best vanilla deck to look at for what i am trying to make?
maybe hex deck is there any other that changes how the shop works?
or ghost deck i mean
it couldn't stop for ace cards cuz it crashed as the other_card thing, but it does now work, i do notice the score still remain the same so i'll change it to a context.after, but thanks again for the help
oh and i didn't even needed the for i = part too since it was already state already lmao
probably ghost deck? cant think of how itd work off the top of my head, but you could try?
thank you !
how do i reload the colors i added? rn i have this code
G.C.EF = {
PLANT = HEX('FFFFFFFF')--HEX("FF2BE725"),
}
local loc_colour_ref = loc_colour
---@diagnostic disable-next-line: lowercase-global
function loc_colour(_c, _default)
if not G.ARGS.LOC_COLOURS then
loc_colour_ref()
end
G.ARGS.LOC_COLOURS.ef_plant = G.C.EF.PLANT
return loc_colour_ref(_c, _default)
end
and it doesn't seem to update after everything i tried.
rn i tried:
-closing and opening the game
-disabling and enabling the mod
-restarting the pc
no, there's no place theyre stored, you need to make it yourself
or just check ccard
that looks fine for me
are you sure youre loading the file
on first load it was set as the dark green and when i wanted to make it darker it stopped refreshing
oh
this should work right?
it takes a 6 letter hex
wait do i change removed_card to ccard actually
i think you can use 8 but the alpha is at the end? not sure
i would remove that loop and do that yeah
i used the color picker in vscode and didnt connect the dots
guys its so close to working
the cards are just a bit funky, I don't think they're actually being replaced as shop cards
ok there
2 things, you dont need to check if its a face twice
youre declaring face_card inside the first if so it wont exist in the second
actually i think the problem was something else entirely. i have a rarity named plant... It seems to make it a color by itself and because that file is loaded later it overrode the colors.lua file
oh yeah
How can I add a card to the player's consumable area
just noticed lmao
which card
whats up modding gang
still dying. I have chili and tortilla chips now though
just noticed that most of people in this channel have a balatro mod link in their bio
i do not
I'm gonna go get Panda Express here in a minute bc I'm hungry
does anybody know how to add an enchacement to a card? for editions is "Card:set_edition" but how do you do that for an enchacement?
Card:set_ability()
Pass in the enhancement center, i.e. G.P_CENTERS['key'], though you can also pass in the key directly if you want and it'll parse it
I've probably spent like half the money I made last semester at Panda
Cryptid
Honestly, as is your right
That spectral card
yeah i was looking at that but i don't understand what any of these arguments mean set_ability(self, card, initial, delay_sprites)
i just want to set the enchacement to a steel card if that's possible
card:set_ability("m_steel")
initial is for the first run of set_ability when its created and delay sprites is to delay sprites during scoring (mostly)
Is there a way to set a “default” for a given pool? For example, a pool of every sin joker that defaults to Wrathful if you try to summon another.
use = function(self, card, area, copier)
if G.STATE == G.STATES.SHOP then
for i = 1, #G.shop_jokers.cards do
local _card = G.shop_jokers.cards[i]
if _card.config.center.set == "Joker" then
_card = create_card("Joker", G.shop_jokers, nil, nil, nil, nil, nil, "reroll_shop")
create_shop_card_ui(_card, "Joker", G.shop_jokers)
end
end
end
end,
I'm trying to do a manual shop reroll but I'm missing something
the cards that I create aren't actually being placed in the shop I don't think
It takes a center, not a card
card:set_ability(G.P_CENTERS.m_steel)
yes, there's a field for that in SMODS.ObjectType
hey guys how do i set a card to be a small playing card pack
What is it?
or a key
self is implicitly passed from the object calling the function when you use a colon in the function call
default is in the docs
And yes both work
specifically im trying to set a card to standard_normal_1
ummmm not what i was expecting💀 i want it to work like certificate but it gives you a random steel card, but it just turned the joker into steel ```calculate = function(self, card, context)
if context.first_hand_drawn then
G.E_MANAGER:add_event(Event({
func = function()
local _card = create_playing_card({
front = pseudorandom_element(G.P_CARDS, pseudoseed('cert_fr')),
center = G.P_CENTERS.c_base}, G.hand, nil, nil, {G.C.SECONDARY_SET.Enhanced})
card:set_ability(G.P_CENTERS.m_steel)
G.GAME.blind:debuff_card(_card)
G.hand:sort()
return true
end}))
playing_card_joker_effects({true})
end
end``` here's the current code i have
steel joker 😭
steel edition Joker when
card in that code should be _card
can you have a joker create the plasma deck affect in a deck that isnt plasma deck? are there any examples i can look at for this? i kinda want to make a joker that does that
Whatever the object you're calling the function from (card is a standin) should be whatever you want to put the enhancement on. card in that code is the Joker, passed in as a parameter to calculate. _card is your playing card, so use that instead
calculate = function(self, card, context)
if G.GAME.selected_back:get_name() == "Plasma Deck" then
if context.joker_main then
return {
x_mult = card.ability.extra.Xmult
}
end
else
if context.final_scoring_step then
return {
balance = true
}
end
end
end
yeah that was it thank you guys so much!
just sending the link N' mentioned
ignore the first part, the final_scoring_step is the important part
bump
yes
sick
how do i set a card to a standard_normal_1 with set_ability
using "p_standard_normal_1" works
but you need additional logic for it to actually work as a pack
why does this add the card basically when playing but the message only appears in the main joker scoring timer? if context.joker_main and next(context.poker_hands["Pair"]) then return { message = "M", card = self }, SMODS.add_card{key = "c_cryptid"} i want the card to be added at the same time as the message, so when the joker is supossed to be scoring
i think that this would crash if its the actual code
but anyway, do it inside an event
it doesn't crash, but adds the cryptid card way before the message appears
yeah you need to put the add_card line in an event
how? sorry im not very good at modding still
Is there a way to detect how many different poker hands have been played?
something like this https://github.com/nh6574/VanillaRemade/blob/975e35dce07617c7a9db01ce032152b07e4f0f2f/src/jokers.lua#L1409
yes, check how obelisk checks for the most played, all of them have a played field
Oh, thank you!
ok it's perfect now, thanks again!
also quick question, if i don't specify the cost of a joker does it automatically choose the price based on rairity?
no, it has a default
it should be in the docs what it is but i think it's the price of jimbo
i apologize for another basic question but i can't find any info on how to get the mod name below the rarity
that space is there by default and it's bugging me lol
Did you not fill in the mod badge info in your metadata?
so what does that "additional logic" happen to entail
no idea :3
is there a way to change the color?
alright
any name ideas?
deadly laser
22 AM?
I tried to make it dynamic by function and IG it failed miserably
how can i make a suit not appear in playing card booster packs? or in any pool at all?
Sunshine
use the in_pool function
and what do i put to not appear in any pool? just a random thing?
return false
like "in_pool = false"?
no it's a function
in_pool = function(self)
return false
end
Bump 
photosynthesis
22 AM?
yeah a few people from other server said the same
@thorn furnace
don't question it
there's a blind for my mod that's just "+4 blind requirement" but it only displayed once you entered the blind. i asked somethingcom about this and was told to look at the clock, and tried this
SMODS.Blind {
key = "joker",
name = "Joker",
pos = { x = 0, y = 0 },
boss = { min = 1, max = 10 },
atlas = "blind",
mult = 1,
cry_ante_base_mod = function(self, dt)
return 4
end,
boss_colour = HEX("f7343e"),
crp_credits = {
idea = { "Unknown" },
code = { "ScarredOut", "Glitchkat10" }
}
}
it instead increases the blind size a ton like every second
(my mod is a cryptid addon btw)
Could just use 24 hour time
in that case 22:00 would be 10PM
the Joker that actively punishes players for being gaming goblins
i still can see the sun and it's 11PM
what 😭
when does the sun rise for you
it depends on how far north of the equator you are. Some days in upper Canada have like 18 hours of sunlight
yeah i mean i live in az usa and sun rises at like 5 and falls at (again) like ~6 7
why does this trigger twice? instead of the xmult going from 2->4->8 it goes from 2->8->32
I think if ur living that far north in yukon u probably dont have a computer 
not a functioning one anyway
More common in south america
Theres even some places in south america with a 24 hour sun
Is there a way to get the last chips and mult scored in calculate before that card is scored?
/gamerule doDaylightCycle false type shit
bumper bump bumpington
hand_chips and mult are globals
actually i wanted to make it end at 8pm but changed it for testing
idk anything about how cryptid works but by context clues I can assume that you only want to return 4 once
pretty much
have a variable somewhere that checks if it already returned
so just like
...
jok = false,
cry_ante_base_mod = function(self, dt)
if not self.jok then
self.jok = true
return 4
end
return 0
end,
...
yeah
but maybe not on self because thats the definition
figured it out its cause im setting scoredrank to other_card
overwrites itself
so it factors twice
wtf do editions not have a calculate field?
they do; this is the calculate area for one of my mod's editions
...
calculate = function(self, card, context)
if
(
context.edition -- for when on jokers
and context.cardarea == G.jokers -- checks if should trigger
and card.config.trigger -- fixes double trigger
) or (
context.main_scoring -- for when on playing cards
and context.cardarea == G.play
)
then
return { eee_chips = lenient_bignum(self.config.eee_chips), eee_mult = lenient_bignum(self.config.eee_mult) }
end
if context.joker_main then
card.config.trigger = true -- context.edition triggers twice, this makes it only trigger once (only for jokers)
end
if context.after then
card.config.trigger = nil
end
end,
...
right i forgot that was on almost every object type
also reminds me that i coded it wrong
how would i go about altering the "saved by mr. bones"?
calculate = function(self, card, context)
if context.end_of_round and context.game_over and context.main_eval and not context.blueprint then
return {
saved = true,
message = "LOOOOOOL"
}
end
end
unsure if it's possible without like hooking
How do I get the number of times a voucher was claimed?
that is very sad
a specific voucher?
wait how do i make this award chips AND mult
it is, you just have to make your own localization and reference that instead, I did it for one of my cards
nvm im dumb
i figured it out
ahhh
that seems like too much work
okay i need to do that then
thank u guys regardless
calculate = function(self, card, context)
if context.end_of_round and context.game_over and context.main_eval then
G.E_MANAGER:add_event(Event({
func = function()
play_sound("tarot1")
card:start_dissolve()
return true
end
}))
return {
message = localize({
type = "variable",
key = "k_saved",
vars = { "1 Up" }
}),
colour = G.C.RED
}
end
end
okay maybe not too much effort. this is perfect
hang on
the reason i was initially annoyed is because it is for joker forge but if i get given ideal code i can write code generation based off of that
so thank u dearly
in your en-us.lua file, in the table misc.dictionary, put this k_saved = "Saved by #1#",
it won't work without that
uhhh did i do something wrong... it gave me -0 for both...
okay im back to 'this is too much effort for now'. will definitely put a pin in this though but for now it can wait until joker forge can generate localisation files properly
does this have anything to say that the player was saved? it doesn't look like it 😭
1 up
well yeah but like
also, writing it this way makes it work with any Joker as long as you pass it the text you want, you won't have to make a brand new one for everything
it doesn't look like this joker saves you at all or maybe i'm dumb
i just don't see it jimball
i will get around to it when joker forge can code gen localisation files, thank you though i will save this code for later
it does lol, I promise
no idea, looks right but never worked with editions
i mean like where because i don't see it and it might help with trying to code my thingy 😭
it just does idk lol
fair enough
😭 the first PR I've looked at seems fine but it behaves strangely with something in ortalab and I DONT KNOW WHY
which
the one that handles cards that hide the front sprites
but it might just be a general ortalab bug, I need to check
I have this code for my custom seal but for some reason it triggers for all cards discarded and not just the ones with the seal
if context.discard and context.cardarea == G.hand then
for i=1, #G.hand.highlighted do
local card = G.hand.highlighted[i]
if card.seal == 'leshys_beeswithin' then
G.E_MANAGER:add_event(Event({trigger = 'after',delay = 0.1,func = function()
SMODS.add_card({set = 'Base', area = G.hand, no_edition = true, enhancement = 'm_gold'})
return true end }))
end
end
end
end,```
okay it's just a general bug cool
Awesome, it's all finally working
nvm don't use this code lol
its bugged, I fixed it but its not well written
lmao
what is the updated version
send the calc function please (calc is short for calculate im just using slang)
one sec
(sec is short for second I'm just cool like that)
calculate = function(self, card, context)
if context.end_of_round and context.game_over and context.main_eval then
G.E_MANAGER:add_event(Event({
func = function()
play_sound("tarot1")
card:start_dissolve()
return true
end
}))
return {
saved = "ph_1_up",
message = localize("k_saved_ex"),
colour = G.C.RED
}
end
end
new version
unfortunately having a variable for the "Saved by ___" message kinda messes it up
beautiful, thank you
you still need to define misc.dictionary.<key> in your localization though if you want the correct message though
use = function(self, card, area, copier)
if G.STATE == G.STATES.SHOP then
local new_shop = {}
for i = 1, #G.shop_jokers.cards do
local _card = G.shop_jokers.cards[i]
if _card.config.center.set == "Joker" then
_card = create_card("Joker", G.shop_jokers, nil, nil, nil, nil, nil, "reroll_shop")
create_shop_card_ui(_card, "Joker", G.shop_jokers)
end
new_shop[#new_shop + 1] = _card
end
G.shop_jokers.cards = new_shop
end
end,
this is rerolling shop Jokers but they're not actually being placed into the shop, like the don't have the "Buy" button or anything, any ideas
that is a crazy bug ive never even seen that before
yeah its pretty weird hold on
and because they're not being added to the shop they stay there forever lol
hey, does anyone know how I could get the current shop size? (in terms of card slots)
G.GAME.shop.joker_max?
maybe, I'll try realq
am I passing in the wrong arguments to create_shop_card_ui()? In the definition for the function, its supposed to add a node for the buy button, but I don't think it's ever reaching it
quick question: are booster packs more rare if you put a higher number or a lower number on the "weight" value
ok nvm i have no idea why it's double gaining
is it meant to be added or multiplied by xmult_gain
why is score_passthrough nil... how do i do a custom config value
example: 1->4 (not intended) instead of 1->2 (intended)
Because it would be card.edition.score_passthrough
how can i check if played poker has been played? i have a loop but id how to check if its been played before
G.GAME.hands[context.scoring_name].played_this_round > 1
G.GAME.hands[hand].played
ok thanks
or yeah played if not just this round
make sure you have G.GAME.hands[context.scoring_name] and too so it knows if it exists
Okay so the only wrinkle left here is that when I discard two cards with this seal, it creates four gold cards instead of two but I can't tell why
if context.discard and context.cardarea == G.hand and context.other_card == card then
for i=1, #G.hand.highlighted do
local card = G.hand.highlighted[i]
if card.seal == 'leshys_beeswithin' then
G.E_MANAGER:add_event(Event({trigger = 'after',delay = 0.1,func = function()
SMODS.add_card({set = 'Base', area = G.hand, no_edition = true, enhancement = 'm_gold'})
return true end }))
end
end
end
end,```
double trigger issue twins
remove your for loop
oh ok thanks
i wish I knew but I'm just as confused as you, it looks fine
pain
ill work on it more when i get back home
Was it really that simple this whole time
how can I add a card to the shop?
what does context.main_eval do?
makes sure it's the main evaluation of the card basically
is it possible in loc_txt to use custom colors instead of attention/chips/mult etc? "{C:chips}{}"
Yes.
@red flower what's the proper way to use the new context you made for SMODS? the context.evaluate_poker_hand one
how then? like imagine i want to use a hex color, how would i format that?
You would do {V:1} then in loc_vars you would do return {vars = {colours = {HEX("HEX")}}} I think.
that did the trick, thank you!
you can also add your own colour codes
by adding them to the G.ARGS.LOC_COLOURS table
if context.evaluate_poker_hand then
local poker_hands = context.poker_hands
return {
-- It will be treated as a High Card
replace_scoring_name = "High Card",
-- It will be called Royal Straight
replace_display_name = "Royal Straight", -- or a loc key
replace_poker_hands = poker_hands
}
end
you can also return replace_poker_hands but it's a bit more complicated, basically you can do poker_hands["Flush"] = {} to remove all flushes and stuff like that so the hand doesnt contain a flush anymore
THANK YOUUU this is so helpful
oh i see thanks
basically this + poker hand visibility can recreate Mathguy's Pairs don't exist blind
wait it says in the docs that it auto adds colors based on suit's and i have a custom suit i wanna use the color of local omega_suit = SMODS.Suit{ key = "omega_suit", card_key = "O", hc_atlas = 'omega_suit', lc_atlas = 'omega_suit', hc_ui_atlas = 'omega_ui', lc_ui_atlas = 'omega_ui', hc_colour = HEX('0026FF'), lc_colour = HEX('0026FF'), pos = { y = 0 }, ui_pos = { x = 0, y = 0 }, loc_txt = { singular = "Omega", plural = "Omegas" }, in_pool = function(self) return false end } how do i do that? {C:omega_omega_suit} isn't working (omega being the mod prefix)
if you're running debugplus, just run eval G.ARGS.LOC_COLOURS in the console and find what the key is
this doesn't effect Devious Joker (chips for straights), Crazy Joker (mult), or The Order (Xmult), is that because they check the cards you play manually when its evaluated?
gotcha
i mean it says something like this "omega_suit: Table:
1: 0
2: 0.14901960784314
3: 1
4: 1" so what now?
then it's just {C:omega_suit}
oh no mod prefix? goddam
i think because smods removes the prefix if you add it manually
calculate = function(self, card, context)
if context.before and context.main_eval and not context.blueprint then
for k, v in pairs(G.GAME.hands) do
if G.GAME.hands[k].played > 0 then
card.ability.extra.mult = card.ability.extra.mult + card.ability.extra.mult_gain
end
end
end
if context.joker_main then
return {
mult = card.ability.extra.mult
}
end
end,
}
i know what i did wrong but what im trying to do is check if hand has been played before and if so, add mult. the problem is the code i have right now will always update but i just want it to me a one time thing, how can i make it do that?
so only upgrade once per hand type?
yes
if played hand has been played before so yes
-- add played_hands = {} to config extra
calculate = function(self, card, context)
if context.before and context.main_eval and not context.blueprint then
for k, v in pairs(G.GAME.hands) do
if G.GAME.hands[k].played > 0 and not card.ability.extra.played_hands[k] then
card.ability.extra.played_hands[k] = true
card.ability.extra.mult = card.ability.extra.mult + card.ability.extra.mult_gain
end
end
end
if context.joker_main then
return {
mult = card.ability.extra.mult
}
end
end
(JokerDisplay) im confused. why wont it show up the 2x
mod_function = function(card, mod_joker)
print((EF.photosynthesis_hour_check(mod_joker) and card.config.center.rarity == "EF_plant" and mod_joker.ability.extra.xmult ^ JokerDisplay.calculate_joker_triggers(mod_joker) or nil))
return {
xmult = (EF.photosynthesis_hour_check(mod_joker) and card.config.center.rarity == "EF_plant" and mod_joker.ability.extra.xmult ^ JokerDisplay.calculate_joker_triggers(mod_joker) or nil),
}
end
Oh ok thanks
sadly i never used jokerdisplay
🥺
did you try clicking on it
sometimes the modifiers hide themselves (dont know why)
is there a convenient way to add an extra voucher slot to the shop?
damn it
SMODS.change_voucher_limit(1)
sickk i was hoping it was simple
probrably a big ask but i can't find anything in the docs about can_use and use functions, like a wanna make a cosumable that works like any other tarrot that changes 3 cards suit's, but to my own custom suit, how could i do that? ```use = function(self, card, area, copier)
end,
can_use = function(self, card)
end```
if context.scoring_name == card.ability.extra.poker_hand and context.end_of_round and not context.game_over and context.cardarea == G.jokers then
any reason this doesn't work for detecting if the player ends a Blind with a specific hand?
thank you so much!
uhhh
sorry, but does anyone know if there is a like, template for creating a main.lua for a Malverk card replacement?
I found this mod, but it only has the png of 1-13 all suites, and tells you to replace the 8bit deck, but I don't wanna use the mod all the time, and found Malverk. I have the folder structure right I think, with the assets, 2x, .png, but I am terrible at coding (only done python), and can't understand the help on the malverk page. (I tried to use deepseek, and gemini 2.5 pro, and to trouble shoot with them, but I get through various phases of crashing at startup, crashing when entering the texture menu, the mod just not loading, and the mod doing everything perfectly... but on the back of the cards...)
Any help is very much appreciated
is there anything specific im missing thats causing these to display as nil
Yes
You close off the vars
In the loc_vars
return {vars = {#1#, #2#, #3#}}
did you do what the comment says
how do i make a consumable create a random joker based on a custom rarity? kinda like soul execpt for a rarity in my mod
Yes
Imma try it out again later thank tho
SMODS.add_card({set = "Joker", rarity = "modprefix_key"})
that worked thank you!
trying to increase the rate of playing cards in the shop (just a testing number) for a deck, any idea whats going wrong?
they still do appear in the shop just not at the extra frequency
how about adding a joker from my mod? like any joker that i added
try doing it in an event
local mymodjokers = {}
for k, v in pairs(G.P_CENTERS) do
if v.set == "Joker" and v.mod and v.mod.id == "modid" then
table.insert(mymodjokers, v.key)
end
end
local joker = pseudorandom_element(mymodjokers, "seed")
SMODS.add_card({key = joker, set = "Joker"})
```?
do i put that outside or inside the calculate function? "im making a joker sorta of like riff raff"
like so? still getting the same issue
im wondering if maybe magic trick is taking effect after and overwriting it
also it's crashing either way
No.
Update SMODS
Then you should also update SMODS
oohhh
probably actually, just modifying that value works
yep its definitely that i removed the vouchers and now i only see cards
i definitely want the vouchers to still be redeemed though
i am asking yet again, how do you add to a poker hands' chips or mult
G.GAME.hands["handname"].mult = G.GAME.hands["handname"].mult + number same for chips but it would be .chips instead of .mult
yay
it's now saying this
I updated the code to fix that I think.
is there a clean way to do this out of curiosity?
bc all the code technically works here its just applying in the wrong order
actually how would you do this to every hand
still giving that same error
for k, v in pairs(G.GAME.hands) do
v.mult = v.mult + number
end
Perhaps now the code is fixed?
attempting this causes a crash i fear
ok it is actually spawning a random joker now, but it's spawning any joker in the game, not my mods jokers
nevermind i fixed it!
just changed the variables names, probrably "local joker" was conflicting with the actuall joker pool
thank you very much!
oh wait...
nah i just got lucky💀
it's still creating any joker
Did you change "modid" to your mod id?
yes i did
Code?
doubled checked it
for k, v in pairs(G.P_CENTERS) do
if v.set == "Joker" and v.mod and v.mod.id == "omega" then
table.insert(mymodjokers, v.key)
end
end
local omegjoker = pseudorandom_element(mymodjokers, "seed")
local omega_joker = SMODS.Joker{
key = "omega_joker",
loc_txt = {
name = "Omega",
text = {
"Turns every card in your deck into an {C:omega_suit}Omega{} Suit",
"Also creates {C:attention}1 Joker{} from {X:omega_suit,C:white}OMEGATRO{} when {C:attention}Blind{} is selected"
}
},
atlas = "omega_joker",
pos = {x=0, y= 0},
soul_pos = {x=0, y= 1},
rarity = "omega_simp",
cost = 20,
unlocked = true,
discovered = true,
blueprint_compat = true,
eternal_compat = true,
perishable_compat = true,
calculate = function(self, card, context)
if context.first_hand_drawn then
SMODS.add_card({key = omegjoker, set = "Joker"})
end
end
}```
Why are you doing it outside of the joker?
uhhhh idk
how do i make a new cardarea
i asked if it needed to be inside or outside the joker and got no answer😭
Modded jokers don't exist in G.P_CENTERS at that time.
moreover, how would i inject it into UI
so something like this? calculate = function(self, card, context) if context.first_hand_drawn then local mymodjokers = {} for k, v in pairs(G.P_CENTERS) do if v.set == "Joker" and v.mod and v.mod.id == "omega" then table.insert(mymodjokers, v.key) end end local omegjoker = pseudorandom_element(mymodjokers, "seed") SMODS.add_card({key = omegjoker, set = "Joker"}) end end
Yes.
i tried that, but still spawning any joker
like when the blind is selected, it spawns a random joker from the og balatro, it's only supossed to spawn jokers from my mod
Are you sure the id is correct?
pretty sure
"id": "omegatro",
"name": "OMEGATRO",
"description": "i love balatro",
"version": "1.0.1",
"author": ["omega"],
"mod_type": "gameplay",
"main_file": "main.lua",
"prefix": "omega",
"badge_colour": "0046FF"
}```
wait
oh
id???
omg im so blind💀💀💀
i thougth it was prefix
ok yeah now it's working thank you so much again😭😭😭
man every time i come in here its new stuff. y'all are great
so yesterday i wanted to make my boss blind (+4 blind requirement (e.g. score at least 300 -> 304)) display correctly when not selected, as it had only applied when the blind was selected. anyway i tried this and it turns out that cry_ante_base_mod multiplies instead of adds. how could i possibly get around this?
SMODS.Blind {
key = "joker",
name = "Joker",
pos = { x = 0, y = 0 },
boss = { min = 1, max = 10 },
atlas = "blind",
mult = 1,
jok = false,
cry_ante_base_mod = function(self, dt)
if not self.jok then
self.jok = true
return 4
end
return 0
end,
disable = function(self)
self.jok = false
end,
boss_colour = HEX("f7343e"),
crp_credits = {
idea = { "Unknown" },
code = { "ScarredOut", "Glitchkat10" }
}
}
hi again. how can i load the contents of a file as text?
hm. could you try making it (base + 4) / base (idk if the function automatically adds 1 so it would become ((base + 4) / base ) + 1 or you would need to add that automatically
i quickly came up with this but i hope this works
edit
ignore my part with +1
i didnt use my brain
ooh
uhh what do i replace "base" with again i forgot
uhm. idk honestly. just get the blind requirement in some way ig lol
okay yeah i'll just look lol
oh goodie
cry_ante_base_mod = function(self, dt)
if not self.jok then
self.jok = true
return (G.GAME.blind.chips + 4) / G.GAME.blind.chips
end
return 0
end,
yippe
sob
does this happen with the joker / modifyer?
i think its because you return 0 and you cant divide by 0
yeah probably return nil
true
hes back chat
whom
somebody named "n'"
im always here i just ignore the chat when i see a lot of big blocks of code
true
guys hes hiding in the walls
also im slowly reading the mod manager thread
anyway WHY 😭
SMODS.Blind {
key = "joker",
name = "Joker",
pos = { x = 0, y = 0 },
boss = { min = 1, max = 10 },
atlas = "blind",
mult = 1,
jok = false,
cry_ante_base_mod = function(self, dt)
if not self.jok then
self.jok = true
return (G.GAME.blind.chips + 4) / G.GAME.blind.chips
end
return nil
end,
disable = function(self)
self.jok = false
end,
boss_colour = HEX("f7343e"),
crp_credits = {
idea = { "Unknown" },
code = { "ScarredOut", "Glitchkat10" }
}
}
we need an ai bot to repeatedly ask questions to just kill everyone
try replacing nil with 1?
this is like the cryptid #i-need-help description
already tried; same result (infinity)
jwoop
print out the calculation result
the variables may return nil
is this not how you convert a suit? scored_card.ability.suit = 'omega_suit'
-# how would i do that
no, use SMODS.change_base
idk you may try. elsewise does :set_suit() work?
nvm N' answered
print(). you can even see logs in the game using db+ instead of switching to lovely console
No.
Yes.
Maybe.
SMODS.change_base(card, rank, suit), you can leave rank or suit as nil if you dont want to change those
also emoji reactions are not working on my phone so something's power has been nerfed
/bump
wat
oooh
so like this? SMODS.change_base(scored_card, nil, 'omega_suit')
it'ssss not doing anything
alright chat i got an idea for my launcher script right
so right now i just have a list of mods and their github repositories (from awesome-balatro)
my problem is, not all mods are installed by just cloning the repository into the mods folder
another problem is, not all mods can be used standalone with no other mods
another problem is, having only this selection of mods limits how many mods the user can install with the program
another problem is, mods generally include more information than just its name and a vague category
my idea is to have a sorta database that includes mods, information like the author and description, and a script that installs it
another problem is, itd take weeks to go through every balatro mod and write a script that works on every system to install it
what should i do chat
anyone got any idea why this is crashing?
im not 100% sure how custom suits are handled but i think so
given that scored_card is a given card, i dont recognize that bit
what context is this running in
wtf
also
there already is a mod loader
it would help seeing the crash logs
im basically making midas mask, but it changes every card's played suit ```if context.before and context.main_eval and not context.blueprint then
local converted = 0
for _, scored_card in ipairs(context.scoring_hand) do
SMODS.change_base(scored_card, nil, 'omega_suit')
converted = converted + 1
G.E_MANAGER:add_event(Event({
func = function()
scored_card:juice_up()
return true
end
}))
end
if converted > 0 then
return {
message = 'Omega!',
colour = G.C.SUITS['omega_suit']
}
end
end```
well yeah i know but like where
thisi s all i got
you might be interested in the discussion in https://discord.com/channels/1116389027176787968/1391137484238360576
Because back.config.vouchers is usually a table of voucher keys.
everythink works fine execpt the changing suits part
looks mostly good, the suit should be modprefix_key though
ok wait how would i resolve this then
would it just pretty much be pasting that code in iinstead
Put it in extra
oh
oop sorry just put it beffore the return of the calculation there
still not changing the suits for some reason
what if you try hearts? sry ive never done that so thats just a guess
wrap SMODS.change_base in an assert()
itll crash but should give an error message
woahhh sick it works
then with the error message maybe we can see whats wrong
also didn't work
/bump twice
welp then try like Osquo said and put it in an assert
you put nil in quotes?
ah
youre setting the suit as a rank
a
i'd search for lua specific solutions
its (card, suit, rank)
no problem, what matters is that it works now, thank you very much!
one last question, i added the extra bit to everything in the other deck and while i think itll get the effect im hoping for once ive added everything properly, it's currently still crashing. does anyone know a fix?
self? what are you trying to do here
did you mean G, Gameor card?
No, remove that.
oh yeah i have that deck working this is hte other one im trying to set up today
Still remove that.
it's supposed to increase the rate of seeing playing cards with illusion in the shop, but im trying to set it up so that it applies the voucher before applying the playing card rate increase because magic trick by default overwrites it
How can i load the text of a file in my mod? I remember hearing smtn about systemfs or smtn like that
Bump
i'm booting up to a black screen
idk if its mod related but it doesnt usually happen
think it is mod related tho because i reinstall the game to no black screen
can i see the code, just had an idea of what it might be
for the button and whatever function it uses
Code for the button or for the functions for the button?
Oki
im a psychic
boowump
i want this blind to have blind requirement + 4 but this make the blind requirement just turn into infinity
there u go
I think you would have to calculate the blind size manually.
so like
get_blind_amount(G.GAME.round_resets.ante)*G.P_BLINDS.bl_modprefix_key.mult*G.GAME.starting_params.ante_scaling
yeah that works lol
have you tried setting card.ability.lock_text to a value before you create the button
great
SMODS.Blind {
key = "joker",
name = "Joker",
pos = { x = 0, y = 0 },
boss = { min = 1, max = 10 },
atlas = "blind",
mult = 1,
jok = false,
cry_ante_base_mod = function(self, dt)
if not self.jok then
self.jok = true
return get_blind_amount(G.GAME.round_resets.ante)*G.P_BLINDS.bl_crp_joker.mult*G.GAME.starting_params.ante_scaling
end
return nil
end,
disable = function(self)
self.jok = false
end,
boss_colour = HEX("f7343e"),
crp_credits = {
idea = { "Unknown" },
code = { "ScarredOut", "Glitchkat10" }
}
}
i have no idea why this is happening
like on instantiation of the card or smth?
not entirely sure where that would go
you can put it in the patch just before local lock probably
my guess is that it gets messed up by it being nil the first time before the other function loads
Small question, is the rarity actually makes consumable rarer to be drop ?
how does one load their config in other files?
as in those loaded via SMODS.load_file
Does context.destroy_card trigger its effects when a card is destroyed or is it used itself to destroy cards?
SMODS.Mods["modid"].config iirc
thank you :D
to destroy
Ah, is there a context for when cards are destroyed?
That seemed to work 
Thank uuu
I can now move onto the next UI thing I will suffer with
context.remove_playing_cards for playing cards, context.joker_type_destroy for other things (in the next SMODS release)
Thanks a million
The last one should be relatively super simple if I play my cards right
I just create rectangles
one on top of the other
and the top rectangle has a dynamic height
good luck
anyone know how to make a shader overlay the games "camera"
i need to make a function that overlays a shader for 170 seconds and if the event isnt cancelled before it ends it ends the run
probably last bump before i scrap trying this
how do i use a global variable to make a sell counter? i tried to use a reset_game_globals to set it but the game says that i'm trying to increment a nil value here
jsut call the global
would one of the values you're using to multiply the blind score be zero? try removing one of the variables to see if the score goes back up
like literally just call the global in its own line
Is there a way to manipulate a card's position in the deck? Or at least place it at the top of the deck?
anyone know how i can get my shader into balatro?
{
vec2 uv = fragCoord / iResolution.xy;
vec3 bg = texture(iChannel0, uv).rgb;
float speed = 0.0059;
float t = clamp(iTime * speed, 0.0, 1.0);
float borderPx = 0.5;
float thickness = borderPx / iResolution.y;
float freq = 50.0;
float flash = (sin(iTime * freq) * 0.02) + 0.5;
vec3 col = bg;
float borderPos = 1.0 - t;
if (uv.y > borderPos) {
float darkR = 1.0;
float brightR = 0.9;
col.r = mix(darkR, brightR, flash);
col.g = bg.g * (1.0 - flash * 0.8);
col.b = bg.b * (1.0 - flash * 0.8);
}
if (uv.y < borderPos + thickness && uv.y > borderPos - thickness) {
col = vec3(1.0);
}
fragColor = vec4(col, 1.0);
}
ante = 1
"mult" (blind size) = 1
ante_scaling = should be 300 i think
i guess now that i think about it i don't have anything for the +4 blind req but like stilllllll
how would i code a joker card where it gives me x3 mult when a king is played but when i play a queen it gives me 0.50x mult how would i do that shiish
sexist joker, look at trib
No, ante_scaling should be 1.
-- Triboulet
SMODS.Joker {
key = "triboulet",
unlocked = false,
blueprint_compat = true,
rarity = 4,
cost = 20,
pos = { x = 4, y = 8 },
soul_pos = { x = 4, y = 9 },
config = { extra = { xmult = 2 } },
loc_vars = function(self, info_queue, card)
return { vars = { card.ability.extra.xmult } }
end,
calculate = function(self, card, context)
if context.individual and context.cardarea == G.play and
(context.other_card:get_id() == 12 or context.other_card:get_id() == 13) then
return {
xmult = card.ability.extra.xmult
}
end
end,
}
thanks bro!
that's just the code for trib
yeha
you gotta modify it
uh no i'm pretty sure he was just giving an example on how you could do so
yeah man i dont know shit of coding im just in a call with friends
anyone know the issue here
shouldn't be too much i hope
x1 and x2?
do you have a 1x and 2x
just x2 i think
you nee dboth
yeah you need both
peak spelling mistakes
is there a "dl_bald_joker" file in 1x
needs to be like this
no just a j_bald_joker
then rename it as such
name it just bald_joker
alright
actually this might be it i just forgot
could be either
not this no
both pngs need to be the same name
then try this instead
i.e. make both "dl_bald_joker"
alright
okay but like
do i just declare it at the top of main or do i need to put it inside a function orrrr
put it inside nothing
jsut declare it
this didn't work either
same crash each time
id put it in its own file for organization sake
is this not the correct file organisation?
i'm already putting every joker in their own file, i think it's fine in main
should be correct
what else could be the issue
are you sure the atlas is correct?
how is the atlas being defined
like the SMODS.Atlas
in jokers.lua?
yes
wherevr
key = "bald_joker",
path = "j_bald_joker.png",
px = 71,
py = 95
})```
what
path need to be whatever you have your actual apth as
so j_bald_joker.png was fine the first time, or should have been
path is wrong
so in this case dl_bald_joker
it didn't work when it was j_bald_joker.png
wreong person but point stands
try it now then
then lets see
aight
my theory is your atlas in the actual joker is wrong
same crash
wdym
key = "bald_joker",
path = "dl_bald_joker.png",
px = 71,
py = 95
})
SMODS.Joker{
key = "bald_joker",
config = { extra = { mult = 2} },
pos = { x = 0, y = 0 },
rarity = 2,
cost = 4,
blueprint_compat = true,
eternal_compat = true,
unlocked = true,
discovered = true,
effect = nil,
atlas = 'bald_joker',
soul_pos = nil,
calculate = function(self, card, context)
if card.debuff then return nil end
if context.individual and context.cardarea == G.play then
return {
shake_card(context.cardarea),
mult = card.ability.extra.mult,
}
end
end,
loc_vars = function(self, info_queue, card)
return { vars = { card.ability.extra.mult } }
end
}```
from the atlas, all relevant code
atlas is correct...
unsure
equally as confused
can i see this again
also if you are defiing something as nil you can jsut not define it
helps my sanity if its nil
dumb question: you sure you saved everything
ight
yes
and reloaded
aslo whats in globals.lua
just colors
so how is joker being defined?
My best guess is atlas key and joker key are clashing
FOUND THE ISSUE
If not I have no clue
whats the issue here
it's supposed to be "1x" and "2x" not "x1" and "x2"
classic
sob
the wizard is here
rename folder
Rename folders
they make things look cool
learn the entirety of glsl
i wanna know how to put it ingame tho
i ahve one made
ah
{
vec2 uv = fragCoord / iResolution.xy;
vec3 bg = texture(iChannel0, uv).rgb;
float speed = 0.0059;
float t = clamp(iTime * speed, 0.0, 1.0);
float borderPx = 0.5;
float thickness = borderPx / iResolution.y;
float freq = 50.0;
float flash = (sin(iTime * freq) * 0.02) + 0.5;
vec3 col = bg;
float borderPos = 1.0 - t;
if (uv.y > borderPos) {
float darkR = 1.0;
float brightR = 0.9;
col.r = mix(darkR, brightR, flash);
col.g = bg.g * (1.0 - flash * 0.8);
col.b = bg.b * (1.0 - flash * 0.8);
}
if (uv.y < borderPos + thickness && uv.y > borderPos - thickness) {
col = vec3(1.0);
}
fragColor = vec4(col, 1.0);
}```
i mean you can just replace the shader file of a different mod
for ref
yeah but
that's what i did
what is this
oh wait did you make your shader outside of balatro/LOVE
yeah you're cooked idk how to convert that lol
😭L
its a simple shader tho it shouldnt be too hard
onyl time vremade doesnt come in clutch
you underestimate the number of syntax errors that are possible
the only two shaders in my mod (of the 11 editions) were made on complete accident or were a joke from ai slop 😭
it's great
no it's not but like the only ways i've ever done shaders were by just messing with values on other shaders
because i have no clue why any time i ever try to make a shader i get 50 syntax errors
the shader should be even easier considering it's not going on a card
it's just an overlay
thanks for helping guys all is well now
like the vhs shader or whatever
appreciate it even if it was a stupid issue of mine
we cannot believe your mistake so in turn the entire community will be blocking you
just as planned
lol
classic lurking somethingcom "🤔"
okay unironically this is just what i wanted to do with one of my jokers (but just for enhancements)
ended up commenting it out though since returns end all next things so i would have to create an if for every single scenario (e.g. lucky cards and echo cards' probabilities)
You didn't use the built in quantum enhancements?
average modded joker
imagine a card enhancement that would slowly infect all your cards
how do I make a cunsumable spawn as freakently as the soul ?
hidden = true
i find it hilarious that the joker was literally named "quantum joker"
but no i have no idea what those are
The only thing that is missing is multiple of the same sticker.
seals on every more like every on every
? I don't realy understand. like hidden = true is not for hidding something, isn't it ?
hidden = true is for things like the soul
means it won't show up in shop and can only be gotten from a would card
makes things appear rarely
like I want my consumable to be as rare as a soul in my packs
its going to do that Ig
yep that's just hidden
i consider mr poly bridge and n to be the wizards of the modding community
the ⬆️ should get a balatro makeover
anyways any wizards here that know shaders?
how do you use loc_vars on a blind
No.
Is it not the same as normal loc_vars?
not a single one
hey so why is this happening?
--- STEAMODDED HEADER
--- MOD_NAME: Shenanagain
--- MOD_ID: shenanagain
--- MOD_AUTHOR: [TheTyphothanian]
--- MOD_DESCRIPTION: Shenanigans but again
--- PREFIX: shen
--- VERSION: 1.0.0
----------------------------------------------
------------MOD CODE -------------------------
SMODS.Atlas {
key = "shen",
path = "shen_atlas.png",
px = 71,
py = 95
}
What's the file structure of your mod so far? The code shown for your Atlas is correct, so something else must be going wrong.
No.
dang
shen_atlas.png should be in assets/1x and assets/2x
oh my god
2x being double sized.
yeah
I've seen that when digging through mod files just completely forgot
testing
same error
What does the file structure look like now?
also, you don't need that ancient mod header
oke
just do your stuff in the metadata .json
it's not needed and updated mods don't have it
now I know
aight bet
what are the odds i accidentaly delete everything
high
still no idea what the issue is?
What's in the lovely.toml?
[manifest]
version = "1.0.0"
dump_lua = true
priority = 0
[[patches]]
[patches.copy]
target = "main.lua"
position = "append"
sources = [
"shenanagain.lua"
]
do I need more?
No, remove the lovely.toml file.
okay
I think you're trying to load the file before SMODS.Atlas exists.
oh dang that was it
holy cow thank you
time to develop my overpowered spectral card
SMODS.Joker {
key = "universal_joker",
config = { extra = { h_mult = 1 } },
rarity = 2,
cost = 10,
blueprint_compat = true,
eternal_compat = true,
pos = { x = 1, y = 0 },
atlas = "placeholders",
demicoloncompat = true,
loc_vars = function(self, info_queue, card)
return {
vars = {
number_format(card.ability.extra.h_mult),
},
}
end,
calculate = function(self, card, context)
if context.before and context.cardarea == G.play or context.forcetrigger then
return {
G.GAME.hands[context.scoring_name].mult = G.GAME.hands[context.scoring_name].mult + card.ability.extra_h_mult
}
end
end,
}
why isnt this working
What exactly is the error/issue?
the part where the mult to the hand is added
