#💻・modding-dev
1 messages · Page 267 of 1
THIS VERY LANGUAGE GOES AGAINST THE GRAIN OF EVERYTHING I HAGE EVER LEARNED
HOW DO YOU
DEBUFF A JOKER 🥀
i was typing Too Much there
im gonna check crimson heart or whatever :(
i used py in class and i kept fucking up 0 indexed lists
Isn’t “saw” in the past?
and “broke”
list indexes are the lest of your concern in lua
oh
hey guys can somebody help
so how should i handle this
just check if #g.jokers.highlighted == 1?
There’s actually a werewolf hidden inside each Lua program
well thats annoying
i don't get where the config values i put are stored (in-game)
That’s your biggest concern
before trying to manipulate it
god the new discord ui sucks ass
Why are you trying to manipulate them?
they are not in G.consumeables.cards[1].config
all lua programs are built with blood, sweat, and a controlled substance or two
i'm trying to understand a bug
In a card, that isn’t a prototype, it’s “ability”
Not config
two actually, one adds too many ends and the other is yuri
yuriwolf
I don't see why this would per se cause this, so I assume it might be that there is different information that the use_card function assumes to be true for booster packs because technically they only open in specific contexts. Does the behaviour work properly if you use the consumable in the shop?
I think you can only open a pack while in the shop or selecting a Blind
So maybe transitioning from another state is broken
tweakin out before finding out it's 1-indexed and then tweaking out figuring out why != Doesn't work 🥀🥀🥀🥀
i tried doing -=
SHIT I FORGOT IT WAS ~=
my first lua error was !=
me when a += 1 doesnt exist:
real i tried modifying the joker buffer with -= 1
GLua literally just readds != for people used to other languages
Real
i’m too used to godot
hello
gdscript my beloved
idk i somehow understood ~= immediately
hello
im notg brit
It’s used in logic I think

‘Ello guv’nor how are you today
that looks like a definition
❤️
that looks hellish to read
lemme check if it does
i have made an esolang before
and honestly you should be executed for making the suggestion /lh
hi guys how do i fix this 💀
I THOUGHT THIS WAS RHYTHM DOCTOR PATTERN
also me and a group of friends are making fucking exodia in balatro
or something like it
did someone mention rhythm doctor
my sprite size is 95x71
rhythm doctor?
i love rhythm doctor so much
the black background supposed to be a square
it’s 71x95 broski
Do the base and soul sprites have different sizes
all same sizes
doesnt work properly in the shop either
is there a way on how to know which toml file is used to patch game files?
Then you probably put the wrong sizes in either the atlas or the Joker
pov: the charter is lazy
x------
Sometimes I forget that time exists while playing or modding Balatro
They cured the Ain’t Got Rhythm guy
oof. I'd recommend looking into the tag logic, see how they call it. I can check as well, later
it's good
I barely even notice a difference
just now i couldent type anything
alternatively, pov: the charter is a sadist
xx-xxx-
I'm buying FL studio 24
good idea
can you buy me lunch while you’re there
you know what
i put correct sizes
idk why its broken
😭
can someone check something for me on the latest official smods release?
I'm going to buy winrar while I'm at it
Which variable did you use
am i supposed to use something like pixel size or display size
winrar in the big 25 is insane
use 7zip people 😭
how would i juice up the consumable card im trying to use (like hermit when doubling money)
(i use 7zip)
i put correct size for atlas
apparently self:juice_up(whatever) does not work
I’m asking about the card
card
Not self
99% of the time when using SMODS
Card is the card
Self is the prototype
I want the winrar bag
5 mins too many
friends has one
Like the people self-flagellating to purify their sins
display and pixel size?
but not really because i don't get why self.config.limit does not give me the limit, instad giving me nil
Yes
card_limit
There’s no self
i put it both w = 95 h = 71
no, like. i'm just doing a hermit esque card
Jimbo is Buddhist
just like the atlas
is there a way on how to know which toml file is used to patch game files?
G.whatevercardarea.config.card_limit ?
Maybe one shouldn’t
wait wdym
What do you mean
Try only setting one variable and not the other idk
Then swap
Then go back
Based
so like would i do it G.consumeables.card[area].config.limit?
what mod causes the error (except for talisman) 💔
hiiiii modding devvvvvvvvv i've got another question ^^
can I post my own mod on the mod manager
jetbrains ides are the best
omg ghost
okay
still trying to get my animated card to work, have i done something wrong?
hai :D
Animated atlases on cards don’t current work AFAIK
There’s a PR for it though
Well
They almost work
But something breaks
And no one ever fixed it
ah
this
but
Applied (n) patch in file.lua : (path of the toml.file that patch that file.lua )
You could read the dump and work from there
ya it's this error
how would i do it then? if self does not exist, where can i get the variables i set in the prototype config
The issue was how you accessed the area incorrectly
….area works
Actually wait
What are you trying to do here
The first part doesn’t make sense to me
no clue
my main goal is just to make a hermit esque effect
so i have this hermit-esque card that has "limit" in config, which is set to 30
i guess i can't do it right now, then ^^ unfortunate
trying to access that
inside the use method
i think you might want to check jimball from Cryptid
card.ability.extra.limit
okay
That’s custom made
wait
There’s also Aura
why does my joker mult increase by 1.5 ingame
if context.cardarea == G.play then
card.ability.extra.x_mult = card.ability.extra.x_mult + 0.5
return {
message = 'Consumed',
colour = G.C.RED
}
end
Which I think is Jimball polished
i set it to 0.5 only
The mod
it's being run 3 times
And there’s the aforementioned PR
yeah but you didn't check for other context
What’s the config
looking at jimball's code, i've got no idea how it works 😭 there's nothing about animation there
The part that changes the location of the sprite in the atlas
I don’t know if you exited the game and came back if the card would work
Exactly
ah, that's in a different script then, will search for that
since if you re-enter the run, i think all cards are made anew according to new information
Yes
oh. wow
im stupid
sooo the better way is to probably mark the joker with something
i created the card in a save file before it had config
-# wait
im my worst enemy
At least you’re not your best enemy
But it’s true
You need to add a variable to the card itself
i was actually talking about my mod lol, but yeah
In general
wait u cant do this?
card.ability.extra.xmult += xmultgain
no
my code error when i do
Like when you want to destroy it later
lua doesnt have +=
???
fr
???
when i was coding in roblox all the time i used that
🪫
Americans when they learn they speak other languages in other countries:
rest in piss 💔
Maybe Aura would help more
right
okay can i assert SMODS.LoadFIle
and then load my files that way
because im about to break up my code into multiple files to make it easier on me
How do I retrigger a card until it meets a certain condition?
just have it in a loop thats checking for the condition and if it isnt met retrigger
this reminds me of uno
draw until you get a green card
xD
nobody answered me
shoud i be able to
assert(SMODS.LoadFile()
and if i do
is the path relative to project root
got it
so, question about Aura
do i use it as a dependency, or put its code in my mod?
use "/"
Well having a while statement under context.repetition crashes the game somehow but I may be dumb
and this is relative to the project root
why is my thing nil
i am cooked
i have it defined right here
so if i have PROJECT_ROOT/src/jokers.lua
i would do
SMODS.load_file("src/jokers.lua")
pretty much
alright good to know
font is very questionable
?????????????
SMODS.load_file returns a function and maybe an error btw
balatro looks so different like that
so youll need to call the return result of the function
@zealous glen you'd started messing around with the new boss blind update, right? Are there any contexts that don't work for boss blinds?
nah
idk if you can stop the ui text from dying but you can just not undo the effect
additionally you can manually debuff all blind disabling jokers as a hidden part of the blinds effect
ya i've got no idea what this code is doing either 😭
that wont work for modded jokers
0 is even
this is my mod description
just have a big table of all the modded jokers that disable blinds youll probably wanna look into how the ui text is removed
so you can undo that
hhhhhhhhhhhhhhhh
what is this
hey so none of my files loaded
what do you have so far
what they do
and a new consumable
id show you if tyhe files loaded..
😭 i love her
card.ability.extra.x_mult = card.ability.extra.x_mult + card.ability.extra.x_multgain
why does my game crash and tell me x_multgain is nil even when i put it in config
config = {
extra = {
x_mult = 1,
x_multgain = 0.5
}
},
show code rq
what does the loading code look liek rn
is that zundamon
sure is
ends the program if the condition isnt met
Is there a way to retrigger a card without if context.repetitions then return {blalblabla}?
okay i know the issue
wow peak skin
SMODS.load_file returns a function that when called actually loads the contents of the file
is this accessed when i use G.GAME.blind.resistances?
this is how i do it
so you need to do SMODS.load_file(path)() or something like that
not without a lot of effort. How so?
i just do it like this
let me try that
ughhhhhhhh i can't see what does what in Aura's codeeeee
DO I DIG FOR STRAIGHT FLUSH
just gonna not bother for now, maybe i'll be better at Lua programming later :}
alr there it goes
ROYAL FLUSH
ROYAL FLUSH
DIG DIG DIG
99% OF GAMBLERS QUIT BEFORE THEY HIT THE JACKPOT
good enough
straight flush already wins so you can just burn hands and discards to try get a royal flush
you gotta
hhhhh i'm upset i've asked for so much help for my mods :<
too late
worst thing ever
gnome user detected
aiko, bepis, do you two happen to know which calculate contexts work for blinds and which don't?
uhhh
i just guess
haha, maybe I should just do that
context.before, context.after, context.final_scoring_step, and pretty much all other contexts that u think blinds can do :3
I guess I can make darth vader choke you out before you score, instead of after
i fixed the problem of it not being in the joker areas btw
u can use context.before for that one, they fixed it
minor splling mistake ❤️
3 phases, allat passives, time to change some stuffs and im gonna push it
wtf is 5枚のカードをプレイしなければならない
whats that

ok it's just psychic ig
5 cards must be played for hand to score
aseprite cli doesnt add length limits so my sprite sheets are just long
Because this crashes the game
What is the proper way to do it?
what is the crash
what's the crash that it gives?
Oh wait
trying to figure out why my config is not getting copied to the consumeable table
😭\
can anyone help
Of course it crashes cause normal cards don't give lucky trigger which causes an infinite loop
idk the exact effect youre going for but idk if youre gonna want while here
i'm doing everything right, am i?
config = {
extra = {
x_mult = 1,
x_mult_mod = 0.5
}
},
calculate = function(self, card, context)
if context.cardarea == G.play then
card.ability.extra.x_mult = card.ability.extra.x_mult + card.ability.extra.x_mult_mod
return {
message = 'Consumed',
colour = G.C.XMULT
}
end
end
WHY IS THIS IN ENGLISH WAS
the game says that x_mult_mod is nil
Retrigger a lucky card until it gives a lucky trigger
this should make it so that the boss only spawns at ante 8 right?
YOOO my guy experiencing the same issue as me
help im gonna die
Darth Vader blind works, just need to make a pleasing indicator for 'm
you have to check if its actually a lucky card before it goes into the while loop then
should fix it
u too?!
Am I going to make a hand that floats beneath the joker, to indicate it's being forced choked?
how do i get a pseudorandom number between 0 and 1
why cant you just
use any other var names that dont conflict with what smods is using 😭
...
thats exactly what it does
oh
🥀
oh my godf
wait your not supposed to do that?
how do i get the game seed so its actually a bit random
dunno, but its best to avoid that
I tried but it just retriggered them once but let me check again
you can use any seed, as long as its unique and not used by anything
pseudorandom("good morning sunshine") works
i mean, that's still inside the EXTRA table
so that can't be the issue
ok now why the fuck
it's generally good practice but it's not the issue for them
uniquenamethatsmodsdoesntuse = 0.5
afaia
lets test this
wtf why does empress look so cool
@manic rune 💀
hello :3
are you
i am concerned because it does not have localization
^^
on the same run?
yes
make a new run, and try it again
oh yeah btw you have to change runs
okay
oh
whats the highlighted joker again? g.jokers.highlighted[1]?
The ones I’ve tested worked
G.jokers.highlighted[1], yes
it still didn't fix the issue for me though
dang
alright just double checking
whats your joker code looking like
yeah, i solved it, I misspelled things because of course ❤️
use = function(self, card)
G.E_MANAGER:add_event(Event({
delay = 0.4,
trigger = 'after',
func = function()
local bank = {}
for i = 1, #G.jokers.cards do
local joker = G.jokers.cards[i]
if (not joker.ability.eternal) then
table.insert(bank, joker)
end
end
local joker = pseudorandom_element(bank, pseudoseed('infinity'))
local sticker = SMODS.Stickers['eternal']
-- add an eternal tag
play_sound('gold_seal', 1.2, 0.4)
joker:juice_up(1, 0.5)
sticker:apply(joker, true)
-- double money
play_sound('timpani')
card:juice_up(0.3, 0.5)
ease_dollars(math.max(0, math.min(G.GAME.dollars, card.ability.extra)), true)
return true
end
}))
delay(0.4)
end,
it can't find card.ability.extra
config looks like this
how do i replicate a joker
i was inspired by thunk
just use extra = {smt = ...}
(thunk used those like that for every consumable 😭)
and use card.ability.extra.smt instead
i know, i just have it like this for now just to not change runs
im lazy
it should not change anything
how do i duplicate a joker
im reading https://github.com/Steamodded/smods/wiki/calculate_functions but it confusin
what do you want to do
do i just add card with whatever id the selected joker is
check hex's code
trying with the change
when card is played +0.5 mult then destroy that card
but it trigger 3 time like u said
weak ahh card tbh
why can nobody give me a straight answer dawg
but context.individual and context.cardarea == G.play
and also it will add chips x10 the amount of the card
off i go
i suppose
still like this, no
rip
whats individual do?
copy_card i think
wait, do consumables even have extra?
copy_card is vanilla function
dunno, tried it without extra it still does not work
plus, yes they do
mmm
for some reason my extra is not in the ability.consumeable
There are few straight answers when it comes to this stuff 😭
unlike all other tarots
if im correct
context.cardarea == G.play
this triggers everytime a card is scored right?
You also have to have context.individual
what does that do
can you try printing G.consumeables.cards[1].ability.extra
hermit:
local card_ = copy_card(jokerplace), nil)
card_:add_to_deck()
G.jokers:emplace(card_)
alright
death
judging from this, consumeable just isn't config for some reason
which it should be
something aint ading up
wait what is context.main_scoring 💀
It goes over individual cards
for card effect i believe
beautiful diagram
gangg what is wrong with this one😭
Did you replace jokerplace with the joker that you want to copy?
and yeah this outs nil
btw this reminds me of inconsistency abt smods calc
smods' calculate_context (aka everything except the actual main scoring) calcs jokers first THEN playing cards, when it should be the other way around based on how the scoring thing works
im going to go eat dinner i cannot take this anymore
"smods context thing" is basegame for the most part though
i wonder, has anyone tried to untie the movement of objects from framerate yet
i gtg somewhere i’ll come back to it
as in like, fixing the thing where if the game is lagging too hard, the card movement becomes rigid and jittery
or the other way around, forcing that behavior when the game is not lagging
is there a base funciton to have blinds put text on the screen?
attention_text?
oh damn wasn't even familiar with that function, that's super helpful
I assume hold is the amount of seconds the text'll stay up on screen?
Where are glass cards defined?
Where does it check to break?
how many elements are there in the mod?
aaaaaaaaaaaaaaaaaaaaaaa
7, the same as hsr
its a reference to how bosses have different element resistances in the game :3
idk if i love or hate this
What's your UID Bepis
on one hand this is absolutely insane on the other hand its absolutely insane
823312155
I fully assumed. I like the concept. I was thinking how hard it'd be to get a little visual display somewhere in the UI there 🤔 with 7 max, it'd probably be possible to display all of them at the same time in the width at least. Though I don't know where I'd say the space is there, on the ui
ty :3
well, i can just reduce the size of the text themselves if i want to fit more passives :3
smods seems to overwrite it
Yeah, that's in the hover_over UI, right? I was imagining something underneath the blind. I was considering making some blinds that buff or nerf certain genres, and how I'd make that fit in a ui box somewhere on the left of the screen. Or whether I'd want it to be on the jokers themselves with some indicator. If I end up doing that, and it looks good, I'll send you the code for it, haha, if you'd be interested
why am i online again
|Oooh, I didn't know that existed! That's good to check out
Is there a thread with library/api mods?
acctuallyr eally cool implementation of the boss blind
So I have a little problem. I want to retrigger a Lucky Card until it gives a lucky trigger. Since you only can return stuff once, this code retriggers Lucky Cards only once (No matter if the third if is a while statement or not). context.repetition doesn't happen again after a retrigger. So what do I do? Should I remove the return and write the entire retrigger code? Bad idea I guess
i will probably add lib/api mods to #1349064230825103441
there are some in the modded wiki
imgonna crashout
oh, that'd be great, yeah
i need to follow my old threads lol
Also, I was visualizing something like this (i used the hsr elements because I don't have icons made for the genres yet), to illustrate. Ignore the thematic clashing going on 😛
there is a context for it!
Another way would maybe be to somehow predict the amount of repetitions needed until a lucky card get's lucky but I don't know how to do it if it's even possible
Aw, I can't add you
context.destroy_card, I'd check the wiki for the specifics before I end up explainining it wrong on accident, haha
wait what
context.destroying_card
I’m building a balatro arcade cabinet using a vertical (portrait) monitor. I plan to use DisplayFusion to split the monitor so Balatro is in 4:3. the remaining real estate (above the play field) is still open for “something”. I looked to see if anyone made a high score database/tracker. I’ve also considered some kind of replaying video or the Balatro joker site that lets you see all jokers and their stats.
Any ideas? I am now looking into making the high score setup myself. Basically some kind of middleware that captures the high score at the end of the game and inserts it into a database that can be displayed in a web page. It’s super basic of an idea though. My scripting skills are fine, my runtime skills are meh. Any suggestions on other channels or discords to ping on ideas is welcome as well
I have been thinking logistically how this would work and I think my query is, if I wanted to capture specific details about a run in the game (highest score is one) is there a way to pipe this over to a flat file for testing? I am a little outside my league when it comes to mod dev, I am an IT person but not experienced with mods. I'd also be willing to put a bounty up if that's the proper way to go about this
so do i just
the code is visible, and with smods and lovely, you could easily inject some code to output your scores into a file, yes!
I reckon you're approaching the project like this is a game where you'd need to read the binary to get high scores out of it, but luckily everything's very exposed!
Guys, any idea? Would really appreciate it.
I haven't looked into how the seeds work, but you could look into how seeds are used so you can predict when the next hit will work out
I know @ larswijn was messing with recursive retriggers, but apparently there's some logic issues that make that something that's not very easily done
Oh cool! Ok. I'll start researching more. Thanks for the heads up
That's what I found but it sounds very difficult. Well there porbably is somewhere something about predicting pseudorandoms online
You'd probably have to look into the engine code for that, yeah. The other option is to look at how vanilla and smods do retriggers, and see if you can patch or hook into something
I'm curious, let's pretend this is outside my normal wheelhouse of IT related tasks, would putting some kind of offer out to pay someone to create a mod be reasonable?
balatro goes kino
They just return the repetitions, haven't seen something else yet. I maybe just search for it on the net
HUH
Nothing unreasonable about that, I think. I assume that if you're not doing anything for profit with the cabinet, there's no issues anywhere. People do art commissions for mods, and I think some mods have some commissioned work as well
aikoyori's shenanigans
first idea thats probably not that good:
make it return a lot of retriggers, then patch the function that does the retriggering to mark when lucky card triggers within one of those retriggers, and make it so all the further retriggers in that calc for that card from that joker are ignored
shucks, ur on europe server right?
America server
im actually planning on playing again over there, since its getting boring over here :3
pretty clever patch work, I'd say!
icic, i will tell you when i start playing on America server :D
Just for my arcade at my house. I build and setup various adhd fueled projects regarding cabinets (driving and fighting for example) and I am going to make a casino esque cabinet for balatro to add to it. At this point the idea is just to create something that augments the 4:3 playing field above, but my ideas include things like having leds ramp up color like the run flames do, or more. I would definitley make the idea public somehow to inspire others and maybe give some ideas. I already bought an actual casino door assembly for the bottom with a marquee.
...oh, thats actually cooler than mine 💔
Like starting over
well i want smt else to do lol, at end-game theres really nothing else other than just hop in, grind for a few minutes then out
Basically this in Balatro form https://g3newswire.com/wp-content/uploads/2015/01/AinsworthRumbleRumble_A560-SL.png
oooh very sick, definitely make a yt video about it if you get that finished up. That's all super doable. I don't know much about hardware, but setting up an interface is dead-easy with how open balatro's code is
The chrome bottom I already have.
the smods function you'd need to patch is SMODS.score_card
Unfortunately, but I don't think I'd enjoy playing the story again, and it's not skippable
very fair point, i hate that too 😭
is jokerdisplay an api mod
...maybe?
this is probably too much work but i feel like having a mod that changes the ui to portrait mode would be perfect
hey der, i'm poking around the UI_defintions.lua to try and move the position of the deck in the UI (the card back location). could someone point me in the right direction?
I assume something changed in the blind code with the new patch making this break. Anyone got a clue?
like those balala things
I think when the G.deck area is created, it's also placed by a function a bit later. You'll wanna check that
could someone tell me the reason this doesnt recognise this enhancement?
playing_card.ability and playing_card.ability.effect == "Hazard Card"
I have tried using the name or the key but it isn't working either way so idk to do
you want to look at set_screen_positions() probably
what key did you use?
modded enhancements use keys instead of vanilla-like aliases
m_poke_hazard, the enhancement key
did you manage to figure out your boosterpack issues, Kawaii? Or Rerun? haha
Nope, left it for another day, but that’s ok, Rome isn’t built in a day :3
Hardware will be simple enough. Cabinet seems straightforward. The door will add a ton of cred to the idea that it is a video cab. Even capturing the flames on the monitor can be done with something like SignalRGB right out of the box.
If I can get some mods to add to the look and feel (and playability) of a high score display (and really that's open ended, there's probably a lot of cool things that I am missing) then it should come together nicely.
I need to find a way to offer a bounty for this, while I probably could hack something together with enough time, I think paying someone to do it with experience seems more advantageous. Then I can just make it public in a proper fashion and let others try the idea too
Oh and you can just call me Cleo, tbh I’ve been meaning to change my username but I can’t think of anything that has stuck
playing_card.config.center ~= G.P_CENTERS.m_poke_hazard if you want it to for sure have the physical enhancement. SMODS.has_enhancement(playing_card, "m_poke_hazard") if you wanna make it compatible with potential quantum enhancement implementations!
Hmmm don't know, I'll first maybe check how predicting pseudorandoms work
I'm available most of the day, so let me know if you need some help with it! 😄
my instinct is to just have my name be what I want people to call me 😛
Here or the smods server maybe, I don't know what the policy for commissions on this server or on discord generally are, though
This worked, thank you
yeah me neither. I'll find a way to organize my thoughts into a cohesive goal. Is using github as a landing page for the idea reasonable? Seems as much
I can make a who what where front page on github, make some mockups etc and then have the code backend for managing other aspects
github's the main way mods get spread around
cool i'll start with that, thank you
nexus mods....
if you have ideas but aren’t ready to code them yet
ewwwwww
truly
Nexus Mods, where the tagline is ‘you want some website with that ad?’
im pretty happy with how my mod is turning out
and so far - still NO lovely patches needed yet!
:d
i’ve been doing good
i wanna do 50 jokers
That’s valid, I guess I just don’t know what that is yet.,,, besides my actual name

The custom blinds are crashing my game but I don't know why
at least
and 24 ritual cards
i have 3 ritual cards pretty much done
and 5 jokers
me but for the entirity of letterboxd
me but for the entirety of pokemon
Idk if I’m free, I have. 2500 word paper and a local tournament tonight
-# wdym pokemon 😭

i might make a joker that interacts with a vanilla joker
let both of those take priority 😛 good luck!
Tyty!
nostalgia critic joker that gains x6 mult and destroys the credit card if it’s there
thats what i want to do but someone else started before me do im stuck with ygo
‘a JIMBO CREDIT CARD?!’
(im joking anyway)
❤️
currently i strive to make my mod as quality and packed as your mod and myst's
what if i added a joker sticker that switches it to a random joker every round
what if you did
call it ‘indecisive’
The dream is to make a mod that feels as polished as joyousspring honestly
same...
my goal for this mod is to dismantle vanilla meta
i’m gonna fuck shit up so much
that you have to play with the mod to make it work
my goal is also to make everything in vanilla balatro have some sort of use
through jokers and relics im gonna add
currently, all enhancements are useful now, that includes bonus and mult cards
has anyone ever added the tarot cards that aren’t in major arcana
i want to start doing more of this too
my jokers are too independent
that’s what i plan to do
like the credit card one
it activates on the credit card existing
I wrote some notes on the types of archetypes I could find in vanilla, and made sure to add at least one movie joker that focuses on each
though I don't have a skipping blinds focused on or tag focused one yet
how do i get the amount of cards held right now?
#G.hand.cards
and how to check if i'm even holding any
i... how does true end up in this table? where am I going wrong with this boss blind?
#G.hand.cards > 0
thanks!
bepis have you pushed any of your blind code to your git?
i'm back againnnnnnnn haiiiiii
hai :333
this code didn't work:
info_queue[#info_queue + 1] = { set = "Planet", key = card.ability.extra.chosen_planet }
my Joker changes planet cards, and i'd like to add a tooltip for its chosen planet
and there are still some stuff i want to polish, like how jokers get immediately debuffed with no juice_up + eval_message rn
how should i do that?
her sprite should just be stock chicken png
i'm getting this crash but I can't figure out why. I think it's because I'm still formatting something in the pre-blind calculate context set up
so true though...
[card.ability.extra.chosen_planet is formatted like, eg., c_pluto]
can you show me your blind's code?
ah icic :3
this is the one that's crashing it, but I suspect that's because of the alphabet, mostly 😛
what is your code?
Oops I'm lagging
i'm aware I need to add a math.floor there, btw, haha
i actually havent used modify_hand yet, so im not sure if i can help you with it 💔
it's in the code that picks the new boss blind.
but it's not the modify hand that's breaking it
it's the fact that eligible_boss[k] is true, rather than a number
but fuck me I don't know why that's the case
this is continuing from a save state, that's a good point
let me try a fresh one
How could one change the loc_txt of an enhancement if a joker is present?
Look at how invisible joker adds the negative tooltip
When you have a negative one
for i=0, #G.hand.cards do
if SMODS.has_enhancement(G.hand.cards[i], 'glass') then
return true
end
end
is this the right way to check for glass cards in hand?
if there are any
i should be equal to 1.
oh, yeah.... lua...
Is it possible to hit Talisman's max numbers? Like, before the game crashes
you can actually just do
for _,v in ipairs(G.hand.cards) do
if SMODS.has_enhancement(v,"m_glass") then return true end
end
and also, im pretty sure it should be "m_glass"
I suspect it's because I spawned a blind in, I'm not having issues in clean runs, or using the boss rerolls function
oh and yeah check out the cool card
LOL KINDA
so the mult and chip is only at common_events.lua and nowhere else?
I'm trying to make a joker that makes glass cards not break and I want it to remove the thing where it says 1 in 4 chance to destroy card
oh btw where would i find the joker code
for example shoot the moon
where would that be located
card.lua
Yes.
thanks
balala
lalaba
lalala
@hushed field well, made a mockup at least
jimbos arcade machine
how do i replace the showdown music with something else for a specific blind?
Anyone interested in discussing a bounty for some mods for the project I posted feel free to dm me.
it's non profit, just making something cool
woah
this doesnt really explain
can smoeone help explain
i wanna destroy card upon benig scored
Is this possible to do?
yes although tbh idk why people add them as just extra tarots when minor arcanas are a valid playing deck on their own
maybe u have to
find where balatro calculates the glass card breaking
and change that
paperback added minor arcana
I've already done that part.
I don't know how to remove the text.
like its literally just the standard 2 to King deck with the only major mechanic difference being 4 face cards instead of 3
oh
when will i have ace of pentacles
like in glass card descriptio/?
Yes.
i read that as tentacles for some reason
💔
very creative
'Creates a random consumable or joker at the end of shop',
how
i love when i ask a question then realize the answer right away
i swear 75% of my questions are that
yesterday i was halfway through writing a question and solved the problem before hitting send 😭
🔥
uhhhhh
im really unfamiliar with the code
I mean, I've been working on a sticker, and I know there is a SMODS.Stickers table that has all keys to stickers
including my modded sticker
bump, i need to know
idk
help
alright
insightful of you
good amount of blinds in there. In the future I wanna update the xenomorph blind's drool to be animated though
ill try finding it
that would be really lovely
a lovely reference!!
game.lua has mentions of sounds in there
that helped me a lot with patching and hooks and just generally referencing code
i just extracted a zip from balatro.exe
i dont know the best way to do these things but perhaps check the play_sound function
did u check sound manager
and patch that
where is the sound manager
have u decompiled the game
i open it in vscode and do ctrl shift f to search all files
u can do that???
wow
?
there is a file called sound_manager.lua that defines a function called play_sound
card.lua contains many play sound functions
are u looking in the SMODS repo
you gotta decompile the actual vanilla game
(bump)
the sound_manager file
thanks
and that contains play sound, so you could probably reference that and patch it
card.lua doesnt contain any play_sound with multhit
whats your code?
like how
tell me
yeah exactly
code is provided
like can i see loc_vars in its entirety?
ah kay
just in case
how to patch it?
yeah if i patch the play sound instead of the mult
im not sure how actually info_queue works but the example on wiki just gives a key like this
i found some
it kind of looks like ur doing that tho (not sure how set = "Planet") works
in ui_definitions
ill try that
idk if it works
you could do that too yea
i was gonna suggest patching the play_sound function itself
something like this in my code
there we go, here's an example where i used that format successfully
there is a function called prepdraw, which I changed the behaviour of by overwriting it with an extra parameter called check
so if i want to use this modified version I can pass true as the last variable
ah wait, lemme try doing this? maybe?
in this case play_sound is a global function so you can do it much the same way
Idk if that will work
dfjkngdfkjgnkjdfng sorry to bother 😭
ngl why don't you just hook play_sound
what i might do is literally put some if statements that check if its "multHit1" or "multHit2" and if it is, then call the original play sound function with your sound
how do you patch play_sound though, i can just type the same thing with the play_sound(multhitblabla)
why don't you use SMODS.add_card
in my case since I wanted the original function still I made a variable called prep_draw_ref = prep_draw before changing it
same function
that exists?
ok wait i gotta go read documentation
thanks
and if u look at my code, if "check" is false it just calls the original function
nah doesnt work
rip
so perhaps pseudocode for you would be
play_sound_ref = play_sound
function play_sound(whatever the parameters are idk)
if multHit1 were passed or multHit2 were passed then
play_sound_ref(your sound)
end
end
if i do add card i can just write any card name in there
something like that would be how you could hook it
and it will create?
can i use that?
yes
yea go ahead ofc
I want it to be the first image when the joker is not present and the second image when it is.
wait so
hold on
its pseudocode ofc so you gotta make the if statement and paste whatever the parameters are
payload as in?
but whats the target
not familiar with that patching
you put this code in your mod, and play_sound is a vanilla global function that is already defined
@lament agate this will be useful to you
https://forums.kleientertainment.com/forums/topic/129557-tutorial-function-hooking-and-you/
In LUA, it is a very important concept to understand that everything is a variable and all variables may be edited in runtime. This includes functions. With modding other peoples' LUA files, like Klei's basegame code, you may find yourself wanting to run your code before or after the original fun...
how would i add random cards tho
yea this will explain it better probably
ill check it out thanks
omit key, use set and rarity instead
rarity as in rare common blah blah blah
set as in like tarot, spectral, planet ?
no, hooking is done in your main lua file
^
that's not "on smods", those are lovely patches
whats the function?
see im unfamiliar 💀
SMODS.Sound?
my bad
SMODS.add_card(
{
set = ...
}
)
play_sound
SMODS.Sound
alright
