#💻・modding-dev

1 messages · Page 40 of 1

solid salmon
#

my mod is doing fine

brisk pond
#

that's not a word in my vocabulary

solid salmon
#

9 jokers, 5 editions and 4 packs

brisk pond
austere charm
crisp coral
#

if i had a nickel for every modder whose name sounds similar to myst, i would have two nickels

solid salmon
#

i have 17 splash fusions to make

#

like this

brisk pond
#

Arsène (Rare) (Linked to: The World)

  • RK1: Copies the ability of Joker to the left
  • RK5: Copies the ability of Joker to the left, 1 in 3 chance to do it twice
  • RK9: Copies the ability of Joker to the left, +1 Joker slot
  • RK10: Copies the ability of Joker to the left, +2 Joker slots
maiden phoenix
brisk pond
solid salmon
#

i just wish that i had someone to make art

hallow forge
#

i just found out about SMODS.PayoutArg

solid salmon
#

no

hallow forge
#

it's a thing for hands remainign and remining discards stuff

crisp coral
hallow forge
#

it doesn't seem to be used very much tho

languid mirage
#

I actually wanted to use it

hallow forge
#

and i feel it needs to be fleshed out more

solid salmon
brisk pond
hallow forge
#

like there is no function to tell it to now show up on the pay out screen

hallow forge
crisp coral
#

the other math

hallow forge
#

but, i think they meant mathisfun

maiden phoenix
#

Still want to see Mathguy vs Mathisfun in a pit fight

brisk pond
solid salmon
brisk pond
#

got it right?

solid salmon
#

i misclicked

crisp coral
#

what NT is nobody will know

languid mirage
#

Actually mathguy wasn't talking about joker retriggers

crisp coral
#

oh

languid mirage
#

I was tho

crisp coral
#

Oh.

#

reading comprehension fail

languid mirage
#

Didn't realise in the moment lol

#

Same

brisk pond
#

I got this Joker that adds 20 chips at every scored card.

calculate = function(self,card,context)
        if context.individual and context.cardarea == G.play then
            return {
                chips = 20,
                card = self
            }
        end
end
#

but it crashes

primal radish
#

Does anyone know where to get the mod to get rid of scoring animation

crisp coral
hallow forge
brisk pond
frosty dock
#

self in Card:calculate_joker() is actually passed to calculate as card, self is the center proto object, not the card itself

frosty dock
#

just replace card = self with card = card

solid salmon
#

hey is there a consumable version of card.ability.extra?

austere charm
#

an object in lua is defined like {key1 = value1, key2 = value2, etc.}

#

where keys are strings, just pieces of text, while the values can be anything lua allows

crisp coral
austere charm
#

"wait, it's all just cards?"

hallow forge
#

"no"

solid salmon
#

I can't art, i don't have time to art, and i want to make cards not art but apparently card ugly with no art

hallow forge
#

oof

solid salmon
#

this was literally the best thing i could make

brisk pond
solid salmon
brisk pond
solid salmon
#

i did the same thing for blue and red. and it worked

languid mirage
#

learned that the hard way

solid salmon
#

this crashes the game

crisp coral
#

what is center

frosty dock
#

💀

#

it even tells you what's wrong if you select it

solid salmon
#

buh

#

i changed it to self

#

and it is no longer wrong

frosty dock
#

needs to be card

#

not self

solid salmon
#

oh

frosty dock
#

same thing that was discussed above

#

self is just the object's prototype, not the actual card

solid salmon
#

oh

stray warren
#

Yeah, I figured that. I just couldn't figure out how they accessed the chips value to multiply

solid salmon
#

i changed it to card

#

it still crashed

languid mirage
#

probably would be nice to add those in steamodded as well

mellow sable
#

I eventually plan to make a PR

languid mirage
#

retrigger jokers as well 🙏

solid salmon
#

what's wrong with my potion?

solemn coral
#

Does using 1/2 like that work? I think it might, but it's usually better practice to type it out explicitly as 0.5

crisp coral
#

technically works but i'd wrap it in parentheses if i were to do that

maiden phoenix
#

Also why do you even use loc_vars if you have no variables in your text?

languid mirage
solid salmon
#

how do i fix this error?

regal wolf
#

Are you creating your own mod? Or just trying to load someone elses?

solid salmon
#

me

#

mod

regal wolf
#

Well then it's crashing because you're attempting to index a nil value.

solid salmon
#

which is?

regal wolf
#

You're passing a nil argument into some function or calculation when it's expecting something else.

#

Lua method 'set_sprites' at file 'card.lua:166'

solid salmon
#

so i need sprites?

regal wolf
#

???

#

I can't tell you what you need, I can't see your code.

#

I can only tell you what the error means.

solid salmon
regal wolf
#

Can u just copy paste ur code here, instead of pasting a screenshot please lol. -- It's kind hard to read it.

solid salmon
#
    key = 'midas_mix',
    loc_txt = {
        name = 'Midas Mix',
        text = {'A gold potion may have rich flavor'},
    },
    set = 'Potion',
    pos = {x = 2,y = 0}, 
    config = {
        extra = 30
    },
    discovered = false,
    cost = 0,
    can_use = function() return true end,
    loc_vars = function(self, info_queue, card)
        return {vars = {1,card.ability.extra}}
    end,
    use = function(self,card,area)
        if pseudorandom('midas_mix') < 1/2 then
            card.ability.extra = card.ability.extra - 60
        else
            card.ability.extra = card.ability.extra  
    end
end

}```
regal wolf
#

Thanks

#

I cant see where you are calling set_sprite

#

does Steamodded.Consumable have a required sprite sheet argument?

crisp coral
#

atlas yes

regal wolf
#

I'm guessing that's what you're missing then (?)

solid salmon
#

so i do need sprites

regal wolf
#

??

crisp coral
#

all cards need an atlas to pull sprites from

regal wolf
#

If you're trying to make a card, of course u need sprites (?)

solid salmon
#

that made sense why red and blue work

elfin coral
regal wolf
#

LOL

solid salmon
#

🔫

regal wolf
#

doesn't steamodded have documentation for this (?)

crisp coral
#

incredible

#

it does

solid salmon
crisp coral
#

and center is one of the more fleshed out documentations

languid mirage
#

Spoonfeeding but all the code spills out

solid salmon
#

ok

#

but where am i going to find sprites

regal wolf
#

LOL

#

Dawg, u gotta make ur own

solid salmon
crisp coral
#

if i laugh my family's gonna wake up holy shit

solid salmon
#

you think i didn't try that

regal wolf
#

myst stop im trying to keep it together

regal wolf
solid salmon
#

making a sprite

regal wolf
#

ok..

#

did you pass it into the SMODS.Consumable ?

kind shadow
#

wait what is that

#

Is that a cape

crisp coral
#

potion

regal wolf
crisp coral
#

allegedly

solid salmon
kind shadow
regal wolf
#

Logan Paul x Wizards

#

It looks like a bottle of Prime

solid salmon
#

ik

crisp coral
#

HELP

#

im actually going to die

kind shadow
#

Honestly I would just download a png if i'm being real 😭

regal wolf
#

Myst ur so rude omdddd

solid salmon
#

what the hell did i turn this into

kind shadow
#

Nothing

regal wolf
#

Nothing, Nothing

#

Uhh, so yeah. Look I advise you read the Lua documentation, and the steamodded documentation.

solid salmon
#

no

regal wolf
#

oh, okay.

#

well then.

solid salmon
#

i did

#

so what would be the point

regal wolf
#

Did you?

solid salmon
#

Yes

regal wolf
#

Ah okay.

kind shadow
#

no way

regal wolf
#

STOP.

kind shadow
#

I'm so sorry

solid salmon
#

lol

regal wolf
#

No but where is the white stripe

kind shadow
#

on the outside

solid salmon
#

i think i should add it

crisp coral
solid salmon
solid salmon
kind shadow
#

don't use black in balatro art balatrojoker

unkempt thicket
solid salmon
#

LOL

mellow sable
#

You know what might be funny and fitting for the mod

solid salmon
#

yep

mellow sable
#

You could do the art by inserting images and downscaling them to fit in the sprite

regal wolf
maiden phoenix
solid salmon
#

oh no

#

im dying

regal wolf
solid salmon
regal wolf
regal wolf
mellow sable
solid salmon
#

im dying

regal wolf
#

LOLOLOLOL

mellow sable
# mellow sable

If you stick the image into the joker template it could actually work as an art style for your mod

solid salmon
#

that could make sense

#

but then i might get attacked by reshuffled

mellow sable
#

You’re not reshuffling anything tho

solid salmon
#

oh ye

mellow sable
#

Their art style is just doing everything all at once

solid salmon
#

ok

kind shadow
#

this is just what i did

regal wolf
solid salmon
#

...

#

that's enough prime

mellow sable
#

If I was on my computer I would send a proof of concept

solid salmon
#

or pepsi

hallow forge
#

this art is

regal wolf
#

pripsi max

solid salmon
#

you want to draw

regal wolf
#

not really

unkempt thicket
#

pripsi xma

regal wolf
#

its not prime, its washed 💀

solid salmon
#

it's not washed it's dirty 💀

regal wolf
kind shadow
solid salmon
#

is that ultrakill

kind shadow
#

ultrakill reference: accepted

solid salmon
#

im ultrakilled

#

imma make midas mix in photoshop

mellow sable
wintry solar
#

I think the atlas should default to the tarot one anyway right?

solid salmon
#

yeah

mellow sable
solid salmon
#

but i can art

#

stupidly

mellow sable
solid salmon
#

i already got one

#

but thx

#

now imma use my photoshop skills

wintry solar
#

Are they as good as your coding skills?

elfin coral
solid salmon
hallow forge
solid salmon
regal wolf
regal wolf
solid salmon
elfin coral
#

🫡

solid salmon
#

sorry spring

regal wolf
#

😔 ✋

solid salmon
#

imma put it in a wheel

#

to see who wins

elfin coral
#

oh no

#

my experience with wheels is not good

regal wolf
#

why not

#

like

#

wheels of death

#

car wheels

#

cart wheels

#

cart wheels

#

other wheels

solid salmon
regal wolf
#

rigged

solid salmon
#

how

regal wolf
#

rigged

elfin coral
solid salmon
#

sorry spring

mellow sable
solid salmon
#

but the wheel has chosen

regal wolf
mellow sable
#

you didn't consider my art though /j

regal wolf
#

the disrespect

solid salmon
regal wolf
#

also true

#

the disrespect

mellow sable
#

oh

#

rip

#

you'd probably want a different background for custom consumables

solid salmon
#

wait

#

i need to make it a png

regal wolf
#

@elfin coral ntsc-rs is v cool, i just had a look at it.

elfin coral
#

:D

regal wolf
#

its easing the pain of losing

solid salmon
regal wolf
solid salmon
#

perfect

regal wolf
#

either im crying, or my eyes are bleeding

solid salmon
#

ow my head

regal wolf
#

im joking

solid salmon
#

ik

regal wolf
#

altho the res is painful

solid salmon
#

ik that

regal wolf
#

have you heard of nearest neighbour

solid salmon
#

no

elfin coral
#

isnt that that one game that matpat made a theory about

regal wolf
#

no

#

its a type of scaling method 💀

#

IM DEAD

elfin coral
#

i'm just pulling your leg

regal wolf
#

oh

#

good one LOL

#

that made me laugh

mellow sable
solid salmon
#

should the gimmick of potions just be that they're all prime bottles

mellow sable
#

I thought you were talking about first past the post Valadaptive...

solid salmon
mellow sable
#

you should make the background like tarot cards but then all of the numbers are primes

#

2,3,5,7,...

solid salmon
#

meh

#

red and blue, and midas mix is done (in terms of sprites)

elfin coral
#

I can't see your code, but look at the differences between red and blue (the working one) and midas mix (the broken one)

glossy stone
#

i kinda want to learn modding so i can put my stupid joker / boss ideas in

elfin coral
#

That should help find the error

glossy stone
#

But I'll have to learn coding as well so.

#

i am going to have to die

maiden phoenix
glossy stone
#

yeah XD

glossy stone
maiden phoenix
#

^

regal wolf
glossy stone
#

ah, okay!
Time to add ANOTHER thing in my things to get good at :3 list
Miku_Happy

regal wolf
#

atlas should not be inside loc_txt

regal wolf
elfin coral
#

To be fair, atlas is listed as an "optional parameter"

#

Probably would've tripped me up as well

regal wolf
#

i think its optional bc u can use the default atlas if u add sprites to that, or reuse game sprites. but idk i dont use steamodded.

solid salmon
#

so it's not the atlas

#

eh im taking a break

kind shadow
wintry solar
#

The atlas is optional

#

It’ll default to the base one

solid salmon
#

yeah but midas mix keeps on crashing the game

#
    key = 'midas_mix',
    loc_txt = {
        name = 'Midas Mix',
        text = {'A gold potion may have rich flavor'},
    },
    set = 'Potion',
    pos = {x = 0,y = 0}, 
    discovered = false,
    cost = 0,
    can_use = function() return true end,
    loc_vars = function(self, info_queue, card)
        return {vars = {1,card.ability.extra}}
    end,
    use = function(self,card,area)
        if pseudorandom('midas_mix') < 1/2 then
            card.ability.extra = card.ability.extra - 60
            ease_dollars(-30)
        else
            card.ability.extra = card.ability.extra  
            ease_dollars(30)
    end
end,
atlas = 'midas_mix',
}
SMODS.Atlas {
    key = "midas_mix",
    path = "midas_mix.png",
    px = 71,
    py = 95
}```
wintry solar
#

It looks like betmma mods are messing with the set ability function to me

solid salmon
#

huh

wintry solar
#

What’s your ability even for?

#

Like you never use it

zealous glen
solid salmon
wintry solar
#

But you don’t use it

#

So why are you trying to reset it

solid salmon
#

idk

#

i just want a potion that magically gives money or takes it away

wintry solar
#

so get rid of your card.ability.extra stuff

solid salmon
#

all of it

wintry solar
#

well in the version you sent you don't ever define it so you're trying to adjust it when it doesn't exist

solid salmon
#

ok

#

i rid of it

hallow forge
languid mirage
#

What does charge to play mean there

hallow forge
#

it's supposed to say Charges $7 to play The Manacle

#

It takes $7 dollars, and you must have at least $7, and then The Manacle would be activated

wintry solar
#

how do you get these?

solid salmon
#

is there a G.GAME.round_resets.discards for money?

hallow forge
#

G.GAME.dollars?

solid salmon
#

thx

#

i did the atlas and it still doesn't work

#
    key = 'midas_mix',
    loc_txt = {
        name = 'Midas Mix',
        text = {'A gold potion with rich texture'
        },
    },
    set = 'potion',
    pos = {x = 0,y = 0}, 
    discovered = false,
    cost = 0,
    weight = 3,
    can_use = function() return true end,
    loc_vars = function(self, info_queue, card)
        return {vars = {1,2}}
    end,
    use = function(self,card,area)
        if pseudorandom('midas_mix') < 1/2 then
            G.GAME.dollars = G.GAME.dollars / 2
        else
            G.GAME.dollars = G.GAME.dollars * 2
    end
end,
atlas = 'midas_mix'
}
SMODS.Atlas {
    key = "midas_mix",
    path = "midas_mix.png",
    px = 71,
    py = 95
} ```
wintry solar
#

try updating betmma vouchers

solid salmon
#

ok

#

it still doesn't work

wintry solar
#

can I see the error message now?

solid salmon
wintry solar
#

can you try putting name = "test", in your card definition

solid salmon
#

i tried

#

and it crashed

wintry solar
#

same error?

#

hang on

#

send me your entire file in DM

hallow forge
#

@wintry solar , i found SMODS.PayoutArg in the Steamodded code and was thinking there should be a method to prevent the PayoutArg from showing up, like if it's 0 ot smthng

edgy reef
#

I forgor to add one 💀

hushed cradle
#

can someone please help me with something quickly

#

im trying to use a mod that adds seals to the game

#

but whenever i load up my game i get this

#

no idea what any of it means lol

frosty dock
#

I think that means you're missing some utility mod that this depends on

hushed cradle
#

thank you

#

is there a way i can figure out what it needs?

frosty dock
#

should be linked where you downloaded it, probably

hushed cradle
#

that makes sense lol

#

thank you

#

i have this util file to go along with it now but its giving the same error still :(

hushed cradle
#

i think maybe something is wrong with the inject sprites part of the util

#

it says its doing smth with a nil value

#

which would explain why i couldnt call the function before

solid salmon
zealous glen
#

Out-of-curiosity, how would you implement an effect that adds an extra repetition but with a percentage effectiveness?

#

I have some ideas but they don’t sound great

wintry solar
#

are you aware how to add an extra repetition?

zealous glen
wintry solar
#

can you not send an extra repetition from the source when required/

zealous glen
#

what do you mean?

regal wolf
#

have a look how brainstorm/blueprint works

#

I'm pretty sure they have a flag, which indicates the action is from them.

#

iirc

wintry solar
#

do your calculation in the joker and then return the correct number of repetitions

zealous glen
#

Blueprint and Brainstorm don't create repetitions

regal wolf
#

so u could just check if the action is from your joker, and then calculate some sort of % decrease

#

how wdym then

zealous glen
#

Seltzer creates repetitions

regal wolf
#

i thought u meant like a retrigger

#

ohhh

zealous glen
#

Blueprint and Brainstorm don't retrigger

#

Seltzer does

regal wolf
#

Blueprint and brainstorm have the effect of retriggering a joker.

zealous glen
zealous glen
regal wolf
#

...

#

dogmatic much

zealous glen
#

What do you think that word means

wintry solar
regal wolf
#

if u want ppl to help u, you should try being a bit nicer lol

zealous glen
regal wolf
#

every time i try help u, u keep arguing over every little thing

#

its crazy

zealous glen
#

But the repetition has partial effectiveness

wintry solar
#

oh right

#

that sounds like a hell of a rewrite to evaluate play

zealous glen
#

Maybe, which is why I'm asking for ideas

#

In principle I can hook the functions that evaluate Chips, Mult, etc. and check for a global variable in them

#

I think that's the idea that uses the least injections/overwrites, and, while not nice looking, might work

wintry solar
#

all the calculation is done within the stack though, the functions are given a final value and just update it

zealous glen
#

(Although that would make the card_eval_status_texts incorrect)

zealous glen
wintry solar
#

yes, but you can't hook the functions, assuming you mean mod_mult etc.

zealous glen
#

I can't?

wintry solar
#

they're just passed the calculated value

#

mod_mult(mult + effects[ii].mult)

#

funnily, the mod_mult function doesn't actually do anything too

zealous glen
#

Yeah, and inside them I multiply them by a value if some global is true

wintry solar
#

but that's going to multiply the previous value too

#

so you're applying your scalar more than once to each increment

zealous glen
#

Ah I see what you mean

#

I guess it'll need a lot of injections then

solid salmon
#

did i art

mellow sable
zealous glen
#

What does Boredom do?

mellow sable
#

1 in 2 chance to retrigger each played card or Joker

#

Basically I just return 1 retrigger with a 50% chance

zealous glen
#

See, I wanted to reduce the effectiveness to make it deterministic

#

Rather than random

solid salmon
mellow sable
#

So like every other?

zealous glen
#

Though I’ll test if the effect with integer retriggers is too strong before committing to partial effectiveness

mellow sable
#

You could probably use a counter instead of RNG

solid salmon
zealous glen
solid salmon
#

as in decimal money

zealous glen
#

The original idea started at 0.25 and increased by 0.25 per level, but in hindsight that might be too slow

#

Maybe I’ll do 0.5 for both

#

Anyways, I just made a broken Joker to test a future Enhancement effect so maybe Cryptid will like it @mellow sable

#

(unrelated)

mellow sable
#

Feel free to make a PR with it!

zealous glen
#

I mean, if you find it interesting 😅

mellow sable
#

What’s the effect?

#

Sorry if I’m like half distracted since watching Balatro on SGDQ

zealous glen
#

So, the Enhancement would make it so when a card is destroyed, it grants its Chips to cards in hand. So the Joker does that but it’s also Trading Card for every hand

mellow sable
#

That sounds awesome

zealous glen
#

I’m getting almost 10,000 Chips per hand. Not the hand score. Chips.

mellow sable
#

Wee Joker but better

#

I was testing Ankh and got like an insanely lucky Wee seed

zealous glen
#

Oh the Joker itself doesn’t gain anything

mellow sable
#

Oh the cards

wintry solar
zealous glen
#

I didn't give myself any Jokers besides the one I just made balatrojoker

#

(and I didn't give myself money either)

mellow sable
#

Sounds tough

zealous glen
#

Ante 6 Violet Vessel :< scary

stray warren
#

Who can I ping to get a github link pinned in a post?

mellow sable
#

Egg

solid salmon
edgy reef
#

Still got a lot of work to do but this is getting somewhere.

hallow forge
near ivy
#

me when i get the water:

zealous glen
#

Which one do you prefer?

near ivy
#

imo none of them look particularly good, but of them 2 is the best one

zealous glen
near ivy
#

yeah i'm not sure what to do either ¯_(ツ)_/¯

zealous glen
#

What about these two?

crisp coral
#

try smoothing out the corners

zealous glen
#

Oh vanilla blinds do use single pixels. I thought it was only 2-by-2s

zealous glen
#

Like this?

crisp coral
#

looks better

floral elk
brisk pond
zealous glen
#

Do you know how to update the Blind text mid-blind?

#

(and maybe during in the Blind select screen)

languid mirage
#

why the fuck would this patch not work

#

but this does

#

I'm actually so confused

#

side by side is identical, and I'm not overriding anything

solid salmon
#

is drawing drinks allowed?

#

like vodka

crisp coral
#

where are you putting your keybinds.toml file?

languid mirage
#

my mod folder

crisp coral
#

if it's not named lovely.toml then you'll need to put it in a folder called lovely

languid mirage
#

oh

#

didn't know

#

ty

austere charm
solid salmon
#

ok so im fine

solid salmon
#

how do I make this appear in the shop

hallow forge
#

Give the potion consumable type a shop_rate

#

What?

solid salmon
#

i gave the type a shop rate

hallow forge
#

No

#

Not inside the loc_text

solid salmon
#

oh

#

still not appearing

hallow forge
#

Well it’s random

#

You’ll have to play a bit

#

But if you want to be sure set the rate to 1000

solid salmon
#

i set it to 8

hallow forge
#

ik

solid salmon
#

ok

hushed cradle
#

can someone help me with defining a sprite for a custom spectral card please

#

i have no idea what im doing

#

im using feder api thing

#

i literally dont know anything about lua

#

but ive managed to reverse engineer this

#

but the image is a fool card

#

i have art i made for the card but im wondering how to set the image for it

solid salmon
#

im dying

#

you gotta use atlas

hushed cradle
#

right

#

what is that

#

lmao

solid salmon
#

check the bottom

hushed cradle
#

cool

#

will i need the whole segment then

solid salmon
#

the atlas is your card key

#

like luck

#

not Luck

hushed cradle
#

right

#

thank you

#

ill report back

solid salmon
#

yw

hushed cradle
#

sorry

#

im a bit confused

#

where do i actually put that bit

#

tried shoving it in

#

idk anything about lua

crisp coral
#

hi, so you're using 0.9.8 so the syntax is completely different

hushed cradle
#

oh i thought i had 1.0.0

hushed cradle
#

thank you

crisp coral
#

init is a 0.9.8 thing

hushed cradle
#

oh

#

do you know if feder api is 0.9.8 then

crisp coral
#

yes

hushed cradle
#

ah

#

damn

crisp coral
#

do you want to use 0.9.8 or 1.0.0

hushed cradle
#

probably 0.9.8

#

hopefully all my mods are compatible

crisp coral
#

0.9.8 is not compatible with 1.0.0 mods, and 1.0.0 has compat with 0.9.8 but it's not stable

hushed cradle
#

ill see if any of my mods break when i install it quickly

frosty dock
#

feder api isn't even its own thing anymore?

#

a bunch of the 0.9.8 apis come from it though

fallen tendon
#

Honestly you should prob switch to 1.0.0, its getting close to release

#

Theres already a sizable amount of 1.0.0 mods

hushed cradle
#

if i stay with 1.0.0 is there any easy way for me to add my own stuff to the game?

solemn coral
#

Yes, absolutely.

#

You'll proably need to learn a bit of Lua to do so, but Lua's an easy language to pick up, and from my experience adding new things in 1.0.0 is much easier than it was in 0.9.8.

hushed cradle
#

cool

#

are there any resources for making it easier

#

like the api thing i was trying to use

solemn coral
#

This is the current documentation for 1.0.0

#

Anything in the table of contents with a number in front of it is part of the new docs, while the entries below it are for the old 0.9.8 docs

hushed cradle
#

thank you very much

solid salmon
#

if i wanted to do something stupid like 1 in 5 chance to get a voucher

#

how could i do it?

crisp coral
#

create a card with the voucher center then redeem it

solid salmon
#

what if i wanted to make more than one?

crisp coral
#

create multiple cards with the voucher center then redeem them

brisk pond
# solid salmon

i never get why all you modders use pseudorandom when mathrandom() is there

hallow forge
#

seeds

#

they need to be consistent

brisk pond
#

want to elaborate?

hallow forge
#

if you use mathrandom() you will get different rng even with the same seed

brisk pond
#

that's not the point of random?

hallow forge
#

the whole point of seeds is so you can play the same run with the same rng

brisk pond
#

oh yeah I didn't think about that

#

the seeded runs

#

so just pseudorandom('string')?

hallow forge
#

i think so

solid salmon
#

...

hallow forge
#

btw u forgot quotes

crisp coral
# solid salmon

unfortunately the way you used create_card is far from how it's supposed to be used

solid salmon
#

gee if only i knew

crisp coral
#

read the source code

solid salmon
#

which part

crisp coral
#

think of a similar thing that would happen in the game, then look at how the game did it

#

for example, if i wanted to create a voucher then i would look at either the shop functions or the voucher tag

#

...or betmma's Housing Choice

solid salmon
#

randomly_redeem_voucher

#

but how do i make it happen twice

#

nvm

#

i got an idea

zealous glen
#

How do you set the background color for Showdown Blinds?

crisp coral
#

i'm pretty sure there's a check for boss.showdown somewhere that disabled the color

zealous glen
#

Oh that's just how the base game looks

solid salmon
#

this gonna be crazy

hushed cradle
#

no way wtf

#

this is sick

#

thank you all

hallow forge
#

oops all spectrals

hushed cradle
#

my favourite part of this game is the probabilty jokers and things

#

like lucky cards

solid salmon
#

@hallow forge help

edgy reef
#

Betmma issue

#

I think it got update to fix this but idk

solid salmon
#

bruh

#

betmma has to fix his voucher pack

#

how do i fix this

wintry solar
#

Fix what

solid salmon
#

the error

wintry solar
#

Look at the code and see what it needs

hallow forge
#
    key = 'ironic',
    atlas = 'bonus_tags',
    loc_txt = {
        name = "Ironic Tag",
        text = {
            "Create a {C:red}Common{}",
            "{C:red}Bonus Blind{}"
        }
    },
    pos = {x = 0, y = 0},
    apply = function(tag, context)
        if context.type == 'immediate' then
            local lock = tag.ID
            G.CONTROLLER.locks[lock] = true
            tag:yep('+', G.C.BLUE,function() 
                if (#G.consumeables.cards < G.consumeables.config.card_limit) then
                    local card = create_card("Bonus", G.consumeables, nil, 'Common', nil, nil, nil, 'top')
                    card:add_to_deck()
                    G.consumeables:emplace(card)
                end
                G.CONTROLLER.locks[lock] = nil
                return true
            end)
        end
    end,
    discovered = true
}```
am i doing something wrong here, my tag won't activate when collected.
solid salmon
#

meh it's not too much of a problem

frosty dock
hallow forge
#

k

#

that worked ty

#

a blind for a blind. extremely productive

outer hedge
#

Is it possible to do something like oops all sixes but always make the probability guaranteed

#

Like instead of 1 in 2 it's 2 in 2

And instead of 1 in 4 it's 4 in 4

solid salmon
#

ye

zealous glen
regal wolf
#

hey @frosty dock do u happen to know how to update the G.CHALLENGES cache thats used to generate UI for challenge tab?

#

updating G.CHALLENGES doesn't do it. It must be something that's happening on game initialization. Because my changes to G.CHALLENGES only apply to the UI on game restart.

frosty dock
#

the challenge API was an extremely straightforward addition to steamodded iirc

regal wolf
#

to get it to update dynamically?

#

during the game?

frosty dock
#

ah I haven't messed with that, let me see then

regal wolf
#

yeah

#

challenge API is easy, its just updating the UI elements dynamically which is a problem

frosty dock
#

how dynamically are we talking about?

#

while navigating within the challenge UI?

regal wolf
#

i mean, depends whats possible

#

but currently its not updating at all

#

while the game is open

#

you have to restart, for it to update

#

even though G.CHALLENGES is what is being used to get the data for the UI. and G.CHALLENGES is being updated dynamically.

frosty dock
#

if you're fully restarting the game, where is the data in G.CHALLENGES coming from?

regal wolf
#

I'm p sure it wont be possible w out a massive rewrite for the challenge data to be updated dynamically while the UI is open, but even just on the main menu it wont updat ,.

regal wolf
#

injecting into G.CHALLENGES.

frosty dock
#

pretty much nothing about G.CHALLENGES is static normally

#

this is all a bit too vague for me to tell what exactly is going on, do you have any code to show for it?

regal wolf
#

yeah, ill push my stuff to a seperate branch

frosty dock
#

also I'm getting tired, I'll have a look at this tmr

regal wolf
#

Alright, thanks.

solid salmon
#

hey how do i make my own kind of joker type?

#

like it works like jokers but isn't

hallow forge
#

look at the lovely/dump/main.lua

#

you can try and make your own class from that

solid salmon
#

ok

#

where lovely?

#

nvm found it

hushed cradle
#

im using the not just yet mod, does anyone know how i can make this button less wide so its not in the shadow of the deck?

#

ive tried changing stuff in the bottom picture

#

like adding maxw and stuff

#

but i can never make the width smaller

maiden veldt
#

how would i make it so consumeables in the shop and vouchers show up as negatives?

solemn coral
#

I've got a patch that makes Common jokers show up as Polychrome, so you should be able to tweak that patch to work with what you want

maiden veldt
#

i'm not familiar, but i think i can figure it out. i'd just need to see the code to figure it out, so if you wouldn't mind sharing, that would be great

solemn coral
#
# Top Gear - Common jokers in shop are polychrome
[[patches]]
[patches.pattern]
target = "functions/UI_definitions.lua"
pattern = '''local card = create_card(v.type, area, nil, nil, nil, nil, nil, 'sho')'''
position = "after"
payload = '''
if G.GAME.twewy_top_gear then
    if card.ability.set == 'Joker' and card.config.center.rarity == 1 then
        card:set_edition({polychrome = true})
    end
end
'''
match_indent = false
#

And here's some of the documentation for how to add lovely patches

maiden veldt
#

thanks

solemn coral
#

This patch only works on the shop itself - you're going to need to make another separate patch for modifying booster packs

maiden veldt
#

👍

languid quiver
#

how do you make new hand types? (in 1.0.0)

surreal marsh
shell tangle
#

Could anyone explain why this gives an error, which is
attempt to call method 'juice_up' (a nil value)?
It makes it to the debug message and sends checked, so my best guess is something to do with "card = self",

      local suit_check = card.ability.extra.cur_suit
      if context.other_card:is_suit(suit_check) then 
        sendDebugMessage('checked')
        return{
          message = localize{'k_again_ex'},
          repetitions = 1,
          card = self
        }
      else
        sendDebugMessage('Failed')
      end```
edgy reef
#

What magic does Thunk imbue into his debuff shader to make the X transparent

edgy reef
#

Tbf I've just edited the parts that set the color of the X and non-X so there might be some missed wizardry

shell tangle
# royal ether try `card = card`

Text didn't show up, but it didn't crash, and did retrigger, so I'll mess around a bit more. Thanks, and, is there ever a case where you'd use self over card while modding?

tepid crow
crisp coral
#

idk if that would do anything

mellow sable
#

what do I do here?

edgy reef
#

This is the most accurate mod screenshot ever made.

carmine yacht
#

what font are you using in that screenshot

solemn coral
#

I think I made the Swashbuckler happy with this run

crisp coral
#

that's way too good lmao

zealous glen
#

I think it’s balanced /serious

solemn coral
#

Honestly without Swashbuckler in the mix it does feel relatively balanced

#

Compared to other uncommon econ jokers like Rough Gem, Lightning Rook does have a greater payout, but it needs to be sold to actually cash in that money

crisp coral
#

on the other hand, that's at most $25 per hand

solemn coral
#

If you've managed to get your hand to the point where you can consistently play that, you've pretty much won already

#

I found that even with trying to pick up as many aces as I could, I only averaged $10-$15 per round.

languid mirage
#

Which affect all econ jokers on scoring, I guess

crisp coral
#

yeah i didn't want to mention retriggers

zealous glen
#

I think comparing it to other economy Jokers like Cloud Nine and whatever the Face card one was suggests it’s balanced

#

It’s more restrictive, and slower

crisp coral
#

c9 is dogshit lol

zealous glen
#

Exactly

royal ridge
#

this button is dumb, i tried for like an hour or two to try and fix it, it's just a pain messing with the ui system

#

there's a better looking alternative i tried, but it shifts the discard and play buttons and i find that worse than an ugly button

#

if you want to try it out, i believe all you need to do is to change the first n=G.UIT.R into n=G.UIT.C

river panther
#

Anybody know the best way to get started for just adding some basic jokers to the game with steammodded? I have a few ideas I want to try out, nothing crazy like an overhaul of the game or new functionality. Simply 5 ish jokers with unique effects

iron sphinx
#

i suggest looking at others mods code

regal wolf
#

Have a look at this jokerAPI example

rich idol
#

hey fellas
how does one install steamodded 1.0.0 on a Mac? i think i'm lost

rough furnace
#

oh man

#

localthunk wrote his own code to handle text input when love has it built in

edgy reef
#

I was just wondering how commands could be done through DebugPlus

rough furnace
rough furnace
fallen tendon
#

its so funny how local thunk has basically become a meme in the modding community

#

the perfect reaction to any souce code spaghetti ranting

crisp coral
edgy reef
#

ITS SO PEAK

rough furnace
willow quiver
#

Hey guys, new to balatro modding - what am I missing about showing messages during joker calc? I got this:


    calculate = function(self, card, context)
        if context.using_consumeable and (context.consumeable.ability.set == "Tarot") and not context.blueprint then
            new_chip_val = card.ability.extra.chips - card.ability.extra.chip_mod
            if (new_chip_val > 0) then
                card.ability.extra.chips = new_chip_val
                return {
                    message = "AAA",
                    colour = G.C.CHIPS
                }
            else
...

after running thru this block, i can see that my joker's chip state has changed, but I never get the message

crisp coral
#

because all messages must be a return from the localize function

willow quiver
#

ive also tried

                return {
                    message = localize {
                        type = 'variable',
                        key = 'a_chips_minus',
                        vars = {card.ability.extra.chip_mod}
                    },
                    colour = G.C.CHIPS
                }

to no avail

crisp coral
#

hm

#

add card = card

willow quiver
#

in the localize or the return?

#

(well i tried both.. no dice)

frosty dock
#

should be in the return

#

look at base game joker effects for reference

#

(minus the change that every self in vanilla calculate_joker becomes card in Steamodded)

willow quiver
#

^speaking of, it took me way too long to realize that too

#

i know there's a table explaining the diff in the wiki but might be good to call that incongruency with the OG code more explicitly? or i missed it

#

Anyway, feeling stumped bc I feel like this is sooo close to what Ice Cream calc does already. I just cant figure out what would be different

zealous glen
#

There’s no difference between a string and a string

willow quiver
#

localize just rets a string right

zealous glen
#

AFAIK yes

#

Maybe sometimes it has no return?

#

I vaguely recall it doing in-place substitution

#

But maybe it was another function

zealous glen
willow quiver
#

it exists in one place, ice cream, which i was mimicking

#

but ive tried other keys too

zealous glen
#

What about 2?

willow quiver
#

thats a new name to me, ill have to look

#

(in other news, just confirmed

    calculate = function(self, card, context)
        return {
            message = 'AAA',
            colour = G.C.CHIPS
        }

also does nothing, so im really doing smth wrong)

#

hold up im cooking

#

GOT IT. using_consumeable calcs never used ret statements in the og code to fire messages. they have to manually G.E_MANAGER:add_event into card_eval_status_text

crisp coral
frosty dock
zealous glen
#

So it’s either nil or a string

#

AFAIK

zealous glen
willow quiver
#

ill keep that in mind thanks

#

for now i sleep

languid mirage
#

is that intended

#

if the initial value 0 then it's never going to get to return statement

languid mirage
#

I might've cooked

#

wait

#

maybe not completely I just noticed something

languid mirage
#

Does anyone know what function handles drawing cards from pile to hand?

#

is it CardArea:draw_card_from(area, stay_flipped, discarded_only)

crisp coral
#

G.FUNCS.draw_from_deck_to_hand?

#

i think?

#

not at pc so can't check

languid mirage
#

seems like it also leads here

#

thanks

languid mirage
#

deck with only top 52 cards visible

#

the rest of the cards are not drawn until they're in hand

shell timber
#

is this an optimisation for big decks

#

e.g. 60 suits

languid mirage
#

Basically yeah

#

I didn't do it for specific mod, just QoL for endless runs and I guess mods that allow adding a bunch of cards in deck

sonic mortar
languid mirage
#

I'll publish once I get electricity 🫡

#

Having an outage

sonic mortar
brisk pond
#

is there a index in the Joker's card table that tells which mod it comes from?

#

i've been going with if card.children.floating_sprite.atlas.key == 'PT_Jokers' then but I think there's something easier

frosty dock
#

if you have access to self, that would be self.mod and self.mod.id == 'your_id' or replace self by card.config.center if you don't

brisk pond
#

thanks ❤️

frosty dock
#

np

brisk pond
#

your_id is just the one you specify in the Steamodded header, right?

frosty dock
#

yeah

languid mirage
#

Unless I don't know something

frosty dock
#

wdym, like I said you can get the center from any Card as card.config.center

languid mirage
#

Oh

#

Didn't know that

#

And can't read

#

Ye that makes sense

frosty dock
#

lmao dw

brisk pond
#

so basically is this?

#

and you use the one you have access to?

languid mirage
#

Probably want to check if Center exists

frosty dock
#

center always exists

#

mod does not

languid mirage
#

Ah, I see

brisk pond
frosty dock
#

yeah

brisk pond
#

pretty straightforward

frosty dock
#

use self in any mod API functions, the other variant will do otherwise

languid mirage
#

I don't think using self there makes sense

brisk pond
#

In a temp file so I don't forget it

languid mirage
#

Ah lol

frosty dock
#

though print(card.config.center.mod.id) will break on vanilla cards

brisk pond
#

yeah yeah

#

because .mod is nil

#

makes sense

brisk pond
#

so I have to check if other_joker is PT

frosty dock
#

yeah you'll want config.center then

brisk pond
#

i suppose context.other_joker is the card's value of the other jokers

#

I have a question about context.other_joker in general: does it iterate on the calculating joker itself?
Like: if I have 3 Jokers and the first one has context.other_joker inside it, will it iterate on all 3 Jokers or only on the other 2?

frosty dock
#

the way that works is that after a joker's main calculation, it's sent as other_joker to all other jokers, including itself

brisk pond
#

okok

#

Last question (both you and I know this is a lie)
What is the purpose of G.E_MANAGER:add_event()

#

I had juice_up() in my joker's context.individual and it was juicing up right after I hit "Play hand". I put this instead and everything goes fine, the timing and all

G.E_MANAGER:add_event(Event({
  func = function()
    _card:juice_up(0.5, 0.5)
    return true
  end
})) 
fallen tendon
crisp coral
#

events are like a queue, when you add an event it doesn't trigger until all events before it are finished

brisk pond
#

got it

#

so maybe this can help my mod

#

I have this function that basically acts like a return{chips, card} but can be put inside the body of the calculate function and it adds the Chips.

#

My problem is that it activates before all other jokers (including the ones at the left) and even before the normal +Chips of the cards.

royal ether
#

put update_hand_text in an event, probably

brisk pond
royal ether
#

you probably have to mess with blocking and blockable parameters

#

for the event

#

and maybe just put the entire thing in an event

#

idk

brisk pond
brisk pond
brisk pond
royal ether
#

the function is as the name implies

#

if its blocking, it blocks other events until its done

#

if its not blockable, it'll ignore blocking events

brisk pond
#

for reference, the joker is basically this

brisk pond
rough furnace
#

Try looking at the code for juice up

royal ether
#

you need to inject if you want it to happen after the playing card is scored

#

you can see how the queue is formed & operated on in state_events.lua:688

brisk pond
#

yeah basically all calculate jokers return their effects and state_events.lua puts them in a table called effects

royal ether
#

yea

brisk pond
#

and then iterate on every effect one by one

royal ether
#

you need to inject the section of code where it iterates through effects

#

im thinking you basically make a second effects list that your functions add to

#

but there might be a different solution

brisk pond
#

I think I need to inject at line 803, with a variable that is populated by the aChips() function, and then the game pulls from that variable and adds to the effects table

royal ether
#

you probably need to inject in all the different contexts

#

effects is overwritten between card areas

brisk pond
#

When context is different than individual the jokers act as intended

#

here i'll show you

royal ether
#

yea but if you inject there it'll have no effect on the video you sent earlier

brisk pond
royal ether
#

rather, it would make it worse

royal ether
#

it would do the effects at the start of scoring G.hand

brisk pond
royal ether
#

so it would go card->blue joker->card->blue joker->card->blue joker->your joker->your joker->your joker

brisk pond
royal ether
#

yes but effects is cleared after each card area

brisk pond
# brisk pond

Yeah, but I'll just need to add to the individual's effects table

royal ether
#

there are multiple context.individuals, one for each card area

#

if you put it in the spot you sent earlier, it'll be only for G.hand's effects

brisk pond
#

so inside the aChips(), I'll do if context.individual and cardarea == G.play then

royal ether
#

but what if someone wants to add chips for cards in hand?

royal ether
#

youd needa add a new parameter to aChips for which cardarea its happening in

#

and your other scoring functions

royal ether
#

oh you take context as a parameter already mb

#

didnt see that

#

yea that works

brisk pond
#

don't worry

#

i already got 4 headaches since I started working on this

#

it happens

royal ether
#

me when i took on sapets project ...

brisk pond
#

so I really need to learn how to .toml

#

in order to inject

hushed cradle
#

does anyone know how i can make using a card spawn a specific joker

#

its a modded joker so im not sure how to get it in the pool

wintry solar
#

Doesn’t your key need to be a string and have your mod prefix?

hushed cradle
#

i have no clue tbh

#

i know barely anything about modding

#

ill try that tho thank you

zealous glen
hushed cradle
#

is it modID_j_conquest?

#

as a string

#

oh i need to set a prefix

#

i think?

zealous glen
hushed cradle
#

thank you

#

it worked

#

thank you

#

if i have it as legendary rarity can a soul card spawn it?

#

ah

willow quiver
languid mirage
hushed cradle
#

i have it specified as soul cos i wanted it to be like hidden and rare

#

but didnt want it to spawn from soul cards

#

it spawns from a unique card im adding

#

i just made in_pool always return false and now the soul card wont spawn it

#

idk if theres a better way to do that

frosty dock
#

In 1.0, you can use hidden and soul_rate

hushed cradle
#

ive got this

#

rate is 1 for testing

frosty dock
#

that should do fine without in_pool

hushed cradle
#

ive done this so soul card wont spawn it

#

oh

#

i used a soul and it spawned my modded joker

#

its legendary rarity so im assuming thats why

frosty dock
#

hm that's tricky

hushed cradle
#

it works now

#

i think

#

i spawned in 6 soul cards

#

and the 6th gave me jimbo

frosty dock
#

what'd you do?

hushed cradle
#

using debug mode i gave myself 6 soul cards

#

so i spawned the 5 legendaries

frosty dock
#

I mean in code, what did you change to make it work?

hushed cradle
#

i put the in_pool thing

hushed cradle
frosty dock
#

ah I thought you'd said that didn't work

#

nvm then

hushed cradle
#

nah its all good

#

although the code looks funny

#

probably a better way to do it

#

but i suck at this

#

is there a way i can make a card show up in arcana and spectral packs?

frosty dock
#

The set of rules these follow is pretty simple. A soul card can show up when a soulable card is generated for:

  • The card type of the soul card or
  • the card type specified in soul_set
#

So, if your card is a spectral, you should put soul_set = 'Tarot'

hushed cradle
#

my cards are a custom consumable type tho

frosty dock
#

I mean soul-like cards are "thematically" spectrals

#

it's sort of a convention

hushed cradle
#

oh

#

okay

#

so is there no way to add it to multiple sets?

frosty dock
#

currently not, but that's an arbitrary restriction

#

we could have it so you can pass soul_set as a table

hushed cradle
#

that would be cool

sly forge
#

the soul_set thing is actually not very extensible, it'll likely be reworked for 1.0

#

this is your chance to give feedback!

brisk pond
#

do you think this would implement an xChips?
--EZSC are injections in the code
The expected joker's ability would be "Each scoring card gives X2 Chips, this joker gives X1.5 Chips"

#

this is a demonstration of injecting inside the context.individual and cardarea == G.play, but the code blocks would be injected in every context

cinder echo
#

could anyone help me learn how to mod balatro? I've never modded a game before so I'm new to all of it

river panther
#

Rate my art boys First 3 jokers

hallow forge
#

anyone know which file G.FUNCS.use_card is in? i can't seem to find it

wintry solar
hallow forge
#

ty