#💻・modding-dev
1 messages · Page 237 of 1
Okay. I'll do that
this should be a puyo rainbow
idk much about poker hands
ive gotten this working exept for the end of booster packs. i havent tried actually hooking this to the save function due to some issues that could bring up
is the mod ID correct?
wait, it has to be my mod id?
yeah lol, had a friend test it and it was pretty up there
lol fair
I named the placeholder your_mod_id, what else was it supposed to be???
there it is
huzzah
why can i never use this card, even when i have 1 card highlighted?
max_highlighted is just in config
Ty! I got it working now :)
not config.extra
i'm probably NOT going to make jokers for all the puyo chain and puyo rainbow variants
just base puyo rainbow and puyo chain
now that i think about it, the memory card should be rare
in this case this is fine, but you need to reference it as card.ability.max_highlighted
it also works with rare suits but i expected that
the other thing you can do is put some property in your suit declarations and check for those on SMODS.Suits[v]
that gives you more control than just checking if it's from your mod
nah i want it to work with all puyo types
finally finished a spritesheet 🔥 10/10
now for puyo chain
which is five cards of a singular puyo suit
the puyo chain code is currently just a copy of puyo rainbow
ok so i fixed itbut now when i try to use it it says card.lua:559: attempt to index a nil value
which is weird. because card.lua line 559 is empty
check in the lovely dumps, not extracted files
how do i make this say +1 consumable slot
might have to do with setting the seal
how do i delete the card at the start on the title screen foreever and ever ?
bal tro
does anyone know what zone the shop vouchers go in?
yes
how would i check for 5 of the same suit
I don't use shaders that much so not sure. Does the shader look fine when its in game for real on the plain joker?
G.shop_booster
vouchers
oh whoop
trolled
G.shop_vouchers
thank u
Not much different lmao
actually, it's not too dissimilar to how a flush works
a flush is literally 5 of the same suit
this is just that but with puyos
where would i find the code for a flush
Hmm I'm making a custom enhancement and I have
config = { bonus = 2, mult = 2 },
but it's only adding the extra chips and not the mult
anyone know why that might be?
A
A
Somehow it looks worse actually on a joker, not sure what the difference is between variables being passed in
I'm not sure
it's possible theres some difference in variables
DebugPlus makes some assumptions to try to prevent crashes but it could be wrong and the wrong data could be passed to the wrong value
having the shader would help
i'm saying this because i want to learn from it and see if i can apply it to the puyo chain code i have
search for get_flush
in game.lua?
@quartz ravine
where
asking this again bc i didnt get an answer earlier
Sorry, didn't see your response. Let me DM it to you
maybe it's lower in the order than flush five?
its based on the product, is the thing
in which lua
and my hand's product is higher than flush five's product
hmm?
i thought flush five was 16 x 160, and mines 18 x 180
I misread your code
mmm
how hard would it be to start learning how to make editions+shaders? The idea I have atm is something I can easily replicate in Krita, for refrence. (I invert the image then use the original image as a luminosity layer, to create a sort of "negative color" effect and not total inversion)
because i'm checking a few luas for it rn and i can't seem to find anything
misc_functions
but you can global search (with vscode for example)
I tried again with just mult and not bonus and it still doesn't add the mult so I'm confused
i found get_flush(hand) but i don't know how that's meant to help me with coding puyo chain
I don't get why bonus would work but not mult
i got the shaders working! now all i need to do is find out how to have music play :0
do i just have to put that in the code for it
just like
put get_flush(hand) into there
I changed the concept a bit and replaced the Inversion part with a green negative layer
think this would look really good with a shine of some kind
is the entire code just gonna be
for _, v in ipairs(SMODS.Suit.obj_buffer) do
if (SMODS.Suits[v].mod or {}).id == 'puyomod' then suits[v] = 0 end
end
get_flush(hand)
end
self insert go brrrrr
nah, i was thinking you can follow the structure of how that function is set up
like change the initial suits setup and then use the same code
so this
for _, v in ipairs(SMODS.Suit.obj_buffer) do
if (SMODS.Suits[v].mod or {}).id == 'puyomod' then suits[v] = 0 end
then the code for a flush
I love it
the suit table in that function is set up different
instead of this
if (SMODS.Suits[v].mod or {}).id == 'puyomod' then suits[v] = 0 end
you'll want this
if (SMODS.Suits[v].mod or {}).id == 'puyomod' then suits[#suits+1] = v end
i found the code for flush!!!
so do i just take this and put it into the code
rn i have this setup for it, but theres probably a better way for consumables and stuff since with this method i'd have to specify tarot, planet, etc
card.ability.extra.greencount = 0
for k, v in pairs(G.jokers.cards) do
local _joker = v.config.center.key
local joker_txt = G.localization.descriptions.Joker[_joker]
for i = 1, #joker_txt.text do
if string.find(joker_txt.text[i], "C:green") then
card.ability.extra.greencount = card.ability.extra.greencount + 1
end
end
end
ngl i thought you were already looking at that
no i literally just found it
why are you looking at that in notepad though
you could just open the dumps in vscode
or like
have your full mods folder open in there
then you could also use its search functionality 🤔
i have the lua itself open in vscode\
so like
do i just take this and put it into there
take the entire function
and just throw it into my code
like this
or is that
bad
listen i just want this over with so i can show all my friends what i did
yeah i dont feel like this is correct
you still need to replace the definition of suits
local suits = {}
for _, v in ipairs(SMODS.Suit.obj_buffer) do
if (SMODS.Suits[v].mod or {}).id == 'puyomod' then suits[#suits+1] = v end
end
Hey guys, do you know how to make a booster spawn with an edition? I can manually apply one using Debugplus, but I would love for special booster packs I am making to appear with an edition (which would apply the shaders I made)
bam\
so now i just do it for every variation
chain house, chain five, straight chain
though straight also has a royal variant
Worlds 1/3 done
Anyone have any insight on this, I've been digging around trying to figure this out but nothing's turning up
this counts as a flush house instead of a chain house
everything else is fine though
is there any way to make this count as a chain house and not a flush house
Made my first vouchers, what do you guys think?
Nice
a highlight on "booster pack" might help
feels like something thunk would do anyway
chain five counts as a flush five and a rainbow five counts as a five of a kind
i would like this to not be the case
but how would i fix that
I'm assuming flush five is a subset of chain five etc?
There has to be some sort of priority system
i'm checking and i don't see anything like that
unless you mean above_hand
Getting this would be really fun with THIS GUY on deck
is there any way for me to bypass discovery when creating a card without hooking this line to force my own card area into it?
wait, what
why are my jokers showing error instead of the intended suit
don't tell me i fucked up my localization...
show code
If your modded hands have lower chips*mult but need higher priority (for some reason - seems weird) then yes, use that
for the joker?
what? that's baked into the joker itself
but i fixed it so it's all good
this SHOULD work
chain five and rainbow five now work
I'm really happy I got Worlds working
chain house still counts as flush house though
What mod has these amazing looking joklers? I am in love
definitely NOT PuyoMod
how do you make a joker with an extra variable (like hands remaining, for seltzer) that gets set to some value
not sure what to use to initially set the variable
you just set the variable in the config
ohhh cool
Hmmm I found a similar bug with a previous version of SMOD but I have the most recent version so... hm
got it fully working, it detects the wheel of fortune, glass card, and lucky card i have as well as the two jokers here
anyone happen to know how to add a localization entry while the game is running
what are you actually trying to do?
well this is the joker im working on, you can see it has tooltips for each of its effects
what im currently trying to do is create a default ability that it will gain from any boss blind it doesn't have an effect coded for
which means i would need to, on the spot, create a tooltip with the blind's name
just +125 chips probably
ahh I see
you might be able to do something with process_loc_text (smods), but I'm not sure; there might just be a better/simpler approach
or possibly init_localization (vanilla)
mind keeping this to #⚙・modding-general if you're not developing a mod?
ok sorry didnt know where to post this tbh and since developing would mean that u know code maybe u could help me but yea won post it here anymore
there its gone
I'll take a look
how do you call a custom sound and/or change the default soundtrack?
did you look at the sound docs?
oh those exist?
sooo adorable
Mod link plz
be warned that you have to use your mod prefix for every sound. and they need to be defined specially in the root of your module
IN your config.lua*
Alright I give up, I can't find anything on this enhancement mult issue, I have to assume it's an issue with SMOD cause I can't for the life of me find a reason it shouldn't be working
what's your smods version?
I updated it to the most recent version since I saw there was an issue on a previous version, so I'm on 0314c
yeah then it should work. 2 weeks back we did have an issue with enhancement mult not applying
I literally deleted my old smods main folder and replaced it so I can't imagine I left something behind
and you've tested on a new run?
then it's too 1am for my brain to pick up on what's up with that
drop me the code and I can have a look tomorrow
If you wanted a deck to start with an eternal joker, would that be with
"joker:set_ability"? Or is there another function?
is there a way to change the description of a joker mid-game?
IIRC you can change the key by overriding it in loc_vars
not released
how would i do that?
refer to the loc_vars section
if what you want is more dynamic than switching between a few preset descriptions then this wouldnt work though
key = "test_enhancement",
loc_txt = {
name = "Test Enhancement",
text = {
"Test"
}
},
atlas = "test_mod",
pos = { x = 5, y = 0 },
config = {
bonus = 2,
mult = 2
}
}```
I really stripped away everything else and still get the same result so I'm so stumped
even if I take out the bonus chips its the same so
🤷
i have returned once more with my earlier issue
perhaps someone can help me with it now that some time has passed
calculate = function(self, card, context)
if context.discard and context.cardarea == G.play then
G.E_MANAGER:add_event(Event({
trigger = "after",
delay = 0.15,
func = function()
card:flip()
return true
end,
}))
G.E_MANAGER:add_event(Event({
trigger = "after",
delay = 0.15,
func = function()
card:set_ability(G.P_CENTERS["j_hpfx_ijiraq"])
play_sound("card1")
card:juice_up(0.3, 0.3)
return true
end,
}))
G.E_MANAGER:add_event(Event({
trigger = "after",
delay = 0.15,
func = function()
card:flip()
return true
end,
}))
end
end
this is supposed to trigger the events when i discard, but for some reason it doesnt
any idea why?
Just guessing but it might be context.cardarea == G.play messing you up
cause I don't think the card is in that zone after it's discarded
so do i change it off of G.play?
Mmm I'm looking at the example on the wiki and it just has context.discard and that's it
Oh actually it doesn't list G.play as an option for this context so maybe that is the issue
maybe it should be G.hand if you're discarding from hand
You're welcome! I'm glad it worked
i do not get how localization loading works
guess i might just have to make it say "Unknown's Heart"
You can make an en-us.lua file under a localization directory in your mod directory, instead of doing that
heya, im trying to get a mechanic similar to banner but its with mult and with chips (hands remaining for chips, discards for mult). ive been looking through the files and ive struggled to find anything
@warped marsh green joker might help you learn how to do that
hmm okay, can i dm you? i have general questions! (mostly about the files, and how to implement them)
sure but I will me afk for a bit
okay
has anyone ever had this crash before? I have no idea what's causing it
hard to know without looking at the code
the thing is, i don't even know what code to look at
ive been trying to find possible culprits but nothing seems to happen
looking at location of the error, that's the tprint function
so the issue is probably related to a string or something
yeah
where do i find those
yeah
im trying to get a random hand then change the description based on the hand
i have no idea what im doing tho so there's probably something wrong with it
let me see the code
anyone got any clue why this isnt working? it prevents every normal joker from spawning which is what i want, but none of the jokers with their yes_pool_flag set to alternate are spawning
wait nevermind im stupid
Hey y'all, dumb question for someone not too familiar with the coding side of modding.
I'm using 2 mods that add consumables (Cryptid and YART) and some of the consumables, in my opinion, spawn far too often. (All of the reversed tarot from YART, and the multi-hand planets from Cryptid) Is there a way to change individual consumable spawn rates? And if so, is it possible to have it sit in it's own mod so that if they get updated, I don't need to re-edit them again?
how do i play a custom sound effect? i know how to do custom music but no clue how to do a sfx
so the from_debuff in add_to_deck and remove_from_deck
does that do what i think it does
in that if you check if from_debuff is false, effects in the area don't happen if the card was added or removed because it was debuffed/undebuffed
that would be really convenient and easy
Hopefully yea
hopefully?
Ok yeah can confirm that is how it should work
is it just if from_debuff == false then or do i have to do some extra stuff
where is glass card shattering calculated?
so if not from_debuff or from_debuff ~= true then
I've looked everywhere I could think of and all I could find was the animations for when it shatters, but nothing that actually decides if it should shatter
that sounds like it should work
Just check that from_debuff is not truthy (so if not from_debuff then should work)
and I find it in state_events.lua as soon as I ask this
gg
does anyone know?
this should contain all the information needed https://github.com/Steamodded/smods/wiki/SMODS.Sound
Having a timing issue here I can't sort: I have a joker that retriggers scored enhancement effects (bonus mult, chips, xmult, and the lucky rolls), and I want the joker to play a message that says "Repeat!" similar to how full card retriggers say "Again!". I can get the message to play, but it always comes after the effect repeats rather than before.
if enhancement then
enhancement.message = localize('k_again_ex')
enhancement.message_card = card
SMODS.trigger_effects({{enhancement = enhancement}}, context.other_card)
end
if next(return_table) then
return_table.message_card = card
return_table.message = localize('k_again_ex')
return return_table
end```
This is basically what occurs, although I attempted to patch back in card_eval_status_text playing an extra function so I could try to force an event to append before the status text goes through, and that didn't seem to work. Only change when messing around with the event settings was seen above, where it overlaps the next card trigger rather than playing sequentially
It juices the joker at the same time that the effect occurs though
Hi, is there a guide somewhere to getting started making your own mods? I haven't been searching for very long but one place pointed me to this chat.
This page might help!!
smods/src/utils.lua is crashing here (line 239, marked with >>) what does this mean
function SMODS.insert_pool(pool, center, replace)
if replace == nil then replace = center.taken_ownership end
if replace then
for k, v in ipairs(pool) do
if v.key == center.key then
pool[k] = center
return
end
end
end
local prev_order = (pool[#pool] and pool[#pool].order) or 0
if prev_order ~= nil then
center.order = prev_order + 1
end
>>table.insert(pool, center)
end
on startup
They could have been so much worse
config is just a whatever
I'm getting a crash from trying to do this (most likely from the second and third calculate_effect calls) and I have no clue why. Crash report is of no help
Changing to 'chip_mod' gives the same crash
If anyone wants to try to make sense of the crash report then feel free
what are you trying to do
Apply the chips and mult of every hand contained in the played hand
so what's the SMODS.calculate_effect for
I can't just return because that'd stop the function. I know I could just add them up and apply all at once but that's no fun
calculate_effect is just that but better
what is it with smods like
making a bad function and then
instead of modifying the function
they make a second function
that is just a better version that still calls the original anyway
That's just cause they're not using SMODS right.
You can just return a table with extra that contains the messages/effects of the next thing to calculate
Rather than doing all this manually.
not my ass forgetting about an extra table 
Hihi :3
Also the diff is that SMODS.calculate_effect is that it's designed to eval all scoring elements, card_eval_status_text just displays text.
Along with the function just being really scuffed
(or at least it interfaces with the function that handles it)
alright I changed it to this which does work but it doesn't have the desired effect. I wanna display each value in its own message with the order being "hand name, chips, mult"
What's the best way to make a rare playing card that isn't likely to spawn?
I'm fairly certain the crux of this not working has something to do with the message components of calls 2 and 3, but I have no clue why
How would I go about making cards only spawn while a Joker is active and then no longer spawn when that Joker isn't in play?
I meant this.
Ok I understand this, but doing that returns out of the function making it only trigger once
how would i check if another steamodded mod is installed?
I mean it would trigger for only one contained hand type, would it not?
oh right
lmao
What even is the effect here, adding every single poker hand's chips and mult?
every single hand that the played hand contains (and isn't the scoring name)
Can't you just have the chips and mult be added together first then returned?
I get the loop but I don't get why we want to announce all hands.
Wouldn't that be a lot of time just spent waiting for this joker to finish if we play like a 5oak
It could potentially last a while yes, however imo it'd help visualize what exactly is being scored
I think I'm gonna take a break from working on Worlds
And again, the issue is stemming from the message part of calls 2 and 3
Can prob just make a recursive function that keeps adding an extra table for each poker hand.
does a list of all used consumables in a run exist anywhere or do I need to keep track of that myself?
for example, if I wanted to give the player their most used tarot card
how does the shop show the booster packs / cards / vouchers available in the shop?
was looking at Game:update_shop and i tried to read G.shop_jokers.cards but it's empty, same for shop_booster and shop_vouchers
per run? no
per profile? yes
you can check a player's profile card stats to see what the most used stuff are
the MultiPack mod does that with a "Favourite Pack" which contains top jokers on your stats list, i'd check that for a reference
ah i'll just keep track of the values myself then, I'm trying to do it per run
How do I make it so when I get this Joker in the shop or booster packs, it's always Foil?
I currently use the code
set_ability = function(self, card, initial, delay_sprites)
card:set_edition({foil = true}, true)
end```
It only applies in the Collection view, but not the actual game. What should I add or change?
whats the second bool of set edition control?
bump
hover over set_edition in the code and it tells you what the arguments are called
at least it does that on vscode lua plugin
I'm on mobile rn
oh wow, that was surprisingly easy
I'm trying to create a Joker that only triggers based on if a certain number of cards with a specific rank are in the scoring hand (i.e. three 7s are present, so the joker gets triggered once). Is there anything immediately built into the base game/SMODS to do check this or will I need to create a helper function?
Assuming the latter, would something like this work? context.scoring_hand[i].rank was mostly a guess on my part, as I'm not sure where to find a full list of member variables/functions for card objects, or anything within context actually. (Still new to this whole thing so bare with me lol)
it's actually [i].base.value
i made the same mistake
ah thank you
Does this have anything to do with the problem, or...?
What is the proper way to level up a hand through a card's return effect without the text on the left side getting messed up
i thought you need to actually change the text to match yourselves
as evident in planet cards stuff
at least that's what i did
hello chat how do I view the list of blinds in the ante and their corresponding skip tag and score requirements
is there like a list of antes in the game code? where is it
was trying G.GAME.blind_on_deck
i'm trying to make a joker with a very specific sprite size (76x76, i didn't do the art), what am i doing wrong? (it should theoretically look square, like how photograph does)
they're in G.GAME.round_resets.blind_choices structured like this
if you wanted to get info on the actual blinds you'd have to access that key in G.P_BLINDS, for example G.P_BLINDS.bl_small would have info on the basic small blind
DebugPlus
off-topic but i am surprised how much overlap the Balatro and TWOW communities have
hi sorry where are the skips associated to the blind? G.P_BLINDS only says the debuff and dollars
are there any mods that change the number of booster packs available in the shop?
They’re actually not attached to the blinds at all, moreso the UI box that holds the blind
hmmm
Poke around in UI_definitions.lua, it’s somewhere in there
Anyone know why this card is displaying "+X Mult" twice? This is my calculate code:
calculate = function (self, card, context)
if context.joker_main and not context.repetition then
PRINT_TABLE(context)
return {
mult = card.ability.extra.current,
message = localize { type = "variable", key = "a_mult", vars = { card.ability.extra.current } }
}
end
if context.end_of_round and not context.blueprint and not context.game_over and context.main_eval then
card.ability.extra.current = card.ability.extra.current + card.ability.extra.increase
return {
message = "Upgraded!",
colour = G.C.MULT,
card = card
}
end
end
I'm definitely missing some context check but I'm not sure what
(I fixed the duplicate Upgraded! text, forgot that was in the clip)
because you're using "mult" and not "mult_mod", the message displays automatically
so you don't need "message = localize{blablabla}" in that scenario
Yep that’s it
Got it
okay i found it thx 🙏
function create_UIBox_blind_tag(blind_choice, run_info)
...
local _tag = Tag(G.GAME.round_resets.blind_tags[blind_choice], nil, blind_choice)
👌
What exactly is the different between mult and mult_mod, just for future reference
whether or not the message displays
I see, thank you!
One last thing, is there a debug mod that lets you spawn in a specific card? i.e. if I made a new Joker I could spawn it in, or if I made a new Edition I could spawn a Joker/playing card in with that Edition, etc.
It’s also kind of a remnant of old_calc, as mult_mod was adding mult to the score from the joker directly while mult was for applying mult via a playing card triggered by a joker
DebugPlus!
debugplus
Really? I got debugplus and couldn't find that feature
Is there any way to use pound/hashtag symbols in name or description text, as an actual character?
Oh!
and if you want to change its edition, press q
Ctrl + q I thought
It's ctrl + q yeah
Use a \ before it like ’\#’
Thank you! I'll look into the keybinds more for stuff, thanks for letting me know
i have that setting disabled
oh I can't hook this, it just crashes D:
what's your hook looking like?
You can! I’ve done it before
local blind_tag = create_UIBox_blind_tag(blind_choice, run_info)
function create_UIBox_blind_tag(blind_choice, run_info)
local ret = blind_tag(blind_choice, run_info)
if G and G.GAME then
local _tag = Tag(G.GAME.round_resets.blind_tags[blind_choice], nil, blind_choice)
print("tag tag tag :3:3")
print(inspect(_tag))
end
return ret
end
remove the brackets from the end of the blind_tag variable
Can you pass a variable into the name of a joker, or just the description text?
just tested, yup, you can pass variables into the name of a joker
How do you do that? Loc vars docs seem to imply they only target the description by default
So I can have the variable, but I'm not sure how to actually pass it
that's how they're used in vanilla, but they do still target the name
just use it like you would in the description
Huh! Neat!
hey fellas. I am REALLY new at this, and just wanted to see if there was a way to make a quick and easy mod to rebalance the legendary jokers.
I got my ideas and implementation, hell im happy to just mod the actual sourcecode as well.
Anywhere i can go to mod the legedaries straight up? or are we recommending a modloader?
bump
Smods allows you take ownership of the legendaries, which will let you change them as needed!
how do I mod soul to be buyable in ghost deck
I made my first joker yesterday, how would I go about my second in terms of coding it. I am asking specific would I create a new lua script? Or would I continue from my previoiusu?
My script rn
you can continue on your main.lua but i recommend to separate the jokers into their own individual script
can you give an example?
add modules folder
okay 1s
im new to coding so be wary
done
now i drag the main.lua (my joker) into it?
no
first make jokers folder inside the modules folder
then make a insert_joker_name.lua inside the jokers folder
okay 1s
then copy your joker code from main.lua then paste it into the insert_joker_name.lua
so my main.lua is being replaced into the insert jokers
gotcha 1s
done
do i remove the main.lua?
no
ok
make sure that the main.lua has assert(SMODS.load_file("./modules/jokers/insert_joker_name.lua"))() so it will run the file
because this is the script in main.lua
I can hop in vc if needed so it might be easier for you to explain
so you don't have to type 24/7
did you transfer the code into the script inside the joker folder? if yes, then delete the script inside the main.lua
yes i did
off topic but what kind of icons are those
okay done
i did it and made sure that it loaded afterwards
so in the Insert joker name, that's where I'd put my other jokers
i mean alongside that code, yea
yeah
but i mean that's the Location
good to note
okay
time to try and make a joker (im bad at coding lmaoooo)
OKay
so for assets, I just put it in the assets folder, under 1x and 2x sizes
yes
Can i edit the legendaries in the base game? Where are they located?
while I’m not against learning how to do it, I’ve never used smods
Thats the other thing. Im changing Canio into a ^MULT joker (like the ones in cryptd)
Since ^MULT isnt in the base game is this gonna require its own mod then?
the base game has code spread out over various places, you'll wanna look for their ability name in the source code. If you've worked with code before, looking into SMODS isn't too difficult either.
Oh yeah for that you definitely need SMODS
and I think Talisman? I'm not sure if base SMODS implements ^MULT
aye lmfao 😭
okay
Is there like
a good tutorial around for smods or will one of you fine jokermen be aval to help a poor soul out
(I have coded extensively in a lot of languages including LUI so i pick up real fast)
just like
a kickstart to “how to change joker behavior” or “how to add own mechanics” like ^MULT lol
i picked up Lua pretty quickly and I come from C#
I know C++,# etc, I just have no idea where to start on something like this
Lemme grab the wiki and I think there's a thread now how to get started!
Maybe I should look at like a nice and easy mod that adds like 10 jokers?
Why is this not recognized as a card
PEAK?!
i just figured out why.
I’ll probably just download like a +10 custom joker mod and look at that tbh
If you've done C# you'll pick it up in half an hour at most 😛 The most difficult thing is having to look at code sometimes to figure out how something works because while the documentation is there, it's incomplete or assumes some competency
I've learned a lot looking at the code for Paperback! Cryptid's also a common one to look at, but that does rely heavily on lovely patches, i think, so not everybody's a fan of that
I started yesterday around 24 hours ago on top of the discord, the 2 biggest resources is:
https://github.com/Steamodded/examples/blob/master/Mods/ExampleJokersMod/ModdedVanilla.lua
https://github.com/Steamodded/smods/wiki/SMODS.Joker
Ay, I was just gonna sent that! Thanks waffles 😛
np
This code doesn't created a card why? the test.png is proper and the code works for a different card
I am drunker than a sailor now so this message is so i can come baxk tmr lmfso
Again. Thank you.
I mostly look at:
- Ortalab
- Paperback
- Cryptid
- Pokermon
Hows Neatos?
Ortalab I trust the most because Eremel is a regular SMODS contributor
Neato Jokers is a pretty good place to start as well
how to destroy an enhanced card after scoring ends?
You can thank me by sending a chain email to 10 people to play #1340334060597285025 or they will die in 7 days 😉
give me a sec, I'll look it over 😄
Oh!
ty! I am very new but I am trying to learn
been there, haha. I'm not seeing an immediate error. Is this in a separate file from your main mod file?
mind you, this code is not what im doing for a new card, This is just to see if the card shows up if theres any easier ways to format, or write this please tell me?, this card is using a copied cards code
1s
I'm still quite proud of this code I did for Missing Poster
I anticipated having to change the entire straight algorithm but then I realized I could just do this
as in, it's in a separate file? What does your file loading code look like?
This is all the info I have
it send jokers twice
this is what i meant to send
So it's wafflesmod > modules > jokers > then its the script here
haha you're too quick with providing answers 😛 I can barely ask the question. Is it sharing a key with the kittenandwaffles joker?
idk what that means, i'm very new to the coding aspect, I think it does if you're refering to line 8?
Would it need different keys?
keys must be unique
okay
keys are how jokers are referenced internally. On line 8, yeah!
should they be unique to the name?
yes, fully unique
okay! let me just do waffles1 and so on
I can slow down if needed, I mostly just screen shot my code it's fair easy than typing and less clutter
also, personal preference on my part, but I always name my joker keys the same thing as the file, without capitalization, which helps with automating a bunch of things, but that may be a few too many steps in the future, haha
oh no, it's helpful, no worries!
gotcha! Imma copy that idea
but if you're afraid of cluttering the channel, you can dm some screenshots too. How are you handeling the atlases? Does each joker file have its own atlas defined, currently?
most likely not
1s checking if it works rn
doing some sprite work atm, so feel free to ping me if I don't respond, haha
okay, I will ask you if I have any questions
good luck!
ty
u2
okay so update!
The card offically works however the actual display is wrong.
The assets folder works in the following format:
Mods > wafflesmods > assets > (two folders of the 1x and 2x for image scaling)
In each of the 1x and 2x folders there is two images, one of the test logo (A while logo with the word test, and 'a kitten and waffles.') Named accordingly.How amI messing up ?
@hushed field
Ah, okay. Atlases can handle multiple images on the same sprite sheet. Depending on what you're mod goal is, that might be something you wanna look into, but I don't see a problem with this for being a small mod! I suspect the image is wrong for that very same key reason, btw!
atlases also need unique identifiers for keys
Okay so from waht I'm getting, the images need seperate folders for each different joker?
also i'm confused how the keys play a role in coding? (as in like Do they match with the joker script for the image?)
no, images don't need separate folders! 1X and 2X are all the image folders you're going to need!
so the issue is tghe key
because the way most code works, things tend to have two names: an internal name, and an external name. The external name, however, is probably one you want to be able to translate. Or maybe change during development. So any object has a key, which is the internal name. This is it's unique identifier so you can refer to it and your code will know what you're talking about.
this helps so much
so external name is the file or code or image
and the internal name is the key
no, the file name is the file name. The best way to look at that is that a file is just the box that things are in. On that box, you may write the same name as what you're putting in it, but it doesn't have to be. Files are much more an organizational tool.
so in this scenario would I just do unique keys or for the test image would I do like test1 since test is taken by the lua code?
If you want to do more complicated things with your files (for example, some mods load their jokers in by iterating over file names, so they're named after the object they contain), you want the names to line up, but they don't have to.
okay, what do you reccomend?
This has to do with the fact that you can choose to put all your jokers in one file, or choose to separate them out. I personally separated them out, but that's because my mod has 200 jokers, and I don't want a single file that's 20k lines long. It's entirely up to personal preference
i see that makes sense
soemone earlier told me to have seperate codes for the jokers because its easier to organize
I'd say so too, but it does come with some other hurdles. If you're learning coding, do what you understand so that you're not taking ten steps at the same time, and focus on understanding the one you're taking. That way you also learn what preferences you have
okay from waht I know, I just changed the key for the test code(the top part) for the code and its still the cat image, what could be an issue of this
The 'external name' is I'm calling it, is the localization name, or we could call it the user-facing name. It's what gets displayed when you launch the game. Your code basically never refers to this name, except in that localization spot where you set the name
i see
So, how much do you know about the way atlases work?
very little but after I fix this issue of the image I havea few lua videos lined up in my browser
The main thing is that I think I can fix what you're running into now, but there's a more efficient way to go about it that may need a bit more explanation, haha
ill watch those to get a better understanding of coding because I did code in unity during middle school and found it fun, but its hard if I'm trying to do too much with the basics
I have all the time in the world if you do as well lmao
if you changed the key of the atlas for the test image, did you also change the 'atlas = ' part of the test joker?
no
just changed it now
An atlas and a joker being in the same file doesn't actually tell the joker that it's image is contained in that atlas. The joker's code instead checks the key stored in the 'atlas=' part of the code, and then looks at all atlases you have, and goes to the one with that key. (That's a pretty immediate example of how keys are used in coding)
okay that makes alot of sense because if multiple things are in the samefile it would crash the code, so the keys are a way to reference unique parts of the file, without referencing the whole file?
If you're planning on adding more than a few jokers to your mod, I'd try and see how atlases work with sprite sheets, but that's probably easier to understand once you've watched some videos on lua
oh 100% I plan to watch some videos to get a better grasp
Thank you
once you're code is running, files aren't something that's really considered. As I said, they're mostly an organizational tool. For example, in my mod, I have jokers in separate .lua files, but all my atlases are set in the main file of my mod. Setting an object just gives it an address you can visit with other code
okay that makes sense
Working with code that's separated out across files was something I always felt a bit uncomfortable with when I first started coding, so it's a very normal thing to run into and make mistakes with, haha
okay! I use visual studio code, what extensions should I have for it
I have intelliskript, skript, skript + skriptinsight, skript autocompletions, skript-vscode.
I'm a bad person to ask for that, I just use the lua extension for autoformatting, haha
I'm starting with basic text code, and it won't run without debugging, why is that?
ah okay, well thanks regardless you've been a ton of help!
Haha, bad news here is that I've never worked with lua outside of the computercraft mod for minecraft, and balatro, so I have no clue how to run it normally. Probably won't be too complicated once you know a bit more, but I have no clue haha
lol minecraft go brr
been playing that game for 11 years, was a builder for servers
the memories fly by
i remember indev 🥲
lmaooo
you have to install lua on your computer to run lua files
can visual studio code not run it?
you should follow this guide https://github.com/LazerLars/how_to_setup_lua_in_windows11_and_vscode
it will set you up with everything you need from lua
all the extensions for vscode, lua itself etc
i dont have windows 11.
it should work for windows 10
k
why do you want to install lua, anyway
if you want to make balatro mods, you load them into balatro
How could one make a joker only affect itself and not other copies of that joker?
jokers normally only affect themselves, what specifically are you trying to do?
Because a part of learning coding isn't just learning it to a specific game. It's hard to grasp a concept if it only applies to one specific game out of the millions?
I'm trying to make a joker that retriggers itself 5 times but also be blueprint.
I mean you are right that running code doesn't mean learning it :/
you can still use that setup to run generic code that isn't specific to the game though
just check that the card object is the same as your joker instead of checking something like the card key
are you saying to put it in balatro?
all I'm saying is that you can set up a mod and use that to run literally any code you want
you're also given the context of the game, which is useful if you want to learn about how it works. but it doesn't take anything away
I'm not just trying to learn lua for this game, I'm trying to learn lua as a whole.
Like this?
That retriggers itself but also if there is the same joker in front of it it will also retrigger that 5 times.
like i said there's no restrictions in doing it either way. but sure, do it without the game if you really want to
hmm no idea then, I don't think that should normally happen
You mean if you have another copy that will also trigger five times?
If it is in front of it yes.
Isn’t it just retriggering itself?
No, what happens is the first one retriggers 5 times then it retriggers the second one then the second one retriggers itself 5 times.
Can you show the full code?
So it’s supposed to copy the joker to the right of it 5 times?
Yes, basically.
Okay so I don’t think you want to use retriggering for that
You just want to do the blueprint effect 5 times
How?
Well it depends on the wording of your joker actually
why do the card name and effect not show?
loc_txt instead of loc_text
Also for some reason it prevents jokers from upgrading.
i keep getting the error attempt to index local 'other' (a nil value) and I can't figure out what it actually means, i think it might be something to do with the revive seal copying the card?
ive gotten the error when copying it several times with hanged man, and when having it as a glass card
So what’s the intended pattern of there are 2 next to each other?
The first one triggers 6 times the second one triggers 6 times both copying what is to the right.
I think I’d just use a loop and the blueprint util function to do that
But that might end up triggering the first one too much
Hmmmm
ok this also triggers whenever you used hanged man on a glass card with the seal?? i genuinely cant figure out whats going on here for the life of me
ohhh
im destroying from hand.highlighted instead of the card with the seal
thats probably causing issues
oh god. glass card with revive seal and 2 all sixes jokers
every time you play it it duplicates
Does anyone know the key for the jimbo pack and the store? I'm trying to get my World Jokers to only appear in my custom booster for them
@hushed field @hasty thicket there are WILD things being done in GIMP studios right now
i dont even know what im gonna make him do
but he is gonna be beautiful
Definitely gonna have to be something with Face cards
The Jorker
Oh my god
LMFAO
I didnt even realize it said Jorker 😭
It’s beautiful
ikr
Jorker: All face cards count as Kings, Queens and Jacks.
@verbal wyvern
oh wait you gotta see this shit
its not over
What if all face cards count as Kings and Queens, goes hard with Trib and Paredoilia
im making all face cards count as all face cards lol
paredolia with this would be fucking nuts
Idol even
reworking em as well
I think my favorite Joker ive made so far has gotta be my Metal Pipe joker
Chicora: Permanently REVERSES the effect of the Boss Blind (and makes it positive if possible)
Retriggeres all Aces, and all Aces are considered Wild Cards.
Able to be Blueprinted and or Brainstormed
This would make stuff like The Manacle give +1 hand size permanently
Water could give like 6 Discards
Yorelle: This Joker gives you +0 discard at the start of the round and x1 mult
Gains +1 Discard and X1 MULT each 23 discards, (this value increases by 10 every time Yorick is Upgraded)
Gains +2 chips for each card discarded (resets every time you defeat a blind)
Cania: This Joker gains 0.01^ MULT each time a Face Card or Ace is Destroyed, Starts at 1
Perkea :This joker creates a negative copy of a random consumable at the end of the shop. 1 in 30 chance to create a negative Spectral Card each time a Tarot Card is used. Gains 1$ of sell value for each Spectral Card Used
Tribulea: This Joker gives , X2 Mult each time a Queen is scored. This value is increased by X0.1 each time a King is scored or X0.15 each time a Jack is Discarded. Resets to X2 upon defeating the Blind.
Tribulet (other idea): This Joker gives , X1 Mult each time a Queen is scored. This value is increased by X0.02 each time a King is scored or X0.03 each time a Jack is Discarded.
peak
^
These go hard
I have yet to do anything with ^ values but one day
why make them more op?
Simple.
The Soul card now TRANSFORMS a joker into a legendrie (notice the spelling)
Heyo!! Anybody know how the Misprint joker works and how to recreate it?
Wild af
im just trying to figure out how jokers work lmao
but
i saw this
seems it just takes a random mult
^ something like that
I have a Multprint joker that gives a random Xmult at the end of round
Still working out implementing the text though
The description is blank. i think there is an outsider function causing it to be that random crap
I think it does something with dynatext shit near where you see it's code but I hadn't figured out how to implement it for other jokers
I thinks its just as simple as having the string in your code then calling it out in the text but
I havent figured it out yet so dont take my word for it
key = 'Multprint',
loc_txt = {
name = 'Multprint',
text = {
'',
''
}
},
atlas = 'ExionJonkers',
pos = {x = 5, y = 0},
config = { extra = {
Xmult_min = 1,
Xmult_max = 5
}
},
calculate = function(self, card, context)
if context.joker_main then
local temp_XMult = pseudorandom('Multprint', card.ability.extra.Xmult_min, card.ability.extra.Xmult_max)
return {
Xmult = temp_XMult,
card = card
}
end
end
}```
This is my Multprint code atm
Should help with what you need
Prepare for a programming nightmare 😋
These are from the Legendere Texture mod if you want them
Misprint does use a dynatext, which is I think automatically just parsed properly by the ui functions
i know...
Ooh mayhaps
Me and my friend are working on our own legendarys rn based off us and some friends
Might replace the base ones or just add them
yep. i just went through and actually renamed them, and then just put them on the actual png instead of using a mod
changed the actual nameplates singe legendere textures didnt do that
and then i plan on tweakin em SLIGHTLY
Coding Balatro mods is such a nice break from what im used to modding
Im used to doing stuff for like Arma 3/ DayZ and this is so much easier 😭
terrified to even attempt to program chicora since im basically programming the bug that exists in game into a feature
even more scared to attempt cania. might just steal ^MULT code from cryptd tho
not even gonna think about how rough Yorelle will be with the permant increase to discards, i guess ill steal burgular code to start?
@verbal wyvern smods can "take over" vanilla jokers yes?
Yeah I feel like Yorrelle or Perkea might be easiest
like i can reprog them with SMOD?
Yes
Well they're still the original Jokers
and having them on a separate atlas is better
the png yeah
@zealous glen oh the retexured legendaries is just cause a friend of mine wanted em but didnt wanna install any modloarders
so i just decided to repaint jokers.png for em
It doesn't violate the rules, it's resistant to updates (by being a SMODS mod), and as a Malverk mod can be combined with other textures
i dont plan on merging my legendary rework with legendarie jokers
In Smodded wiki in API Documentation you can find the Take Ownership stuff
updating the game will overwrite the textures AFAIK
unless i contact the mod creator of legendarie jokers and ask to collab
without a modloader
ooh i see
and distributing it I feel like would be a violation of the rules
wait can I reprog the ingame sprites using smods or lovely patches?
technically you don't even need them, but it is recommended that you use at least SMODS
I also recommend Malverk
I will prob reach out to eaze and see if he wants to collab, otheriwse im absolutely not going to include the remade sprites in any mod i make dont worry lol
Sorry to pop in again, but yall know how I can change the joker sprites only while the mod is active?
Have you watched that one youtube video on making modded jokers
yeah
who u
So if you have your joker with your custom sprite in your mod yeah it wont be there if you reload
Did you make a backup of your vanilla folder?
I meant change the vanilla jokers, sorry
yup
bro forgot i interacted with him an hour ago
an hour ago i was sitting on my bed watching yt
three hours lol
. . .
Yeah you still can, youll just have to take ownership of the joker you want to reskin and use your custom png and callout the column and row in the pos
you
bro confused 1/8 of the day with an hour
you literally like
im trolling you Lmaooo
this guy
😭
manifesting hammers above you
you didnt even spell freese right
oh i did
Thats wild
cap
Proper Nouns are always spelled right
thank you!!! have been struggling alot haha
:)
we dont accept people as nouns nowadays.
Real shit
noun (proper)
its the new thing
its like
fancy nouns
where you can make random bullshit
cap, Proper nouns are name of nouns.
new earth mod
thought you would find funny
i didnt
jorker
lmaoo your more experienced than I am
I started coding 2 days ago.
Ahem, you're*
Ahem, you're. If you're gonna correct me, do it properly.
yrou're
uhhhhh.... sorry to ask but what does it mean to "take ownership" of the joker?
Its basically what it says, in your code you can take ownership of preexisting vanilla content and change it up
basically
...yeah he said it
sorry gain, I'm pretty stupid 🙏
your mod basically takes the vanilla joker, rewrites it from scratch, puts your twists on it and throws it back into the game with new shit
Its at the bottom of that page
How is it taking ownership if your just cutting and copying certain parts of code and taking ownership of it when you didn't produce the original part...?
Is that not how they copyright songs and essays?
That idk I didnt make steam Modded
But its also just a code value
Not like
Actually taking ownership
You basically just add the vanilla asset to your mod
ig
It will still be part of the base game and function like normal when you unload your mod but whilr your mod is loaded anything you change will be in effect
.
@wintry swallow if you havent and have the time before you get modding I would go through the steammodded wiki and just, read all of it
You’ll likely be going back to it while coding but it can help you understand it more beforehand
Thank you for the tips! I'm gonna grab something to eat and then continue
yall wanna know what i love
pancakes
vertical monitors that flip 🙂
I do all my coding on my laptop so god I wish
You can see the whole page 😭
Hihi :3
I'm gonna work on making some Jokers, consumables and a new modifier today. Actually get the content of each world before I limit that content to said world.
My monitor's 12 by 12 pixels and flashes each letter to my individually at lightning speed
Should I give Worlds effects besides giving you access to content that you couldn't get otherwise?
Considering making a card that will subtract money to add multipliers, and one that does the opposite:
Example would be if you have X cash, then you subtract it, and gain X bonus.
Or
If you have X bonus, you subtract it to gain X cash
good morning everyone
I have a similar effect in my mod and it's one of my favorites to play with
Morning Bepis
perhaps it wouldn't work every time, mabybe every time it sells a consumable during the round, or even per discard.
my morning btw :3
I personally enjoy a good risk and reward joker, so having to sell out to save your economy is an interesting choice, I'd say
My version changes xmult and cost depending on its positioning, and self destructs if you can't pay for it, and I personally enjoyed the active choices it's made me make
i might do it depending on the hand played, like if a flush is played it causes the event
add a gazillion jokers
bro if only you new how bad i am
i started 2 days ago
😭
Hmm... What other worlds could I add btw? I know I wanna add Mushroom Kingdom, and I already have a Yume Nikki-themed world.
less than 48 hours
i started a month ago ❤️
infinite craft in balatro
fire idea
Oh you're making a Balatro mod? It's not really a mod unless you add 150 jokers, a new consumeable, and a board game from your youth to the game, sorry
oh hi bepis
😭😭😭😭😭😭😭
it's an addon
hi dilly
the color is not coloring 😭
-# i almost said diddy again
my goat ice present too and aiko
you want me to fall off a house so bad
oh but also
i suggest using "inactive" for that one instead
its used for text like that
-# maybe?
im sorry 😭
Hmm... I could probably add some worlds that aren't references? Probably?
A mod is only a mod if every single joker is a very explicit reference, sorry
im so fucked my mod is cooked
what abt a mod for food
well arent u fweakin special..
gray doesnt work , inactive works
please be more specific, a lot of mods add food 💔
i see
gray probably doesnt exist then
a mod that orders pizza in real life when a royal flush is scored
is it a random pizza, or one tailored to you
random
here me out, only consumables will be food, jokers will be pots, pans, and other cooking utilities, or that might be planet cards.
that sure is a gamble
IM DEF DOING THAT
Ingredients based on the played ranks ofc
for a royal flush?
yea idk how we manage that one
I missed the Royal haha
heres all the available colors
suit and rank combined equals ingredient
soo cooking?
hey thats my screenshot
i thought about a cooking mod too lmfao
i told ya, i collect images :3
If you want, I can see if I can see if I can make a proper generic version of my mod's food consumeable, if your ideas'd work with it, haha
our screenshot now
I'm adding Potion Crafting eventually. That counts as cooking, right?
go ahead comrades
yes
mhm, thats cool
no bc mines real
You'll have to check Kino to see if it's a type of food that works like you want in any way though, I'm sure there have been thousands of ways to implement food consumeables
we shall see
Also good motivation to take out their dependency on tags and just make them fully card objects, instead of tag spawners
What does E:3 even do? Wobble harder?
shakes the entire screen
i dont think theres an e3, it got cancelled for the summer game fest
I'm gonna add Runes and Potion Crafting soon. But first, I need to finish the Yume Nikki Reference
so true
i think there was a way to add to INFO_QUEUE stuff straight from localization
time to find that one image i saved a few weeks ago
I did mean E:2 but apparently E:2 makes the train shake so I mistyped
wdym
like this?
oh yeah, that
:3
i got this one from when Riv_Falcon posted on here
24/2
-# why do i look like a stalker doing this
I should put some effort into properly writing my glossary because I don't think people are gonna understand spellcasting at all if they don't run into Fantasy cards
My issue has something to do with the values or naming, because the Xmult isn't being rendered.
{X:mult,C:white}
