#💻・modding-dev
1 messages · Page 246 of 1
...i mean, if it works it works
I'm about to be such a hater in this world
oh i posted this and instantly realised my stupidity so
for getting poker chips right
figured it out.
da-ba-dee, da-ba-di
blueprint 👀
it only half-did it because i did a patch wrong, too
i have cirno fumo :3
mind if i ask what you did just so i can fucka round with the colors
are you using the lovely patcher? or something that at least dumps the resulting game.lua so you can see what your relevant variables look like
i mean yea, we all use lovely as far as im aware everything else is outdated aint it
okay so it now no longer crashes and the original issue has been fixed, but now a new problem has appeared where the joker will increase its value and then destroy itself anyway, anyone know why this is happening?
you appear to have misspelled repetition, that seems like it might affect something
oh yeah, that might be the problem
so in mods\lovely\dump you should find a game.lua which is basically a copy of your active game.lua with all your current mods post patching
you're looking for, in function Game:main_menu(change_context), the function call G.SPLASH_BACK:define_draw_steps().
and that function call should outline two colour values, something like colour_1 (the outside swirl colour) and colour_2 (the inside swirl colour).
and for me, it was
{name = 'colour_1', ref_table = G.C, ref_value = 'RED'},
{name = 'colour_2', ref_table = G.C, ref_value = 'BLUE'},
and i basically did what trance does as breeze mentioned earlier #💻・modding-dev message and patched them both to instead be
{name = 'colour_1', ref_table = G.C.SPLASH, ref_value = 1},
{name = 'colour_2', ref_table = G.C.SPLASH, ref_value = 2},
you can patch them to be hardcoded colours instead if you want, but my mod has a config option to toggle the colours on or off, so i have a Game:main_menu() hook in my main lua file. before i call the original function, i swap out G.C.SPLASH[1] & G.C.SPLASH[2] with my custom colours if the config option i mentioned is enabled (and if it's off, i just set them to red and blue) 
holy shit that was it, i would have literally never caught that
awesome, thank you very much
thank you so much, actual lifesaver
There's also the Trance mod if you just want to look at funny colours without incorporating them into your own mod
Any help on this?
batro
does anyone know off the top of their head, which planets are featured on what celestial pack?
in order of how they appear in the base boosters graphic:
normal packs: mercury, jupiter, earth, uranus
jumbo packs: mars, pluto
mega packs: saturn, venus
I have no clue what's causing this error
key = 'Jokio_Karted',
loc_txt = {
name = 'Jokio Karted',
text = {'When a Lucky Card','played does not','trigger it gives {C:money}#1#${}'
},
},
cost = 6,
eternal_compat = false,
atlas = 'Silver_Atlas_SJP',
pos = {x = 0, y = 0},
config = {extra = {money = 1}},
loc_vars = function(self,info_queue,card)
return {
vars = {card.ability.extra.money}
}
end,
calculate = function(self, card, context)
if context.cardarea == G.play and context.scoring_hand then
if SMODS.has_enhancement(context.other_card, 'm_lucky') then
if not card.lucky_trigger then
dollars = card.ability.extra.money
end
end
end
end
}```
anyone know off the top of their head what global variable the deck/suit customization options are in?
the friends of jimbo stuff?
G.SETTINGS.CUSTOM_DECK
G.SETTINGS.CUSTOM_DECK.Collabs
I'm looking to do something if a specific skin (my own) is set on a specific suit
let's try G.SETTINGS.CUSTOM_DECK.Collaps.Spades
you should be able to find out how your skins are referenced internally by print(tprint())ing G.SETTINGS.CUSTOM_DECK.Collabs
I'll look at that then
thanks!
G.SETTINGS.CUSTOM_DECK.Collabs.Spades was exactly what I was looking for
you are supposed to
return{
dollars = card.ability.extra.money
}
oh yeah i had that originally i changed that while debugging just to see if that would work
should have reverted before posting
its likely because
in the context, "context.other_card" isnt anything
so its just nil, i think?
i think so, but what would be a way to check the cards in the hand for enhancements
use this context instead
it will let you use context.other_card
-# ignore the code inside please :3, i was testing smt
thank you
is there an easy way edit a joker when it's created in the shop?
i want to give every joker a random value when it's in the shop that i will use later
awesome, now my abomination of an enhancement's color can match my deck skin
I'm getting to the point where I wonder how many of my patches could have alternatively been implemented by hooks... and I don't want to think about how much refactoring that would take me
Does anybody know if this is possible or not?
it works!! fun fact: the reason it's called the Moa Egg is because moa eggs were found to be the most fragile kind of bird egg
another fun fact: the moa is extinct, which i did not know until like 10 minutes ago, which makes the message upon the joker getting destroyed very funny
okay so I think that now I've defined what my card is and what it does, now how do I actually make the card an object that can spawn in packs?
the fuck is a toml
Tom's Obvious, Minimal Language (TOML, originally Tom's Own Markup Language) is a file format for configuration files. It is intended to be easy to read and write due to obvious semantics which aim to be "minimal", and it is designed to map unambiguously to a dictionary. Originally created by Tom Preston-Werner, its specification is open source....
toml is a type of frog
is there a way to detect when any probability occurs?
doesn't matter if it succeeds or fails, just if it happens
hook into pseudorandom would be your best chance
hmm, that would be everything, even without the 1 in x descriptor
thinking about it, I can probably only hardcode that
unless i'm forgetting something
I'm trying to make a tarot card that makes a selected playing card's edition foil
(like aura but slightly better)
set = "Tarot",
key = "mosaicTarot",
pos = {
x = 0,
y = 0
},
loc_txt = {
name = "Mosaic",
text = {
"Add Mosaic",
"to selected card"
}
},
atlas = 'mosaicTarot',
cost = 4,
pools =
{
["Consumeables"] = true,
["Tarot"] = true,
},
unlocked = true,
discovered = true,
can_use = function(self, card)
if G.STATE ~= G.STATES.HAND_PLAYED and G.STATE ~= G.STATES.DRAW_TO_HAND and G.STATE ~= G.STATES.PLAY_TAROT or any_state then
if G.hand and (#G.hand.highlighted == 1) and G.hand.highlighted[1] and (not G.hand.highlighted[1].edition) then return true end
end
end,
use = function(card, area, copier)
G.E_MANAGER:add_event(Event({
trigger = 'after',
delay = 0.4,
func = function()
G.hand.highlighted[1]:set_edition(foil, true)
return true
end
}))
end,
loc_vars = function(self, info_queue)
info_queue[#info_queue + 1] = G.P_CENTERS.e_foil
return {}
end
})```
currently it does nothing
not even crash the game
the part where you can only use it with one card selected works fine
it just doesn't apply foil
i think it has to be a table
it plays the use animation but nothing happens
I think that's for stickers? a card can only have one edition
I think you're just missing the prefix, which would make it e_foil
i wrote this and it works
I guess try it
does anyone know a way to trigger an effect after a consumable resolves?
the way im currently doing it with context.consumeable triggers before the actual consumable effect happens
for example this just counts the sixes in your hand after using a consumable but when using things like cryptid or strength on 5s it spits out the amount before the card was used
eh ???
is h_dollars an enhancement?
all enhancements should be prefixed with m
oh . dang it documentation
(also you don't need the == true)
that's redundant, since the boolean returned by SMODS.has_enhancement() is already what you want
Is doing something like this possible?
Is it just for aesthetics or is there something else you want to do with that?
85: unexpected symbol near '='
no idea what's wrong with this line
It's because i'm basically making buffed vanilla jokers along with other things and I want to have the jokers be in the joker order of the collection.
You could organize them in that order in your file then
No, because if i'm making other jokers, it'll look weird.
Even if you put your own other jokers all the way at the end?
you're missing a comma after the previous end
and actually you're also missing another end (to end the function)
ah thanks
I wish notepad++ had function-end matches highlighted like it does for brackets
I want the jokers in the order of when they were made.
that's generally why people keep consistent indentation for things. the function body currently has one tabstop too few, if it were intended this would be easier to spot
fair enough
How do you format stuff inside of compat_exceptions? I can't get my sticker to be incompatible with other stickers
it is doneeeeeeeeeee
and with this and much more out of the way, i sleep 
i feel like i should make my own object at this point lol
that would probably be a wise move
Is adding new entries to the collection possible?
Does anyone know if there's a way to have custom playing cards (custom suit/rank) that don't follow the "X of Y" naming convention?
interested in making a joker counterpart to seals
got SMODS.DrawStep figured out, but SMODS.GameObject is beyond me.
i know autumncircus had something like this
(also will have a mechanic that i won't reveal now)
:>
I'm working on a consumable that destroys all consumables of the same type and gains their abilities. They're all custom consumables so I have full access to the code without too much fuckery. If I wanna avoid hardcoding everything, I should probably move their functionality so separate functions, so I can have the code call those, rather than find a way for it to activate fake versions of those items 🤔
I thought I was going to arrive at a question there, but I guess I wasn't
I mean I think there's something there
I don't know how SMODS do that kinda thing but couldn't you store each calculate function in like, an array or something?
Rubber
ing
I haven't played around with calling calculate functions of other items by storing them, I'm not sure if it's something that'd work. I guess it's worth trying to just to see if it's a thing to add to the toolbox even if I don't use it for this
Illusion of choice
what I'm doing right now for ability transfers in my mod is store a table of object keys and config values of all the transferred abilities and call a custom calculate function on the center
I guess I could store the triggering context, a function that contains the effect, and the strength of the effect in an array and pass those on
That sounds like the most effective way to do that for sure. Do you mind if there's some code I can look at? I promise I won't Almanac it 😛
Your code is protected by being so specific that it'd be insane to just copy over, haha. But it is the giant's shoulders on which Kino stands, haha
here are the functions and hooks https://github.com/nh6574/JoyousSpring/blob/a8053a1d270fd34fef4e8e43085cfd48076fd4d9/src/effects.lua#L277
and here are the definitions for the center functions, you can probably just use the regular calculate instead of making a custom one if you want to just copy the whole effect https://github.com/nh6574/JoyousSpring/blob/a8053a1d270fd34fef4e8e43085cfd48076fd4d9/src/monsters.lua#L24
So there's no way to do it without enhancing the card
every time I see your commit I get the ache to clean up my own code base and document it this well, damn
Thanks N', intensely appreciated as always 😄
How would one go about adding a new entry to the collection?
I think I should do a real major rewrite for Confections if I actually want this to be properly modular. For now I guess I'm just going to hack it, and then rework the entire system at some point. I've been wanting to turn it into a stand-alone mod too, so that's good motivation for that, haha
Would it hypothetically be possible for a mod to use the seed to predict things? Like could I make a consumable that tells you how many booster packs itll take for a specific joker to appear in one?
yes! I haven't looked into exactly how, but I've checked to see if the concept of a reroll prediction joker was possible, and it definitely is. The only thing I'm not sure about is whether booster packs are fully predictable, or if player choices can change the outcome
But you probably wanna look at the code for seed analyser extensions
Awesome
can i see the return
im extending SMODS.Sticker but for some reason the inject function isn't running?
return of the config ui?
yeah
G.FUNCS.akyrs_change_wildcard_behaviour = function (e)
AKYRS.config.wildcard_behaviour = e.to_key
AKYRS.save_config(e)
AKYRS.config_wildcard_desc_dyna:update_text(true)
AKYRS.config_wildcard_desc_dyna:update()
end
SMODS.current_mod.config_tab = function ()
AKYRS.config_wildcard_desc_dyna = DynaText{
scale = 0.3,
colours = {G.C.UI.TEXT_LIGHT},
string = {{ref_table = localize('k_akyrs_wildcard_behaviours_description') ,ref_value = ""..AKYRS.config.wildcard_behaviour}}
}
return {
n = G.UIT.ROOT, config = { minw = 18, minh = 6 ,align = "tm", r = 0.1 },
nodes = {
{ n = G.UIT.R, config = { colour = G.C.UI.TRANSPARENT_DARK ,align = "tm"}, nodes = {
{ n = G.UIT.C, config = {
align = "cm", padding = 0.2,
}, nodes = {
{n = G.UIT.T, config = {
text = "Wildcards Behaviour",
scale = 0.5,
colour = G.C.UI.TEXT_LIGHT
}}
}
},
{ n = G.UIT.C, config = {
align = "cm", padding = 0.2,
id = "akyrs_wildcard_behaviour_desc_dyna"
}, nodes = {
create_option_cycle({
options = localize('k_akyrs_wildcard_behaviours'),
scale = 0.7,
w = 4.5,
opt_callback = "akyrs_change_wildcard_behaviour",
ref_table = AKYRS.config,
ref_value = "wildcard_behaviour"
})
}
},
}
},
{
n = G.UIT.R,{
align = "cm", padding = 0.2,
},
nodes = {
{
n = G.UIT.O,
config = {
object = AKYRS.config_wildcard_desc_dyna
}
}
}
}
}
}
end
formatting is a mistake
StrangePencil.Statuses = {}
StrangePencil.Status = SMODS.Sticker:extend({
obj_table = StrangePencil.Statuses,
obj_buffer = {},
set = "Status",
atlas = "pencil_status",
discovered = false,
required_params = { "key", "pos", "config" },
apply = function(self, card, val)
card.status = copy_table(self.config)
card.status.key = self.key
end,
})
i think you need to set a current_option in create_option_cycle
ah
that worked i think
how about dynatext not updating
G.FUNCS.akyrs_change_wildcard_behaviour = function (e)
AKYRS.config.wildcard_behaviour = e.to_key
AKYRS.save_config(e)
AKYRS.config_wildcard_desc_dyna:update_text(true)
AKYRS.config_wildcard_desc_dyna:update()
end
hmm no idea
it's creating new dynatext objects without destroying them probably
Need some help with the code structuring. Is everything corrrect here?
(that's an enhancement)
it seems like the scoring ability only applies when the probability hits
yes
thats the issue atm
its tied to it
Im not really sure how I could separate them
you can use extra in your return to specify another message to come after
A collection of random stuff that I've created and drawn in Paint. - DigitalDetective47/strange-pencil
although for scaling you should check how basegame jokers do it
One question: do I need the elseif part?
the whole structure here is super weird
I added it to makes sure the Xmult message would be displayed even if probability fails
Im a noob at this
well in that case it's matching the wrong if block
and its condition is the same as a surrounding if
is that incorrect? since I need the card to give u xmult when it scores
ur checking context.cardarea == G.play and context.main_scoring twice
so, the whole elseif part is redundant then?
yeah
i need better description lol\
How can I go through the scoring hand with a boss blind?
So this code now triggers an upgrade and Xmult message when probability hits, right? In that case what context should I use for a block of code that is activated when probability doesnt hit? (the one that gives current Xmult of the card)
tbh you should handle the upgrading and the xmult application separately
that's what Im trying to figure out how to do
Do you have a specific example in mind?
anything similar
every scaling joker ever 
what even is card:scale_value
that's my teammate's custom function ig?
i dont think it's relevant here
not sure how you'd need a custom function for that but alright
scalaedouble scale r smthn?
Im using it for code consistency
no other reason
kid named +:
(why they use it idk)
anyways
scaling jokers usually scale in context.before
if they don't scale based off cards scored, at least
oh btw aure while ur here im ripping my skull apart at this
uh
trying to implement something like stamps from autumncircus
you can't have an obj_table/obj_buffer in a class derived from one that already has them
the thing is that Antimatter cards scale when it's their turn to score (in order left to right, not all simultaneously) and they upgrade before giving xmult
should i extend SMODS.GameObject directly?
So what's the context then?
we could use some card modifier type API
else although here you might be able to move the return outside
yeah, this is sorely needed
sticker spoofing is a mess
adding anything to cards is a mess
agreed, the current system doesn't offer a good way to do this
I did want to extend the bonus chips to Jokers and stuff
with permission of course
And I had done it in 0.9.8
With autumn’s code as reference
And I probably still have its 1.0 port
UI SHENANIGANS IS REAL
ui code is hell
can only be a matter of... uhh, months(?) for them to come back
CAN WE GET MUCH HIGHER
who nose 👃
no body nose
how are you doing aure
Hello chatters
I'm doing well but kinda lacking motivation
fair
you should talk to N', because I think he's just made a system for that
tell them hi from ice
and i almost accidentally shared my Balatro game
lmao
so real
i may be stupid but how do you set the hand size for a deck? G.Game.starting_params.hand_size = 12 isn't working
i can see the reddit post 'My coworker was playing Balatro during our morning stand-up. Should they pivot their build?'
it's G.GAME
I mean I had it working (for some parameters), I think just a UI was missing
all caps
And I had done UI, it was just messy compared to what SMODS usually does
when you spell the man’s name
tbh whatever the hell i was doing will wait until this is done
strange pencil 0.3.0 forever delayed
person
I did make a PR for a new context yesterday
I'm almost here, everything works properly except card doesnt give it 'base' xmult if probability fails. Ho do I separate it from probability hit? I didnt fully unerstand which 'return' to put outside
I really wanna figure out UI properly just because I desparately feel it'd be a very handy thing for SMODS to have a standard set up to create the below consumables card area, and make it a carousel, but alas every time I do UI a part of my perishes and I became a more hollow man
For cards being added to the deck
oh wait i did that i just typed it wrong in chat lol
G.GAME also is not worknig
You put the else in the wrong place
Today feels like a good day to merge a bunch of PRs and inevitably inadvertently break something
I might make more PRs soon
I’m doing them as I implement stuff for my mod
So that everyone can use them
Steamodded goes up in flames after 2 merged PRs and promptly explodes
I'm just adding a chain of extra to every calculate return lol
What I have in mind is fixing Orbital Tag and a context for abilities that activate when destroying Jokers
I might get sidetracked by Tags though
Because I wanted to implement one for the first time
Implementing a new tag system? or just making a new tag for your mod
New Tag for my mod
But idk how Tag contexts work
I implemented a new Joker context and Idk if it works with Tags
for the card_added PR, I thought I'd have to be concerned about cards changing enhancements, but fortunately excluding playing cards from this context avoids that issue completely
it does seem to be targeting code from other patches in smods though, which isn't great
well,. isn't there already something for adding playing cards? for Hologram?
yeah that's why it's excluded

that's nice
but add_to_deck gets repeat calls when changing enhancements
which is what I thought might be an issue, but isn't
Should I've to put end to first 'if' block and then add 'else'? I'm a little lost
scale_value?
not relevant here
The else branches off the if block it’s connected to. If you want an alternative action when the probability check fails, you need to attach the else to that block
i'm curious about it
isnt it attached here? @zealous glen
wait
I think i understand it now
sorry for rushing to the conclusions
I was not familiar with this game
If you are using an automatic Lua formatter it will format the blocks via alignment
Still connected incorrectly?
i'm able to do context.card.config.center.set == "Planet", but how can i do this with a check for all consumables?
ok what am i doing wrong here that the hand size isnt being set
yup, now it procs for every other context
Still looking for an answer on this.
On how to do it.
my genius it's almost frightening
I found the right place!
i think
oop no nevermind, i figured it out ^^
...i think. is it if context.selling_card and context.card.config.center.set ~= "Joker" then?
hello ghost
haiii :D
-# going absolutely bonkers
will this have side-effects?
its supposed to run somewhere at the "context.after" state
it works, but im worried there will be jokers which use draw_from_deck_to_hand
alright fellas i have been trying to get this working but idk wtf im doing but i want to shoot myself so please can you tell me whats going on
crash logs are saying its something on line 56
scroll up homie
should it be like this then?
branching off pseudorandom
actually you should combine if pseudorandom and if xmult<3 into a single if
and that on the else of it
correct?
im jumping off my window (boss bind refence)
I mean you don’t have to
It depends on the effect you want
And if it gives xMult anyways, you could avoid having two returns
But two returns might be easier to write
huge thanks folks
Here’s a little celebration
what file with the code for all the jokers?
i spent 4 minutes on this shit
That’s not a wall
close enough
card.lua
-# so cute so tiny….
-# 
i was looking for godamn triboulet withtout a capital t 😭 so i was confused
does that make a difference?
wait until you run across thunk’s misspellings
time to miku
miku
Brazilian Miku when
I THOUGHT YOU HAD IT VICTIN
I was asking myself
ah
Surely it won’t reset
i love miku still
Wowie
ballin'
Still envious of the composition ;P
★★★☆☆
My PR is missing documentation tho
i will work on switching things over to some of the new features today
???????????????????????????????
I will work
at my job today 
i love caino
How does one do this?
Minecraft Nether Portal
I'm gonna do it next
im not ready
oops math problem that didn't remove cards that gives 0 or negative chips
Couple questions about Malverk
- I got these errors on the config texture pack screen and not sure what I did wrong, Is it because I only made an alttexture object of only a couple of things and not all?
- Is it possible to change it so the default joker that appears in areas such as the editions page to be replaced the default joker of a texture pack?
Omg we have the same cursor
But also holy moly that’s so cool
Did you make this?
yea im working on the blind rn
That’s just your alt texture objects missing proper localization
the card skins aren't mine thou
I love the theming of it
It’s so so so sick
Like it feels tense(?)
Which like with the limit of Balatro is impressive to replicate
Can one only put extra collection entries in the "other" tab?
So I have to add the localization = true to it?
How to do you properly add the text?
the music isn't in-game rn im just playing it over the recording but this iss the final boss of undertale sooo
check #1279246553931976714
🔥 🔥
will you add the damage step to balatro
the damage step is represented by people forgetting to order their jokers before scoring
So, I made a boss blind that acts on G.play.cards. Is there a way I could make it act on only the scoring cards instead?
yo @cerulean rose your the goat frfr
yeah
hell yea
hi di
❤️
im just gonna see feedback if the gameplay loop is nice, since its more of a concept rn due to how many stuff r missing from my mod
like uhh, not all the relics are added yet
currently in an online class rn, so the mod will be out an hour later or so
after some assistance regarding splash color changes ive just been fuckin with those now, added a bunch of colors and have the game pick a random 2 each time you launch
been a fun lil time
itll be in the top 5 of released mods because youre awsum
i want to add nice boss blinds which interfere with more than just scoring
soo that will also be a top priority after getting the playtest out
yea im hoping i can do some neat shit blind wise as well
i want at least one boss blind to be finished for the full release
so that pep can have a taste of what boss blinds in my mod will be like
:3
with how much content you have you can definitely do alot that fw your own stuff
-# i also want to add unique small and big blinds too, but i dont think that will be nice when you combine my mod with others
the sad thing about my mod is that its a standalone mod, so it will definitely outshine jokers from most mods
kinda unavoidable
yea unfortunately that be the wave at times
but i figure if the mod is fun enough people wont need other mods anyway
but maybe if i balance my mod thoroughly then vanilla jokers can still be used
I'm excited to try it at least Bepis! And to be as nitty gritty with my feedback as you want me to be 😛
id love specific feedbacks lol
no aiko, they are supposed to be fun, not a mental torture method
yay
is that a new context
yes
fire
wait did the boss blind stuff hit smods today?
it sure did
yes
Time to add darth vader ig
consider adding area checks
Hey guys, do you think this is asking too much of a tarot card? Like is it too expensive, gameplay wise?
Select three cards. The first is destroyed and the other two are given a special edition
-# im gonna forever glaze blind expander
it should be {C:chips}+5{} Chips btw
OHMAGAH
oh yeah i had it but i removed it trying to figure out why cards were not appearing in hand (it was cartomancer)
-# but also, i dont really understand the effect
fair enough
my current notes have him making it so your current hand doesn't score, but I'm for sure going to need to find something more interesting, haha
my effect or something else, sorry
cant you just make it so you press the button and then a key on your keyboard
and it becomes that letter?
this is a test
John, coulw we make it so Control + something restarts the game, rather than holding M
looks at #550
I wouldn't say it's expensive. It's a hanged man + two cards giving an edition. You need to be quite far into deck fixing before sacrificing a card for a benefit becomes a hard choice
ideally I'd like it to be configurable, but just adding a non-conflicting keybind works for now i guess
Why am I being ignored? 😢
context.scoring_hand
could mix some effects, have a cerulean bell like effect for the force, then mess with other things
I'm not sure what you mean by acting on cards
since blinds have calculation now (i think), you can just use that
The boss blind doesn't have access to context apparently.
as of today, blinds support calculate functions
but more information on what you want to do would be helpful
btw you can add a debuff_text
haha my main weakness of knowing jack shit about star wars strikes again , haha. I might go for something related to joker destruction, as that is somewhat tied to star wars in my notes. Though I mainly want something that feels force chokey, but besides moving jokers, I don't know what that'd be. Though, as I type this, maybe I can have him force a joker into slot #1 and weaken it to half strength each hand 🤔 I have the systems for that, after all
I am making my boss decrease the rank of all scoring cards. My code is working on all cards played currently.
I just needed a way to affect only the scoring cards and not all card played. But it should be easy with the SMOD update.
that would be neat
also youre making a freaking mod on movies, go watch star wars smh
yeah that sounds straightforward with blind calc
i'm pretentious, Star Wars is below me. tbh I've seen Star Wars IV, just ages ago and I barely remember anything from it, haha
very fair honestly, oh shit i actually havent fully checked do you have any lotr content tossed in there yet
thats some goated cinema
Nope, I haven't figured out an idea that's simple enough, haha. But I love the trilogy
I've also not seen Titanic. There's a lot of famous movies, it's difficult to have seen them all 😛
uhhh is it normal that it patches it as G.GAME.blind:get_loc_debuff_text()()
youd also win my heart if you can get mel gibsons braveheart in there :b
magic man speaking magic words
Wow! Did you know that Oops All Sixes stack with each other?
-# yes
yes
yes
smh, he was the 22nd joker I added, my guy. He's been there since Kino's been on downloadable 😛
-# i thought thats common knowledge?
i still suck at regex, wow
insert the xkcd comic here
thats my goat right there
that movie is my favorite
i forgot to escape a set of brackets
oh is it a regex pattern
I added it because I needed a movie with Heart in the name ofc, haha
Oh wow, so this is not the syntax to spawn a regular card in a booster pack!
local getCard = create_card("Card", G.pack_cards, nil, nil, true, true, nil, "foxNegation")
attempting to make another joker and this crash happens when i try to hover over it after starting a run - Not before when im in the menu. I used steammodded's example mods castle which works, so idk whats going on. Any ideas?
-# what the hell is that indentation???
you really played a Straight hand with that one 💔
literally better calc 2.3
its the discord ui, thats why i also provided images
Hi John, quick question
If I wanted to spawn a regular standard playing card, which set would that be?
i actually have a joker which does the same, but connected it to context.end_of_round instead
Pretty sure SMODS.create_card doesn't support playing cards
i dont think theres a need for hooks to achieve that kinda "reset suit/rank depending on your deck" effect
you can try with 'Default' or 'Enhanced' though
And here I was thinking it was an ally. Smh
how do i detect if there are two queens in the hand? im trying a for loop and its going badly
the hook is there so that it runs the reset command when the run starts, like it does with mail in rebate and idol
Here, I have logic to check how many tens there are, you could modify this to get started
without it, every time you pick it up itll always start as an ace
mhm, theres no need for hooks for that either
i use add_to_deck
to reset it when its added to the joker area
:3
but what about when its in the shop?
aka when you obtained it
i have it at "?"
AAAAAAAAAAAAAAAA
elseif context.joker_main then
local tenCounted = 0
local messatsu = false
for i = 1, #context.scoring_hand do
if context.scoring_hand[i]:get_id() == 10 then
tenCounted = tenCounted + 1
end
end
🤷♂️ so it really depends on how you want it to look like, i suppose
beh, im not really the biggest fan of that
but i try not to rely on hooks and patches too much to get my jokers going
thats fair, its the hook thats breaking it lol
you can also just use reset_game_globals and check run_start i think
is that not what im doing?
why do you need the hook then?
to activate the function when the run starts??
i did what castle 2 did in modded vanilla
and it works so i dont know what i did wrong :V
function SMODS.current_mod.reset_game_globals(run_start) yeah this is the function name
i am using that
How would I go about checking if the first played card has a specific enhancement and destroying it?
G.hand.cards[1]
no yeah i saw that, it just seems weird to have run_start and also need a hook but if that's what the example does then it must be fine
then use SMODS.has_enhancement(card, enhancement_key)
Oh cool. Thank you!!
ah, makes sense! thanks
would switching off a hook still make it work the same? cuz i might be able to get it to work with a different method
@frosty dock , I found the answer, sent in a pr to add this to the docs
Trying to help others who may have the same question
hi! is there a context for buying a Joker?
add_to_deck?
i would think so but the example says the opposite so idk lol
context.buying_card
Using "Enhanced" or "Base" is what standard packs do, this looks off
i mean no point in not trying? how would you do it
thanks ^^
john aure is here :0
also we don't encourage using create_card directly
i feel like if you remove the hook it should work?
ok john you made the castle 2 card in modded vanilla, im trying to do something similar and its not working
do you think you could help?
like how would i remove it? im a little stupid so explain it like im 5 lol
like delete the entire function
but then it wouldnt ever change card rank...
how do i close the menu properly 😭
i mean function Game:init_game_object()
ModdedVanilla is made by someone23832, but I can help i guess
esc 🙂
😭
Just create a copy of the menu behind it on top
heres the problem im having mr smods, i assumed you could help cuz the comment above the castle2 card
-- Thanks go to Aurewritten, John SMODS himself, for writing out this joker.

Alright I'm done fixing the bug i was dealing with, let me see
you're using base.rank, which doesn't exist at all
Me when I steal that UI: 
i just checked game.lua it is base.value
thats like the ONLY part of the game that says value why would that change up JUST FOR THIS
yay
i should think of a custom message
where does it say rank

some local var names do i guess, but the game doesn't have much of a structure behind ranks
so most of that is from smods
uh oh
looks familiar
In the local variables for the numbers in the en_us file, and I believe the base code for rebate says rank too
it's thunk code after all
don't expect consistency
else you might get consumed by j_gluttenous_joker
what's an x_Mult
Also I ctrl+f rank and replaced it with value, which fixed the error but now it's not working as intended, it's not converting ace cards to steel. Gonna see I it's a problem with mislabeling by replacing ace with a number so that it'll match up with the rank
GLUTEN
WHY IS THE CODE MISSPELT
consumeable
Did you think aure was kidding
Or me for that matter ;P

🤹
why did i think that was a jester hat
💔
i thought that was a jester shurgging
what the hell
pepsi fever
I didn't realize until I saw it next to the loc_text name
it makes you be pis
do UI nodes have a transparency knob I can toy with? I'm trying to see if I can fade an element in
Well you can change the color
How do I destroy a playing card?
Fuck
Do I do it through events?
I tried that and it didn't work, but I'll try again
okay new question :)
context.buying_card works, but is there a context for generally obtaining a Joker?
i love
🔥
one was added today, actually
context.card_added and context.card.ability.set == 'Joker'
cheers!! will update for that, and change the dependency
oh i should change the dependency too
huh, weird. updating caused a new error in the collection
lemme grab that
oh no wait, it's because i added something -w-
Is there a way to check a card's variable via console?
nevermind!
what did i do wrong here? :>
set_ability = function(center, initial, display_sprites)
card.ability.extra.current_rounds = 0
end```
I don't think that's the format for a function but I could be wrong
can someone tell me wat's wrong?
what's the error?
there's no error, its just not doing the destroying
so a logic error then, gotcha
lemme see
do the if statements apply? can you test that?
😭
wait i think i figured it out
(bump)
AAAA
the function argument is incorrect
it's
set_ability(self, card, initial, delay_sprites)
FINALLY WAAA
ah, grand, thanks ^^
fuck i just realized. i have two destroy card contexts.
hmm. now i've got my ends wrong
code:
sorry for the lack of colouring -w-
ah no wait i'm dumb -w- i forgot = function
okay bingo! thanks :D
AHAHAHAHAHA OKAY SOMETHING BROKE
why ol boy leanin to the side like
does it make a difference if mult is doubled vs the total score being doubled
how would i go about making a seal have a 1/6 chance to destory the card it's on?
timing is the main factor, but if it'd happen at the end, (10 x 8) x2 is the same as 10 x (8 x2)
How do I send debug messages?
Is there a way to send multiple of those little notification messages? I tried doing multiple but it breaks cuz you can't do multiple return statements
return{
message = "this is an example",
color = G.C.Attention,
card = card
}```
where do i find this guide, im a lua noob so this is all a bit daunting to me
attention_text might be what you're looking for
For a Nope! for instance
attention_text({
text = localize('k_nope_ex'),
scale = 1.3,
hold = 1.4,
major = aura_card,
backdrop_colour = G.C.SECONDARY_SET.Tarot,
align = (G.STATE == G.STATES.TAROT_PACK or G.STATE == G.STATES.SPECTRAL_PACK) and 'tm' or 'cm',
offset = {x = 0, y = (G.STATE == G.STATES.TAROT_PACK or G.STATE == G.STATES.SPECTRAL_PACK) and -0.2 or 0},
silent = true
})```
That's the Steamodded wiki, this page specifically https://github.com/Steamodded/smods/wiki/calculate_functions
oh that's sick thank u so much
How would I write this as an if statement?
Both parts
How can I make it so the destroyed cards don't get counted in the scoring?
you can use context.modify_scoring_hand to disable them
if SMODS.has_enhancement(G.hand.cards[1], "enhancement_key") then
Oh thanks. That's why I was struggling
So, I should put my code in context.modify_scoring_hand instead of context.before?
no, you will need additional logic
is FPS as high as it can go on the system or locked to a specific target?
Is context.modify_scoring_hand on the doc?
i dont think so?
you need to return add_to_hand = true to add a card and remove_from_hand = true to remove it and it has context.other_card and stuff
what's wrong with this code? i have dream cards defined, but this joker isnt destroying them.
Guys this might sound dumb but where or how do i modify the "Oops all 6's" card
why is Cynthia not the Ace? 😔
does anyone know where local config = SMODS.current_mod.config would go as setup? like is it IN the config file, or in the main file, like where
is there a way to insert a table instead of one specific card type (currently 'Spectral')?
wherever you want to access the config from
I recommend putting it in a global in your main file like
MyModGlobal = {} -- change the name to something unique
MyModGlobal.config = SMODS.current_mod.config
Taking ownership or patching it
whats the normal weight for a normal booster pack
...i will just put it 10 and hope that its common enough
the common one i have is at 1
I do actually need my booster packs to show up more, so I should bump it up a little higher
I'm currently using https://discord.com/channels/1116389027176787968/1215417507440107540 as a reference for modding in a new deck type, but i wanna make it so the player starts with 2 copies of Temperance (like how Magic Deck starts with 2 copies of The Fool) and i cant find any info on how to do this
I need ideas
How do I make an inventory system.
Like where I can combine two things from my inventory
I've managed to figure it out but
bro is making riddle school
Im making a chemical system
does anyone know how this should be formatted in a proper way?
this is always going to be spectral or planet
pseudorandom_element({'Spectral', 'Planet', 'Tarot'}, pseudoseed('obsidian'))
Anyone?
It should be loc_txt = …
Ah 👍
I dont understand how people need lovely toml's, libraries and all that other stuff when all you need is just a json, a main.lua and some assets
would i be able to use a drawstep to make it so that a playing card draws a certain sprite for its center sprite based on a variable? I want to be able to draw any card enhancement backing but dk how
so true
You should probably put /s at the end idek
so true /s /jk /notsrs
:(
@wintry solar btw is the 2nd thing I was asking about possible with malverk or can that be only done by using SMODS.Atlas?
What’s the second thing?
Is it possible to have a texture pack object that is applied for its main joker to also appear on pages such as edition and etc which use the main joker?
update: i figured out my issue, i was writing in the input parameters for create_card wrong
Anyone?
-# bump
can you not just make a consumable?
interesting
You should just SMODS.create_card or SMODS.add_card :jimbo_spin:
Watch an official balatro update come out and break everything
real
1.1.0 will most likely take some amount of fixing on steamodded's as well as any mods that heavily patch
whats different between these and the native create_card im already using
it takes a table as an argument instead of a bunch of different parameters
:3
:3
:3
:3
:3
:3
:3
:3
can i make it so that instead of drawing its sprite an enhancement can draw any other enhancement's sprite instead?
:3
Do you know?
What inventory system are you talking about?
If your texture pack changes the base jimbo these should update afaik
So you need to be able to combine two cards, the cards you het after defeating a blind
So i need a way for someone to see and combine those cards
Sounds like a really open-ended question
maybe you could do something like that menu that displays the vouchers you've collected, that's the closest thing to an inventory I can think of, besides just like the consumable area
this code for checking if the played hand is a High Card isn't working:
if context.before and next(context.poker_hands['High Card']) and not context.blueprint then
what should it be?
I may be clueless
but I'm letting my jokers (with a custom rarity) start showing up in the shop
but I just keep getting a bunch of jimbos instead
oh I think it's this
although technically nothing should be in there...
Ah alright then it prob doesn't unless I messed up something with how I set up the alt texture, it properly replaces it on the joker menu 🤷♂️ so those other menus must do it differently or something
thx for the help regardless
I'm trying to make a custom sound, but it gives me an error when its supposed to play. Am I missing anything? The code for the sound and the code for the joker are in the same file, if that helps at all.
if context.before and context.scoring_name == "High Card" and not context.blueprint then probably?
will try, thanks ^^
works!! :D
sorry, one more question
is there a way to destroy all cards held in hand?
hmm
use context.destroy_card, and do smt so that it knows which card should be destroyed, like storing it in a var or smt
this is what i did
thinking to make a high quality deck mod with a couple of my ideas to add new ways to play balatro
mhm, good luck with that!
ty
-# without the "!" i sound so rude for some reason 😭
I'm feeling like I'm getting trolled
why is jimbo showing up 😭
r u using by chance itemremover?
I found the issue. Turns out I put the ogg file in the wrong place 🤦♂️
debuff cards
nope
ohhhh yeah
I'm trying to make a specific rarity of cards (a modded one) show up in the shop
but it's just adding jimbo
he's mocking me
who's the real fool now, I suppose...?
I reverted all of my changes but it's still happening 😭
What does this error mean?
i feel like i've seen that error before but i can only think of your sounds that are being used as music not having the "music_" prefix to their key, but idk if thats it
are you making it so only that rarity shows up in shop? because jimbo shows up only when the game fails to load in an appropriate joker.
Do you have cards of that specific rarity already implemented? If not, implement a few to see. If so, maybe try turning up the weight by a lot instead of not allowing the other rarities to spawn at all?
No, it's just supposed to show up alongside the regular ones
do you have jokers of that rarity already?
assert(SMODS.load_file('file_name.lua'))()
How do i create a button
it seems like there's still a 'bug'
when card procs and upgrades it doesnt give xmult
but it supposed to upgrade, display message and then give it's xmult
make a button
hope this helps!
return {
message = localize('k_upgrade_ex'),
extra = { xmult = card.ability.extra.x_mult }
}
A bit of a complex question
Is it possible to program it so to have a button which could enable or disable specific cards, tarots, blinds, etc from appearing?
make button that adds or removes the cards from the pool
Ye, how would I do that?
i do not know
this is retriggering every played card, not just the first and last scoring, anyone know how i'd fix this?
Wait nvm found it
https://github.com/Steamodded/smods/wiki/Utility
if context.other_card == context.scoring_hand[1] or context.other_card == context.scoring_hand[#context.scoring_hand] then
Uhh how would i position this a little bit above?
ty
add an offset to the UIBox
config = { align = 'cm', offset = { x = 0, y = -1 } }
yeah i was so close in figuring it out but it was just a piece of code required i didnt know existed
so i wouldve never gotten it
nothing's changed
card upgrades but doesnt give xmult after
If you are storing the name of a deckskin in a language file
Is it stored in collabs like this or somewhere else?
UPDATE: figured it out it just needed to be a number value
I keep getting a table index is nil error so I assume not
Ah, this is an enhancement... uh, not exactly sure then. 🤷
Shouldn't you be returning this too?
The extra should execute after the "message" bit, though.
Like, as I read it, if the probability thing hits, the message gets sent and the extra thing gets updated.
Shouldn't you return xmult as well?
Maybe?
Not sure.
apparently, card.ability does not contain the key for the enhancement?
Tell if it works idk
I haven't worked with enhancements a lot.
well it's goes right after it, no?
nope
Should, as you can have another extra inside of an extra.
like how that would look like?
card.ability.extra contains "Lucky Card", but what I need is "m_lucky"...
why isnt the deck here
like this?
im an idiot
The initial return can be considered an "extra" table itself.
The return is a table of effects to do. If you want to "chain" them, you add an extra table with its' own set of effects.
all I want and quote 'make it so that after sending an upgrade message, card would give it xmult'
that's all
Does it give XMult when not upgrading?
yes
i forgot to save the art lmao
oh wtf now big cards are giving x2 chips again. they can't make their fucking mind up on if they should do that or not im so confused
You should probably move the entire giving of XMult outside of that block and only do the chance check and upgrade separately.
testing out blindcalc, can it not use non-blind contexts like final_scoring_step yet?
OHHHHHHHHHH it's h_x_chips, it's not getting caught by the check for values starting with x_
wdym separately? The code checks chance and scales mult
why do I separate them
i'm confused :(
local upgradecheck = false -- set a temporary local variable
if chancecheck then -- do the chance roll here
upgradecheck = true -- upgraded, set this to true
card.ability.extra.x_mult = card:scale_value(card.ability.extra.x_mult, card.ability.extra.change) -- do the value change
end
return {
message = upgradecheck and localize('k_upgrade_ex'), -- if our temporary variable is set to true earlier, the message should pop up
xmult = card.ability.extra.x_mult
}
If I understand these function correctly if I put the key to a custom joker, tarots, stake, whatever I could add or remove things from their respective pools?
hey guys the crash log keep saying "[SMODS _ "src/utils.lua"]:1240: attempt to call method 'juice_up' (a nil value)" and im to stupid to get whats wrong AAAAAAAAAH
You should not need the card = bit... especially not if it is card = self.
so i just remove it? im new to this and never codded before
Yeah, just remove.
why isn't this setting the hand size to 12?
it its give me juice_up error is there another thing i should remove?
The other card = self, too.
omg im soooo blind
Is this correct?
message pops up but now not only it doesnt give xmult but it also doesnt upgrade
I do
there's like 20 of them lmao
Is there a way to iterate through unscored cards?
just to confirm, food jokers isnt a real definition for jokers in basegame? aka i'd need to define that list?
i cant find much of a way to differentiate between scored and unscored cards
correct
not to my knowledge
hmm ok
there's an optional feature for the unscored cards "area"
how would i uh...go about doing that
go about doing what
making the list and being able to call upon that list in a joker's effect
shouldnt this code work?
would be a bit easier to read if it wasn't in the Blue Zone
you got your return table wrong, and you have checks for different contexts nested inside each other
Well you could just define the list as one of the joker's vars and get a random element from the list and calculate their effect
oh okay
if context.individual and context.cardarea == G.play then defines one context (on card scored)
if context.destroy_card and context.cardarea == G.play then defines another (destroying scored cards in played hand)
to destroy then card in context.destroy_card, you should be using return { remove = true }
if other_joker_ret then
other_joker_ret.card = context.blueprint_card or self
other_joker_ret.colour = G.C.RED
return other_joker_ret
This is blueprint's way of copying an ability, with other_joker being the selected joker, im not sure if smods has changed the way this is done tho
thank you! that makes sense
we have SMODS.blueprint_effect
this is the plan, not even really sure where to start though
Oh
yeah
ig
so why isnt this working?
@frosty dock mr aure how do i check if a card belongs to the unscored card area?
Well, I've written it as how I'd do it with a Joker... I'm just not sure how the enhancements work. I'm pretty sure there's other mods that did something like this that you can take a look at? Apologies for wasting time...
context.cardarea == 'unscored' if you're in a context where that card is being evaluated directly
what do you mean by evaluated directly?
where it's provided directly with context and you're not iterating some list of cards to get to it
all good
thanks for helping anyways
so in something like context.before, iterating through every card and checking for unscored wouldnt work?
does blindcalc support checking contexts that aren't specifically made for blinds yet, or is that still a work in progress? currently i've only been able to get blind-specific contexts like press_play working with calculate
it works btw thaaanks
like, for example, if I wanted a blind to trigger after all cards have scored and animated, via context.final_scoring_step
is this better?
gros michel and cavendish
and gros michel and cavendish, technically
Nah the issue is is im looking at the lua help page on tables and i dont even know like
How to make one
It really doesnt explain it well for complete idiots like me
{ "value1", "value2", "value3" }
i tried it and its still not working
sometimes i wonder if the number of modders is higher than the number of mod players in the balatro community
i think in this case they dont know how to fill it with jokers







