#💻・modding-dev
1 messages · Page 616 of 1
when you follow an argument to chime in about the topic
i think its pretty reasonable to assume
so im gonna respond with the point that i dont think X
if thats not what you meant, no harm done
i HAVE just spent the past 5 minutes being verbally berated by someone with 0 competency and clearly lacking understanding of programming
I typically avoid patches at all costs because I consider them a lot more fragile, even though the resulting code is less efficient
Since there's still a lot of performance overhead for a lot of players, I don't think the performance cost of calling functions a few levels deeper matters much in most cases
lovely panics feel emotionally worse than balatro crashes hence I avoid and acticely reduce patches whenever possible
my goodness this has been a fight
it really feels like there is no good way to check for if card has both a specific suit and a specific rank in the same calculate function
it's called is_suit and get_id
It's just more that esp since SMODS code has become a lot more comprehensive and overrides a lot of vanilla functions, it's far less likely I'll need to redress a hook for a vanilla function than a patch if I follow the same function signature
why are you checking context.individual and the cardarea twice
Patches break pretty regularly with new SMODS updates for some of my more "intrusive" features, so since I can't guarantee people won't have a dev branch or a future version, hooks are generally safer for compatibility
we take those
Not that it doesn't happen obv, I learned only recently that I'd been using a broken hook for the vanilla get_straight() function that has 1 arg when the SMODS override has 4, so it's not universal, but a couple times when I've done SMODS PRs Eremel and co have stressed to avoid changing function args
Tbh if someone likes patches more than hooks, good for them - I don't understand the fuss over it, live and let live
patches and hooks both have their use cases
i prefer most of my code to be in my files, but sometimes the best way to do that is to use a patch to insert a function call
patches are evil because i dont get to use my beautiful lua
There's not fuss over that so much as people can only explain their personal use cases and heuristics for it. Explaining why you use one or the other and your reasoning for it isn't "not letting live" other programmers
patches are better than hooks because the hook discards my gold cards
truth
And ultimately programmers benefit from seeing discrete examples and reasoning for certain programming patterns because they're rarely obvious on the onset
gotten back from leaving because i was ''''ragebaiting'''' you?
-# If I could do less of a destructive patch for my scoring antics... it surely would be safer.
me when i have a basic opinion that patches and hooks are inherently unstable by nature and that id prefer to not use them if its already implemented
a: where
b: why is that a reason to restart this or insult me back
surely youre trying to be the bigger person here
Picking it back up is not the move good lord
the conversation hasnt even moved on from the topic
its been less than an hour
i literally went and got some food and came back lol
So? Stirring the pot benefits nobody 
so what do u suggest? just let people walk all over me?
be civil probably
i would be civil if you were civil in the first place
if there is a place where i did insult you please point it out
i dont see it
you called my honest opinion 'bait' and then ran off after calling me both wrong and unreasonable
foe xample:
you picked a fight over the most lukewarm take ive possibly ever given
i called it ragebait at the time because, simply, i was getting frustrated and the wording sounded extreme
which is a factor in ragebait
i just dont see where i said anything extreme or crazy
like where did i say anything even remotely outrageous
i think that i had and still ahve a pretty reasonable point that i didnt deviate from
the wording (at least to me) implies that you would do nearly anything else except for hooks and patches
i think that leaving it be would honestly be better than continuing to argue just for the love of the game
you dont have to be equal with everyone if they disrespect you , you could just be the bigger person and move on
okay
mb for the misinterpretation
but i want to know what i said that made this person think that
thats why im asking
second message in the most recent screenshot
cba to type it out
also you called hooks unstable
which would give a good reason for you to try and avoid hooks at all costs
don't restart this
they're inserting code.
it helps nobody
restart what dude
the argument
its literally a fundemental property of hooks across languages
this isnt an argument you are just factually incorrect
he's literally not fighting your claim 🥀
yes he is
frankly you're making yourself look immature
i want to understand
why are hooks not unstable
like have i just missed something
im not a lua expert but basically everyone can testify to hooks almost never causing issues based off of it just being a hook
i dont actually know too much about what goes on behind the scenes but this issue just generally doesn't exist
they're not "hooks" in a standard sense, it's maybe not a great name but what can you do
it's just overriding a function
with a good hook, there's no instability. any instability comes from either not checking the inputs properly or not calling the original function properly
if you have a counterexample feel free to show me
then why tf are you arguing about it
if you self admittedly dont know what you're talking about
why you gotta leap in to call me wrong when you dont have any knowledge about the subject
maybe i wouldve been proven wrong
yes
okay thats a fair one
and also
if you were correct then i wouldve learned something
and i wouldve changed my ways
i dont mean literal insertion of code strictly, but both achieve a similar end result
im not saying that hooks are bad and i dont think you shouldnt use them
i use hooks and patches
i'm not victin i don't argue just to say i'm always correct
from what i can see, this is an argument about literally nothing
i just dont understand why you lept on me saying 'i'd prefer to use implementation from the game and SMODS instead of them'
i try to improve
the guy insulted me over nothing and i got annoyed
i feel like thats pretty reasonable
i love the reactionary sentiment of two parties
paradox hopped on this because, from what i can tell, you came off as if you were trying to avoid hooking get_id and is_face when that's standard protocol
this
because i get to see two idiots arguing over nothing ☕
i asked a basic question and then got a non-response
love2d
¯_(ツ)_/¯
bro knows where its at
it wasn't a response to the question you directly asked, yes
i am lionel shrike from the hit movie now you see me
i think it's time to cease this discussion, there's nothing to be gained on either side from continuing. if you're trying to make content that makes cards count as face cards, you should hook is_face because that's the only way other content checks if something is a face. if you're trying to make content that makes cards count as multiple ranks at once, you should just wait for the quantum ranks PR to be merged into SMODS because it's not worth the effort to do it yourself (unless you're willing to muck around in a bunch of patches)
just stop fucking arguing both of you holy fuck shit said this shit said that thank you
the back and forth proved futile if nobody got to reach a conclusion
YES
that is what i was fucking asking about in the first place
i wanted to know if quantum ranks had been merged yet
ffs
you could have checked by searching for "quantum ranks" in the smods pull request list
i couldnt remember what it was actually called
oh that's fair
so i asked here
but yea it's still not merged
Not a clue

Not even the smods devs know
its balatrover
current status
what is quantum ranks
it allows cards to be multiple ranks
making cards count as multiple ranks at once, much like quantum enhancements
ts
it really could
🥀
also astra i like clarification over me assuming >:[
wait how the fuck are they doing steven and todd with this
i assume if any of the ranks on a card is even/odd then it procs steven/todd
it uses modulo iirc
i know the current implementation uses modulo
oh right they added a whole new is_parity function to cards
code-wise i mean
it does
card:is_parity(0) checks if it's even, card:is_parity(1) checks if it's odd
oh sick
oh thats cool
problem solved
herer's the function code
neat
so you define the parity in the rank itself
non-number cards (face cards) have parity = nil
get_ranks is interesting
it's pretty much just the same as SMODS.get_enhancements when quantum enhancements are in play
there's also card:is_rank(), which behaves like card:is_suit()
will this break card:get_id or is it just replaced with card:is_rank now
i assume get_id is still around for backwards compat
it won't break it, but it'd be like checking card.base.suit instead of using card:is_suit()
if get_id was removed it would break every mod ever
Apologies if this is a stupid question, but is it possible to make a consumable (type X) that gives $2 for each time a consumable of type X is used in the run (e.g. if type X consumables are used 4 times, then give $8)? I'm still very new to Lua and I studied a few thingies but I don't know what to do
ease_dollars(G.GAME.consumeable_usage_total.key*2)
IT WAS THAT EASY???
thank you so much
so do i just
```use = function(self, card, area, copier)
card.ability.extra.bonus = G.GAME.consumeable_usage_total.typex * 2
bonus = card.ability.extra.bonus
ease_dollars(bonus)
end
Yes.
nice
Collecting a collage of all the art I did for my mods for resume purposes
how would i make something happen when a card is clicked?
Hook Card:click
charms my beloved
i have a weird question
this is trading card's code from vanillaremake
key = "trading",
blueprint_compat = false,
rarity = 2,
cost = 6,
pos = { x = 9, y = 14 },
config = { extra = { dollars = 3 } },
loc_vars = function(self, info_queue, card)
return { vars = { card.ability.extra.dollars } }
end,
calculate = function(self, card, context)
if context.first_hand_drawn then
local eval = function() return G.GAME.current_round.discards_used == 0 and not G.RESET_JIGGLES end
juice_card_until(card, eval, true)
end
if context.discard and not context.blueprint and
G.GAME.current_round.discards_used <= 0 and #context.full_hand == 1 then
return {
dollars = card.ability.extra.dollars,
remove = true
}
end
end
}```
what part of this code destroys the card?
ive been making a version of trading card but with first discard being replaced with first hand and cant seem to get it to trigger
it does the jiggle animation and stops after the first hand is played but doesnt do anything else
i mean in terms of cards on a cardarea ui
-# im trying to make it change the thing on the right when you click one but literally nothing is happening
i decided to add some code from sixth sense to get the destroying to happen
uhm
oh thats weird my recording only captured my cursor
to clarify: i played 5 cards, it gave me over 100 dollars (it was meant to give me 15), then destroyed both the hand that was just played and everything held in hand
i have embraced the glitch
hey y'all, is there a way to check if a new run starts? hooking Game:start_run seems to not work, as it is also called when re-entering a run?
how does one set up a mod icon?
( #1434965243720892426 ) what would be the tooltip for this block? I know when to use it but not exactly what it checks for ;-;
-# tooltip is basically the description
<@&1133519078540185692>
i may be stupid how can i make it so a joker sets a blind to a different blind without jank shenanigans
if context.ending_shop then
for i,v in pairs(G.GAME.round_resets.blind_choices) do
if v ~= "bl_maxboism_thesky" then
G.GAME.round_resets.blind_choices[i] = "bl_maxboism_thesky"
end
end
end
i have this but it complains about my blind not having boss defined even if i start a big blind for example
SMODS.Blind {
key = "thesky",
dollars = 1,
mult = 0.5,
pos = { x = 0, y = 0 },
atlas = "CustomBlinds",
discovered = true,
boss_colour = HEX("8b0307"),
}
boss_colour is needed or else it crashes if i hover over it in collections 😭
in controller.lua, there is the line self.cursor_up.target = self.hovering.target or self.focused.target
i've inspected self.cursor_up.target but it doesn't seem to be a Card
so, how can i check if the deselected thing is a card, and has a specific ID?
my internet is fine? (this is in git bash, windows 10 btw) why won't this work?
[[hidden]] MINGW64 ~/Desktop/JokerBlocks (main)
$ ping github.com
Ping request could not find host github.com. Please check the name and try again
.
self.cursor_up.target:is(Card)?
$ ping https://github.com/
Ping request could not find host https://github.com/. Please check the name and
try again.
mm
will try, but the object doesn't look like a card
how would i modify this code to:
A: make the video cover the entire window
B: close the video when the video finishes?
i mean it depends on what is being hovered
my computer hates git/github bro 😭😭
it's when i deselect a card, i checked that object and it seemed uncardlike ^^;
but ya i'll give it a go
what would be the proper way to replace the blinds because i am not knowledgeable in blinds
can you connect with another device on same network
if you give it a boss table does it still crash
wdym?
can you connect to github from different device
i dont have another computer
can you connect with browser?
wha?
can you open github from browser
hmm
returning false
i think i'm just gonna remove the functionality altogether ^^;
it's for an annoying easter egg
and it gets in the way
it doesnt crash but then it treats a every blind as a boss and then goes to the next ante when beaten
i would just do that and patch that out until smods add more blind support
thats what i did for hotpot
i see, and i would patch which function if you happen to remember?
ping doesnt take leading https
i have a feeling it's something to do with the local vid_sprite but idk how i'd get it to fill the window
what abt nslookup github.com?
i think its these two patches https://github.com/the-Astra/Hot-Potato/blob/34a5d60d3bb3e115bc44cceab1f64e80b0a015c2/lovely/pdr_events.toml#L33
wait am i s'posed to show address-
thank you 🙏
nothing was leaked
so uh you might wanna try setting up dns server, try this one https://developers.cloudflare.com/1.1.1.1/setup/windows/
and then what? do i click install...?
or Ok?
?
properties
oh
then OK?
set the ipv6 too
ok
thats it?
weird
fr
so what do i do now ;-;
?
nvm
have you tried another terminal lol
yes
did you set ipv4 as 2606:4700:4700::1111 or 1.1.1.1
hm idk then
you cant anyways
how do i check the contents of my consumable slots again-
G.consumeables.cards
I am genuinely confused on why my computer cant ping github
well i got the game to instantly crash which was kinda the point but not what i was going for-
@keen atlas does this tell you anything?
no
dang it
can you still access github from browser though
yes?
ok cool
changing it to pairs does work, but it's having trouble calculating the difference
as shown in the screenshot, it sees Clubs = 3, Diamonds = 2, and Spades = 3 as the original hand and Clubs = 3, Hearts = 2, and Spades = 3 as the new hand.
expected behaviour should be difference = 2, as the two diamonds became two hearts, but instead it's calculating difference = 0, i'm assuming because it's comparing the diamonds to hearts as if they were the same suit when they aren't
i'm going to try and math this out, there's def some missing logic, but just figured i'd mention it
i always find it helpful to write these things on paper to figure out the logic
is there a nice way to check if youre inside the "small blind" slot or "big blind" slot
for the patch
no idea
what about nslookup github.com 1.1.1.1
might just make a separate blind thats exactly the same otherwise for the boss because i straight up dont see a way to check 😭
i forgot to scribble the user name 😭
-# not that bad, not my full name or anything anyways
actually how do other mods that add replacement blinds for small/big handle it
i have, this is the expected behaviour
and in git bash
didn't you say something abt my firewall yesterday?
nvm abt it cuz i never use it
can you try unchecking the ipv6
no
and ping?
is there any way to get the dimensions of the game window?
love.window.getMode https://love2d.org/wiki/love.window.getMode
yeah
yeah sure
okay so the problem is that it's only looking for suit_keys in og_suits for the for loop, not in new_suits, so if a suit doesn't exist in og_suits but does exist in new_suits it just skips over it which means i gotta rewrite it so it takes that into account when setting up the for loop
try open notepad as admin, then edit C:\windows\system32\drivers\etc\hosts, then add 20.205.243.166 github.com
btw what abt ping 20.205.243.166 before you added it?
yeah i said that in my first reply about this :3
this is more a description of the problem rather than the logic of the solution
wait what-
its a bit hacky but give it a try
wdym by edit?
you edit the file C:\windows\system32\drivers\etc\hosts
file > open
?
yeah?
what do i do??
or C:\windows\system32\drivers\etc then click hosts
the hosts file is supposed to be there 🤔
make one if it isn't ig
with blank contents?
this
20.205.243.166 github.com
what
it's hidden or something?
oh probably
i didnt notice that too
yeah
and then ping? (with nslookup or ping?)
ok im incredibly salty why is almost every blind type check done with Blind:get_type() EXCEPT
if G.GAME.round_resets.blind == G.P_BLINDS.bl_small then
G.GAME.round_resets.blind_states.Small = 'Defeated'
elseif G.GAME.round_resets.blind == G.P_BLINDS.bl_big then
G.GAME.round_resets.blind_states.Big = 'Defeated'
else
G.GAME.current_round.voucher = SMODS.get_next_vouchers()
G.GAME.round_resets.blind_states.Boss = 'Defeated'
for k, v in ipairs(G.playing_cards) do
v.ability.played_this_ante = nil
end
end
are you sure there isnt any other line that changes github.com in there
that works
so its good?
crack windows install wdym ping works but nslookup doesnt 😭
yeah try it
i imagine it's just a not having restarted thing
hopefully
its not 😭
nslookup is smart enough to not parse through the hosts file whenever you run the command 
so everything works nicely if i just patch Blind:get_type EXCEPT the blind progression 😭
how can i spawn a random consumable?
kinda like cryptid does with the tarot card
i tried to find it
but theres literally no file for tarot cards in the mod for some reason
cryptid tarots are in misc iirc
but you can just use set = "Consumeables" in an SMODS.create_card or SMODS.add_card call
i tried this
does it work
but idk how to define the set
have you ever created a card before
no 🥀 anyways brb
😭
if not probably look into that first
different output tho
^
did you type yes?
no i just waited .2 seconds
nvm the newround also does that
Can you do hex codes directly in {C:} for loc files?
No.
thjanks
bro i yapped on and on in a tech support server and even they couldn't help, im cooked
im actually going to crash out
Is there a context for purchasing a voucher?
oh typo
Or should I just use context.from_shop and go from there
umm
try remove then add again the remote url
if that doesnt work you might need to authenticate with ssh key / oauth
context.buying_card and context.card.ability.set == 'Voucher'
??
can you try pushing from vscode
^?
this
oesns't work
it says this
but it still loads in vscode
igtg anyways
thanks for the help
kay
guys how do i check the number that i scored? i tryed
calculate = function(self,card,context) if context.joker_main then local totalScore=SMODS.calculate_round_score() if totalScore>10 then return{ chips=10 } end end end
but it gives me an error
what's the error
update steamodded
also preferrably just paste crashes you get in here rather than screenshotting two lines
okok i didnt want to clutter the chat
if it's longer than the character limit it'll turn into a txt file
if not you can still do it manually
after 4kb
ok thanks ill keep it in mind next time
Or just screenshot the full screen
ok it works now thanks guys
That’s normally enough information for most crashes
im trying to make custom collection page with cards but when there's a card area in there it crashes
AKYRS.card_area_preview is a wrapper for card area things that works
i know it works because it's the same code on the description page that doesn't crash
If your functions not wrap card area in object container then that's probably an issue
it does
Fue ahí cuando le respondí "🤓"
Material Audiovisual:
~Emoji Nerd
https://images.app.goo.gl/vvzsH5yWSsYSBSGj8
------------------------------------------------------------------------------------------------...
okay its back to figuring out why my discards arent being set to 0
What is mod
from this
No
That’s not how that works
What do I do if "typex" is a nil value
add or 0 after it
but also make sure it's the right value; you might need to include your mod prefix
Ohhh okay thank you
Anyone know how to turn balatro into a zip folder without renaming it? I tried it that way and nothing.
No, you don't need to do that you can just extract it.
How do I do that?
I have a copy of Balatro on my desktop, how do I extract it?
How do I extract it? It's not in a zip folder!
So is this correct
use = function(self, card, area, copier)
card.ability.extra.bonus = (G.GAME.consumeable_usage_total.jabm_typex or 0) * 2
bonus = card.ability.extra.bonus
ease_dollars(bonus)
end,```
No, consumable types don't use mod prefixes.
Do you have third party extraction software installed?
Not to my knowledge, no
fair
but it's still giving me $0 every time so uhhh
becasuse most of them let you extract exes
Thank you, Eris
Yeah 7zip or WinRAR will get the job done
somehow, still won't allow me. Just.. no extraction button
uh....
I am
I see open, run as admin, all the usual stuff but no Open With... and dragging it physically says it's invalid.
?
did you actually run the 7zip installer
it should show up if you click > right click > more options > 7zip
lemme check...
what's enhancement_gate
because if it isnt anywhere thats probably the issue
prevents spawning of a card unless you have at least 1 card with the given enhancement in your deck
(e.g. how lucky cat won't spawn in-game unless you have a lucky card in your deck)
wee cat
which name is best
lucky kitten
wee cat
wee kitty
wee kitten
wee lucky cat
wee lucky kitten
Now to finally figure out how to button a button.
maybe have it related to a lucky card triggering or not?
small gains when a lucky card scores, larger gains when a lucky card triggers a lucky effect (but still smaller than X0.25)
yeah sorry
unforgivable
game breakin bug
okay guys uh i now that i fixed the no discards deck im making a deck thats entirely 4s now but its lowk just not working
da code
I have a deck thats literally all 2s so if you can wait for me to get home i can help
how long?
wee deck
20ish mins?
its just the red deck but the display size is the wee joker size
sounds good
The only catch is that after each round all cards have a 1 in [Rank] chance to rank up
i gotchu alr
oh okay ty
Found exactly what I wanted! hahahahahaha!!!
okay no this isnt working either
Code?
maybe it should be more
Remove the {} around only_one_rank = '4'
idk i mean its a rare locked joker it should be a bit harder to unlock?
I feel like it should be a bit less since retriggers will increase the xchips rampant
yeah fair point
okay that worked lol
this looks so fucked
+X0.2 for every scored lucky card would be a bit too potent, so perhaps +X0.1 or +X0.05
.1 i think is a fair balance since its still a rare joker and meant to be like the wee joker for xchips
👍
#🃏・off-topic message btw this how i got the inspiration
Btw where can I hook a function upon the shop appearing, since I'm trying to get a joker that stays in a specific slot in the shop until it is either bought or it breaks after 3 shops
"Hey balatro, whats 2{n}2, where n belongs to the set of natural numbers?"
Balatro:
^
I love how 2 raised to itself in ANY hyperoperation is just 4
hi
hikoyori
maybe 10 or 13 lucky cards since the gemstone jokers are 30 for a suit?
Not 13...
13 unlucky...,.,
Have a whole hand of lucky cards
That again
now i just need more ideas for other decks and the 2 question marked decks
so something similar to golden ticket
I guess so
maybe i mean the reason why its gold since it only is a held in effect
yessss
All cards come back when destroyed could be a good idea for reanimated
G.splapp_config = G.splapp_config or {}
G.FUNCS.DT_lose_game = function()
if G.STAGE == G.STAGES.RUN then
G.STATE = G.STATES.GAME_OVER; G.STATE_COMPLETE = false
end
end
local t = {n=G.UIT.ROOT, config = {align = 'cm', r = 0.1}, nodes={
UIBox_dyn_container({
{n=G.UIT.R, config={align = "cm", padding = 0.15}, nodes={
{n=G.UIT.C, config={align = "cm", padding = 0.15}, nodes={
UIBox_button{ label = {"One"}, button = "DT_lose_game", minw = 1.7, minh = 0.4, scale = 0.35},
UIBox_button{ label = {"Two"}, button = "DT_lose_game", minw = 1.7, minh = 0.4, scale = 0.35},
}},
{n=G.UIT.C, config={align = "cm", padding = 0.15}, nodes={
UIBox_button{ label = {"Three"}, button = "DT_lose_game", minw = 1.7, minh = 0.4, scale = 0.35},
UIBox_button{ label = {"Four"}, button = "DT_lose_game", minw = 1.7, minh = 0.4, scale = 0.35},
}}
}}
}, true)
}}
return t
end```
All's left is to time it like yahiamod, scale each one right, and add the question at the top!
-# I CAN CODE A BUTTON NOW!!
thatd be cool but what would the caveat of the deck be
You cant thin your deck
oh thats actually kinda the gimmick for this entire mod ngl lmao ill go with that
tyvm
Ywyw
And also any card you get would be PERMANENTLY added to your deck, so you have to be careful with what you pick up.
i have an idea
play a hand with both glass and lucky cards
since broken glass is a sign of unluck and typically you don't want to play both since both rely on probability
Sure 👍
not sure how id code that?
i can try tho
actually i can just make it so those cards come back as well
i have an idea of how to do that
I'm thinking if the card destroyed is that card, just copy it?
Maybe it can use some sort of Returning sticker that just clones it upon destruction
nah this is the entire deck
Then go ahead
i mean if all cards get returned when destroyed just make it a deck calculate right
probably
Yea context.remove_playing_cards could work
for k, v in pairs(context.removed) do
end
Yadda yadda
Would that work with 1 lucky and 4 glass?
That's cool
idk if the last line has too much characters for an unlock especially for other languages
Btw would anyone know how I would hook a function to when a shop appears, or being able to attach buttons to jokers in the shop globally instead of when on_apply is fired
idk much about hooks sorry
😔
okay i literally just copied the majority of DNAs code and altered some tiny bits lol
watch this not work
not to be rude but have you tried making simple jokers first
yes
ive made like 5
What is end doing in line 25 😭
befpre this
My first was a DNA clone, and it works!
bad indent, it's fine
Oh alr
you made simple mistakes there that you wouldn't make if you did tho
idk but it bitches at me if i delete it so it stays
press shift+alt+f
it will fix the formatting
should make it clear what the end is doing
Isn't there some sort of extension that formats code cleanly
prettier, yeah, but lua formatter is just fine
wdym
also it didnt work but at least it didnt crash my game lol
I found some trouble with the original formatter so I just find the new one better
How not work?
i hung 2 random cards and it didnt bring them back when the round ended
Ah. Maybe make a table?
context.end_of_round and context.game_over?
i was thinking it was a context issue
- DeckCount doesn't exist by itself, it's in config
- eval doesn't exist in that conditional block below
- context.full_hand is not a thing in end_of_round
also like tomato said there are problems with the syntax
Does your cards duplicate when you lose?
the first one makes me think you never made a balatro object before or you didn't learn anything
theyre supposed to bring back any destroyed cards from the round before
ik very little but im slowly learning my man
You could create a value in G and save it there?
how would you save card info
that's why I recommended doing simpler stuff
😔
You can save a value, but not in G
n what if i serialise cards and save it into game table
what if
when it gets destroyed
idk i just save my cards to cardareas
there's no reason to save anything to anything global when you can just save a table of card data inside the joker itself
i know the art of cardareas
It's a deck
deck, whatever
Actually, save the cards to a deck config
i have 8 decks in this mod so far and of those 8 maybe like 5 or 6 are relatively simple and have worked either first try or with minimal bugfixing
trust me ive done simpler stuff
Then at the end of round, sift through the config of the deck and copy as such
you don't need to justify yourself to me, I'm just giving advice from what I'm seeing you post here
ya ik ik
Btw N, I was gonna ask, what could I use to attach functions to when a shop appears, since I want to see how I can have jokers and consumables persist between shops in a special shop slot
save them to a cardarea :3
maybe look at the black market in hotpot
Fair idea, I'm not sure where to look for how cardareas are used but ig I can try tmrw
here's how I'd do the deck
- every time a playing card is destroyed, save its suit, rank, enhancement, edition, and probably its whole ability table. all of this goes in a table, inside another table inside the deck's config (i.e. there's a table for each card's data inside a single table)
- at end of round, loop over the big table and re-create the cards, and then reset the big table to be empty
Or you can save the card to the deck config directly, since they are all objects after all
Unless I'm wrong
Ok 🥀
it'll behave fine until you quit the game and come back later
so how would i save all the cards properties in the table?
I was meaning like emplace it in config = {} but I guess I'm the newbie
they're variables in tables. you save them.
No, you would use card:save()
oh hell yea that works
i figured the save/load stuff was hardcoded to save and load to/from the save files
is this fine in the collection i am still not sure if its too long at least for the third and last line
that's fine yeah
i'd say as long as the description isn't longer than like, obelisk, you're good
i tried
evil screenshot
quick question how can i make a challenge that uses a whitelist for jokers instead of a blacklist, without just banning every joker other than the ones i allow
You can't, but banned_cards can be a function.
yes but then it would make the banned cards tab super full
i guess it can't be helped :/
is the unlock condition clear? basically play a high card but it has to be an ace
gotta love it
locked_loc_vars = function(self, info_queue, card)
return { vars = { localize('High Card', 'poker_hands') } }
end,
check_for_unlock = function(self, args)
local highCard = false local ace = false
if args.type == 'round_win' then highCard = G.GAME.last_hand_played == 'High Card' and G.GAME.blind.boss end
if args.type == 'hand_contents' then ace = #args.cards[1]:get_id() == 14 end
if highCard and ace then return true end
return false
end
``` not sure if i did it right. lol.
is it because it only checks for one of the args.type and skips the other or something
gotta get ready for work and ill be working for the next six hours. uh, just mention me if you know how to fix this
here's the full source just in case
card:get_id() returns a number not a table.
somehow the scaling here is just not activating at all
wait huh
ok idk what the fuck is going on
it's not that
it's the joker_main part
oh
i forgot a return

I'm trying to make a blueprint-like joker that only copies (left + right) jokers of a specific pool. I had the copy effect working fine, but I can't seem to have the joker properly check if other jokers pass the pool check. I'm not exactly sure what is wrong, so any help would be appreciated!
config.center.pools is a table of pools
you want to loop over G.P_CENTER_POOLS["hch_food"] and see if its in there
(Also a food pool with the key Food is very common so more mods will have compat with that
you can do (joker.config.center.pools or {}).hch_food to check
wont that only be there for jokers that have that pool defined via the pools field and not the ones that are added into the pool in the definition
nope because of me and my cool PRs
trying to make a joker that debuffs face cards when it appears
it no worky
return {vars = {card.ability.extra.xmult}}
end,
calculate = function(self, card, context)
if context.setting_blind then
debuff = { is_face = true }
end
if context.individual and context.cardarea == G.play then
if context.other_card:is_face() then
card.ability.extra.xmult = (card.ability.extra.xmult) + 0.25
end
end
end
}```
it should be context.debuff_card and context.debuff_card:is_face() instead of setting_blind
and return { debuff = true }
how does one control what background music is playing
i looked at smods sound but i dont think i get it
return a number in select music track
the bigger number gets played
I'd say "High Card containing an Ace" or something to that degree
alright, and what if i wanted to change when an existing music track is playing
for example, mute the vanilla bg music when a specific joker is held
no idea
Okay, it seems to be working, but not when only 1 of the jokers counts (works when both are compatible). I have to make some cases to account for that, but that should be easy enough.
tyty
I think Myst and maybe some other people know
do SMODS.blueprint_effect(...) or {}
in merge_effects
maybe something like this
back at it again with the same issue
but for clarification
the mod was working fine until i rebooted it so uhhh yeag
noted
oh i did sometihng and it kind of works but the rest of the sounds are broken and very delayed
please tell me i dont need to make an empty .ogg file
Hello, quick question: was there a way to order the jokers/consumables in the collection?
right right, clears things up much nicer than what i got working lol
thanks again!
oh it has a fallback to music1 smh
i understand it now
oh it works 🔥
nevermind, i fixed it
looks like i need to work on a config page some other time
invisible joker and burnt joker's keys are "j_invis" and j_burnt right
No, it's j_invisible
oh ok
hello! so ive been trying to make a cardarea doohickey but for some reason it doesnt shake (or i guess jiggle idrc) or resize alongside the window properly.
please help I've been at this for at least two hours now.
local start_run = Game.start_run
function Game:start_run(args)
self.grgo_powers = CardArea(
0,
0,
2.3*G.CARD_W,
0.95*G.CARD_H,
{
card_limit=4,
type = "joker",
highlight_limit = 1
}
)
GrowlGoofs.powers = G.grgo_powers
start_run(self,args)
G.grgo_powers.T.x = G.consumeables.T.x
G.grgo_powers.T.y = G.consumeables.T.y+G.consumeables.T.h+0.23
G.grgo_powers:hard_set_VT()
end
guys for some reason challenge joker wont generate needle joker
why is this custom tooltip showing up blank?
That would work I'll check it out when I get home
on break atm
you didn't write the name or description /j
show code
how do you have a value change in the description for scaling jokers?
i tried the hashtags that vanillaremade uses but that just makes the number displayed nil
thats a cute kitty
Does anyone know of a mod or tool that will write the game state to a .txt file every time an action is taken
THAT IS NOT HALF THE BLIND SIZE
Oh god 😭
Make sure youre only triggering it once
thats what ive been working on
i just copied the event from disabling the wall
but im not sure what context will get it to do it just once at the start of the round
context.setting_blind
thats what i thought too
if context.setting_blind then
return {
function(self)
G.GAME.blind.chips = G.GAME.blind.chips / 2
G.GAME.blind.chip_text = number_format(G.GAME.blind.chips)
end
}```
func = function()
you don't need to return this
can_use = function(self)
return G.hand and #G.hand.cards > 0
end,
use = function(self, card, area, copier)
card.ability.extra.bonus = (G.GAME.consumeable_usage_total.typex or 0) * 2
bonus = card.ability.extra.bonus
ease_dollars(bonus)
end,```
Is this correct? It's giving me $0 every time, instead of $2 for every time a consumable of Type X is used
it should be correct
what are you using as the type
I'm using a custom consumable type i added for my mod
The code is for a consumable of that type
then I don't think the game keeps track of custom ones
dang
So i need a little bit of help, im trying to make a splash text similiar to minecraft's one for my mod. (see img references) Is it possible and can someone help with making it?
Im thinking of putting the text contents in a seperate lua file named "splashtext.lua" to make it easier
Hot Potato did exactly this
do you know how?
mind linking me to their code?
it's in #1397989781178155009
i would ask if you're able to use it, since its an event and idk how chill the person who wrote it is so
aight thanks man
I guess if anyone has a solution, let me know
how tf do I do this
im back from work
balanced it out
should i add the ace reminder or is it fine like steel joker
reminders are more for played suits/ranks
for the art, since im not that great at art yet, i was thinking a pilot flying a plane somewhat like this one in gta v's story over islands or mountains. mainly inspired by the airplane missions/gamemodes in gta v and wii sports resort
for the name which one is better: flying ace or fighter ace?
So if it’s X1 when you have 4 aces, does it go below X1 if you have less?
Or is it X2 with 4 aces and I’m just making an assumption?
its similar to steel joker if you have no aces you just get x1 it goes up
i don't know why you would want a joker that just takes xmult like that
🐎
You gonna be doing custom unlock conditions for your jokers?
I know Hot Potato added the whole Minecraft splash text, but is it possible to add other graphics to the menu (besides another card)? I plan on adding some, but it's late and I gotta go to bed before I even begin to investigate 💔
similar to the vanilla game where the last 30 where locked some like 3/10 of the jokers
Cool
one stack of joker ideas is beating a run with a friends of jimbo suit and the joker is related to the respective game or something similar
So just changing it in the menu and then winning?
yeah since i think it would be hard to track for the whole run
might be too niche idk ill come up with more ideas later but its almost midnight just wanted to finish the jokers i made before i went to bed after work
I don’t really like that
Maybe reference the game/joker with the unlock
maybe... like for bugsnax i guess consume all the food jokers at least once? idk
Does anyone know what language the shaders use for Editions?
how do I make the joker have the message instead of the card
add a message_card key to your return table
also you should look at SMODS.scale_card
message_card = card
a flavour of GLSL
is there a definitive way to get a joker's loc_vars?
just wondering what you're doing with it
so far the best i can come up with is card.config.center.loc_vars and card.config.center:loc_vars({}, card).vars or card:generate_UIBox_ability_table(true)
yeah i don't think you can get it from anywhere else other than UIbox ability table because vanilla ones are there
how do i get rid of the error
my snag was that uibox ability table doesn't work for modded jokers
(Sorry, wrong timing)
missing localization entry
descriptions.misc.dictionary.j_your_packtype_here_pack
ohh
yeah for those you'll have to use the center like what you did
i think you've got the best solution already
Chat am I cooking
except for the part where it isn't actually functional because I'm just using JokerForge to brainstorm ideas
How do I manually call another joker's calculate() function? I want to forcibly trigger the joker outside of its normal timing by setting all the context flags to true.
you seem to be looking for https://github.com/SpectralPack/Cryptlib 's forcetriggers
how does one do this without cryptlid :(
Steal Cryptlib's Code™
b-b-b-b-but i dunno how :(
a bunch of mods have forcetrigger compat designed specifically for it anyways
this is what i got sofar
im going to be honest with you here i havent actually used cryptlib forcetriggers
i had a certain glitched kat helping me
dang 😢
i know how to add compatiblity but i dont know how one forcetriggers
oh theres a function for that
mmmmmmmmmhm
make sure to check if they exist first so you're not overwriting the function in case cryptid does happen to be enabled
already stolen
youll need to steal Card:no and Cryptid.deep_copy as well
that force trigger function would look a lot less daunting if it didn't individually hard code the result of every vanilla card 
all 900 lines btw
no lmao
Besides that, it mostly just uses eval_card(), right? Where does that function come from?
function eval_card(card, context) common_events.lua
Keep in mind SMODS has a hook on it.
I saw it referenced in smods, but nothing happens when I call it
I figured out that it should've been SMODS.eval_card(), but now I'm getting this crash
INFO - [G] Bitter's Stuff | loaded Scripts/Atlases.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Consumbles.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Edition.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Hooks.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Misc.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Rarities.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Jokers/BadDev.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Jokers/Funnies.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Jokers/JokerFuncs.lua
INFO - [G] Bitter's Stuff | loaded Scripts/Jokers/Reflection.lua
why isnt my file loading?
btw theres like 1000 or so lines that are just for vanilla stuff
at ts point i might just require it for just this
late bump because I went to bed lol
idk
it is order but that is automatically set by steamodded based on load order
Cryptid uses order but that is just for internal load order within the mod to get cards in the desired order
how can a playing card come back to hand after scoring ?
thx
what is handcard, and how do i target a card with a special enhancement ?
Replace conditions with SMODS.has_enhancement(v, 'm_modprefix_key')
v is the card to add to hand ?
to accese its config it's still v.ability.extra or something
Yes.
version = "1.0.0"
dump_lua = true
priority = -10
[[patches]]
[patches.pattern]
target = '''functions/state_events.lua'''
pattern = '''
for k, v in ipairs(G.play.cards) do
if (not v.shattered) and (not v.destroyed) then
draw_card(G.play,G.discard, it*100/play_count,'down', false, v)
it = it + 1
end
end
'''
position = "at"
payload = '''
local handcards = {}
for k, v in ipairs(G.play.cards) do
if (not v.shattered) and (not v.destroyed) and v.ability.extra.value==0 then
draw_card(G.play,G.discard, it*100/play_count,'down', false, v)
it = it + 1
end
if (not v.shattered) and (not v.destroyed) and v.ability.extra.value>0 then
table.insert(handcards, v)
it = it + 1
end
end
if #handcards > 0 then
G.FUNCS.draw_from_play_to_hand(handcards)
end
'''
overwrite = true
match_indent = true```
is it good ?
No, you need to replace conditions with SMODS.has_enhancement(v, 'm_modprefix_key')
im trying to make a card spawn a planet card but i just cant get it to work. using set = 'Planet' doesnt seem to work. Can someone help me?
set = 'Planet',
edition = 'e_negative'
}```
for i = 1, math.min(#G.hand.highlighted, card.ability.max_highlighted) do
G.E_MANAGER:add_event(Event({func = function()
_card = G.hand.highlighted[i]
if _card.edition then
SMODS.add_card{
set = 'Tarot',
edition = 'e_negative'
}
end
if _card.seal then
SMODS.add_card{
set = 'Spectral',
edition = 'e_negative'
}
end
if _card.enhancement then
SMODS.add_card{
set = 'Planet',
edition = 'e_negative'
}
end
_card:remove()
return true end}))
end```
_card.enhancement doesnt exist, you want to check next(SMODS.get_enhancements(_card))
No, it's _card:get_seal() and next(SMODS.get_enhancements(_card))
is it possible to add text to a joker's localization only after its discovered ?
thx
how to get a list of all curent tag and how to add a tag
G.GAME.tags and add_tag(Tag('tag_modprefix_key'))
how to get the name(tag_modprefix_key) of the tag in G.GAME.tags
tag.key
thx
bro i just want a github repo 🥀 🥀
is it possible to make a card come back when discarded
Yes, patch G.FUNCS.discard_cards_from_highlighted
HOLY FUC @keen atlas (mb for the ping)
Modifying SDM_0's mod and I wanna rename the WoF to "Let's go gambling!"
cant you just edit the name to lets go gambling
how do you edit/define global variables again? is it G.GAME.current_round.variable_name?
No, it's G.GAME.variable
do u guys know how to apply edition shaders to things being drawn directly without adding this warping?
Wth is this
okay so
how do i get the {X:mult,C:white} look with raw ui nodes
where in the code is that
localize
also it's just a column node with some rounding
perfect ty
how do i level up all the poker hands?
like, at once? i don't know that you can do it in one call, you'd have to iterate through each hand
https://github.com/nh6574/VanillaRemade/blob/main/src/spectrals.lua
line 911
the re made black hole
you are right
Is there context I could use to pull the sell value from a destroyed joker? (As in, making a joker that gives double the sell value of another joker that is destroyed)
context.joker_type_destroyed and context.card.sell_cost
needed the second part, thanks! seems to be working
what is better
quick question:
why doesn't remove all cards of that suit and only left these cards?
weird that shouldve worked also isnt there like a config option for that?
Because calling remove removes them from G.playing_cards which you are currently looping through
you want to store the cards to delete in a local table and then call SMODS.destroy_cards with that table
mm so like this?
not at all
like this
local cards = {}
for k, v in pairs(G.playing_cards) do
if v:is_suit("Hearts") then
cards[#cards + 1] = v
end
end
SMODS.destroy_cards(cards)
oh,alright
No, they should be iterating over it backwards.
for i=#G.playing_cards, 1, -1 do
if G.playing_cards[i]:is_suit('Hearts') then
G.playing_cards[i]:remove()
end
end
working on a spectral cousin of these two jokers but not sure what to call it
the closest i got was when looking up stuff is paranormal but it doesnt sound like a profession
ghosthunter? parapsychologist? practitioner? transmitter?
pyromancer?
ok thank you, this is better,
it doesn't make some loud sounds👍
How 'bout "Occultist"?
Also, is it possible to call after_scoring() within a Joker?
name = {
"This Joker's full name is:",
"{s:0.7}(*ahem*){}"
},
text = {
"Joker That's Been Crumpled Up, ",
"{E:1}Torn Slightly{}, Soaked In The Lagoon" ,
"And Kissed With {X:blue,C:white}Coral Blue{}",
"#2 Semi Gloss Lipstick"
},
hc_ms_comment = {
name = {
"Mobile Suit",
},
text = {
"This card comes from the",
"{E:1,s:1.3,C:dark_edition}Mobile Suit Gundam{}",
"franchise"
}
},
hc_slander_comment = {
name = {
"Slandering Myself",
},
text = {
"This card doesnt work properly because",
"{E:1,s:1.3,C:attention}I cant fucking code!!! :3{}",
"{C:inactive} -jabon Gratis{}"
}
},
hc_vegeta_comment = {
name = {
"vegeta",
},
text = {
"vegeta :)",
}
},```
only the longass comment shows up, did i fuck something again
that actually works thanks
No, because that doesn't exist.
Exists for Ortalab's The Hammer, which strips enhancements from cards after they score!
Yes, that's an Ortalab thing.
say, would there be a way to have a hand not score unless theres a specific suit held in hand?
workin on a cool asf blind
Ortalab's done something similar, for forbidding a hand unless it contains a specified suit.
well, i want to make it so you just have to hold it in your hand
You'll hafta call debuff_hand() then loop through the player's cards held in hand and see if the player's got so much as a single, say, Diamond. If they do, return false; otherwise, return true.
another quick question:
why do Card effects that check default deck size still believe its 52 when cards are removed/added to deck at run start?
Erosion should say "36" instead of "52".
@sharp arch
show me the joker code for the extra info queue description that is working
and an instance of the joker code for the extra info queue that is not working
Because you need to set it manually.
these are just one comment
prettuy sure if you find the issue therethe rest can be fixed
and how can i set it up manually?
G.GAME.starting_deck_size = #G.playing_cards
the comment is stored in Other, correct?
ye
if it helps, heres how it looks in game
info_queue[#info_queue + 1] = { key = 'hc_ms_comment', set = 'Other' }
return {
vars = {
card.ability.extra.Xmult,
card.ability.extra.every + 1,
localize { type = 'variable', key = (card.ability.extra.loyalty_remaining == 0 and 'loyalty_active' or 'loyalty_inactive'), vars = { card.ability.extra.loyalty_remaining } }
}
}
end,```
can i see the loc vars function of the joker with the functioning extra comment
info_queue[#info_queue + 1] = { key = 'hc_longass_comment', set = 'Other' }
return { vars = { card.ability.extra.increase, card.ability.extra.dollars } }
end,```
the only thing that i can think of that could possibly be messing with this is a syntax issue
you didnt in any way mess with how the game processes loc text, correct?
how the hell would i even do that
idk but that seems like a no
send the loc file here and i can take a look
its not crashing which means its finding the entry
here it is
OH MY GOD-
i hate my inabillity to type\
🧠
try it and see if the other comments work
you are a fucking lifesaver dude
THHEY WORK AGAIN
🔥
dont worry about feeling dumb because you made a syntax error
ive had to help multiple people here catch sneaky syntax stuff that was causing bugs
thanks
we always make em
update = function(self, card, dt)
if card.ability.extra.active == true then
G.SETTINGS.GAMESPEED = 8
end
end,
remove_from_deck = function(self, card, from_debuff)
card.ability.extra.active = false
G.SETTINGS.GAMESPEED = 4
end,
add_to_deck = function(self, card, from_debuff)
card.ability.extra.active = true
end
i have this function which works but when you win a game go to main menu and boot up a new run it doesnt change the gamespeed how do i fix that?\
Hook Game:main_menu
oh yeah mr seals, do you think its possible to make a joker change the langauge on obtaitining it ?
Why would you do that