#đŸ’»ăƒ»modding-dev

1 messages · Page 521 of 1

distant junco
#

i'll try it a different (and less optimised) way to see if that helps

#

20 if checks coming up

gleaming crescent
distant junco
#

worse... undertale

manic rune
#

-# tf u mean worse

distant junco
#

have you not seen undertales code?

#

its ATROCIOUS

cursive gazelle
#

Switch case for

#

Dialogue

gilded blaze
#

do I have to explain what hooks are
because the simplest way to achieve the effect is to hook ease_ante

red flower
#

i think the way they did it is simpler

distant junco
#

oh yeah baby

red flower
#

that's only true for wild cards

distant junco
#

what

red flower
#

a card cant be a spade diamond or club at the same time

#

unless it's wild

distant junco
#

should it be or then

red flower
#

yes

distant junco
#

ok

red flower
#

but also just do not hearts

distant junco
#

you're ruining my terrible code

#

wait do i have to like undebuff them or is that just done automatically

red flower
#

that is done automatically

distant junco
#

thank god

red flower
#

well, it's done by calling debuff_card again and doing the opposite at end of round

distant junco
#

it still debuffing everything 😭

#

how come blind one works great but everything else just instantly falls apart

#

im gonna try different contexts just to see if anything changes

gilded blaze
#

exactly

#

wait

#

wrong channel balatrojoker

gleaming crescent
#

Oh, I have a simmilar joker

#

and it's a rare one, so I don't think it's balanced

buoyant thorn
agile path
#

okay chat, jokers file done, do i need anything else?

gleaming crescent
#

Or do you have it?

agile path
#

they are all empty files for now, i'm just creating the files and naming them

#

so, main.lua and jokers.lua, correct?

gleaming crescent
#

Yup

#

You can organize them however you want

cursive gazelle
#

Don’t forget to assert the files in the main file

agile path
cursive gazelle
#

Or they won’t load

gleaming crescent
agile path
cursive gazelle
#

assert(SMODS.load_file("yourfilename.lua"))()

agile path
cursive gazelle
spice wadi
agile path
#

assert(SMODS.load_file("jokers.lua"))()

like so for example?

cursive gazelle
#

Yes

buoyant thorn
spice wadi
agile path
distant junco
buoyant thorn
#

you're trying to debuff non hearts right? @distant junco

distant junco
#

oh my god

buoyant thorn
red flower
distant junco
#

yeah for the jokers

red flower
#

no

cursive gazelle
buoyant thorn
#

huh

#

ohhh

red flower
#

i said to use not hearts instead of what you were doing

distant junco
#

oh right yeah i did that

buoyant thorn
distant junco
#

same thing

red flower
cursive gazelle
agile path
cursive gazelle
#

Card.is_suit(“hearts”) will return true if the card’s suit is hearts and false if not

cursive gazelle
#

For the file path

agile path
#

got it

#

thank you

cursive gazelle
#

So yeah it’s obligatory

distant junco
red flower
#

i dont think this is a problem with your debuff_card logic

distant junco
red flower
#

you said it was end_of_round

distant junco
#

oh yeah

cursive gazelle
#

Are u trying to make the debuffed deck or something

buoyant thorn
#

so jam
is this a joker that debuffs all cards except for a single suit and it changes every round?

agile path
#

for my jokers i'd need to do j_"joker prefix"?

buoyant thorn
#

ah okay

pastel kernel
#

I don’t know how to define ObjectType đŸȘŠ

cursive gazelle
agile path
#

jokerkey?

red flower
cursive gazelle
distant junco
#

ill leave it as is for now

agile path
cursive gazelle
#

Your modprefix is ljbt

agile path
#

yes

cursive gazelle
#

j_ljbt_jokerkey

#

Jokerkey being the key of your joker that you specified in SMODS.joker

dreamy thunder
#

j is lowercase also i think

buoyant thorn
#

if this was python id be able help
if this was python
first
I'd probably make a list of all four suits
then id make the code pick from one of them at random and remove it from the list
then id check if the cards' suits are in what's left of the list
instead of making four if statements
and then the list would reset every time
not sure if this is possible in lua since
i dont know lua...

cursive gazelle
agile path
jagged zodiac
#

okay this is way too strong ;-;-;-;-;

agile path
#

either that, or it's flying right over my head

cursive gazelle
distant junco
red flower
buoyant thorn
#

ah i see

agile path
cursive gazelle
jagged zodiac
cursive gazelle
jagged zodiac
#

yeah it's just busted on ghost deck

buoyant thorn
unborn bay
#

i just use SMODS.debuff_card like a normal person

distant junco
#

thats... a thing????

unborn bay
#

yeah

#

its in the documentation i think

cursive gazelle
#

Reading the wiki explains the wiki

distant junco
#

so true

agile path
#

please bear with me😭

cursive gazelle
agile path
#

slowly, but we'll get there lol

cursive gazelle
#

j_modprefix_jokerkey is mainly used in localization file and spawning joker

jagged zodiac
#

WAIT I HAVE A FUCKING FLUSH FIVE ACES BUILD

cursive gazelle
#

But if you don’t care about translating just use loc_txt

jagged zodiac
#

THE RARE MONEY JOKER

#

yay

#

now I can see if it is too strong

buoyant thorn
cursive gazelle
#

Basically what localization file is
Is just a file that contains the text for your joker and you’ll have to make others and translate the text

gleaming crescent
cursive gazelle
#

As an advice i think the easiest thing to code is jokers so just look at vanilla remade and SMODS.joker documentation and you’ll understand how everything works

agile path
buoyant thorn
cursive gazelle
jagged zodiac
#

to feel the balance

buoyant thorn
#

English united states (of america)

#

ah yes
what im currently doing as well

jagged zodiac
#

basically, the runs I need to do to unlock gold stake on all decks, I do with my mod on
then the actual gold stake runs for Completionist+, I do without

cursive gazelle
#

I should work on my mod

gaunt thistle
cursive gazelle
#

Hello ethan

buoyant thorn
distant junco
cursive gazelle
#

Honestly i’m out of original ideas lol

agile path
#

i can give ideas

#

what's you mod about

distant junco
#

i can too i have so many

buoyant thorn
#

lets green needle

#

i mean

#

brainstorm*

agile path
#

let's blueprint

distant junco
#

lets jolly joker

spice wadi
#

lets hang chad

distant junco
agile path
#

why are we hanging chad...

distant junco
#

what did chad do

unborn bay
spice wadi
#

only appear in shop while i was testing my mod

cursive gazelle
#

?

#

No

unborn bay
#

what

buoyant thorn
#

haha sorry

cursive gazelle
#

Please don’t make those kind of jokes

agile path
#

D:

#

...oops

buoyant thorn
#

yeah im sorry

#

looks cool

agile path
#

no one saw anything

distant junco
jagged zodiac
#

but honestly, it feels balanced
it's something you expect for this level of deckfixing, it's like having a full deck of one card with rebate, or golden ticket and hanging chad

buoyant thorn
#

interesting quotation mark placement...

unborn bay
distant junco
unborn bay
#

think of it like a seed for a pseudoseed

distant junco
buoyant thorn
#

hmmm
does that work without single and double quotes being differentiated?

unborn bay
distant junco
#

oh

unborn bay
#

you still have to do the suit checks manually

distant junco
#

im so confused

buoyant thorn
#

sooo

#

SMODS.debuff_card(card, true, "other_card:is_suit:('Hearts')" ?

distant junco
#

thats what i just did

buoyant thorn
#

look at the quotes around hearts

red flower
unborn bay
#
for k, v in pairs(G.playing_cards) do
    if v:is_suit("Hearts") then
        SMODS.debuff_card(v, true, "unqiuedebuffidentifier")
    end
end
buoyant thorn
#

"**"**" ~= "**'**"

unborn bay
#

this will debuff all heart cards when called

#

permanently

agile path
#

guys, i'll head out, i'll come back later

distant junco
#

ohh ok

unborn bay
#

unless you call it again

#

and set the second parameter to false

agile path
#

gf is having trouble setting up her console

royal ridge
agile path
#

goddamn

cursive gazelle
distant junco
#

so it doesnt really matter what i put in the unqiuedebuffidentifier

red flower
#

yes

distant junco
#

got it

#

i will try that

red flower
#

in the sense that it should be unique

distant junco
#

yeah

buoyant thorn
#

so what's the upside to this joker?

distant junco
#

X3 mult

royal ridge
buoyant thorn
#

does it debuff wild cards too?
if so, thi-

royal ridge
#

i hate bloodstone 🙏

cursive gazelle
#

I like bloodstone

#

I may have gambling problems

red flower
#

i am married to bloodstone

distant junco
buoyant thorn
unborn bay
#

i also have a joker similar to this but it only debuffs when you draw it

buoyant thorn
#

i think its pretty cool

unborn bay
#

and each debuffed card gives x1.5 mult

royal ridge
#

i sure do love my score having a range of 8k and 600mil

distant junco
buoyant thorn
cursive gazelle
#

Gives no chips and doesn’t trigger jokers

#

Worse polychrome

buoyant thorn
#

polychromes cousin that we dont talk about

spice wadi
#

polycrap

red flower
#

i mean it's better polychrome in the sense that it's easier to get

cursive gazelle
#

Polychrome is unjustifiably hard to get

unborn bay
distant junco
#

like this?

unborn bay
#

also said debuffed cards can be retriggered by mime for example

buoyant thorn
unborn bay
distant junco
#

alright ill give it a shot

unborn bay
#

just remember to undebuff them later

buoyant thorn
spice wadi
cursive gazelle
#

Context.end_of_round

distant junco
buoyant thorn
#

yo jam
what are you gonna call your joker?

unborn bay
spice wadi
#

also set up your vsc workspace to include SMODS and the balatro source code dump from Lovely specifically

unborn bay
#

just use the same third parameter

distant junco
#

call it? ive done the art and everything

unborn bay
#

probably n++

#

which doesnt have lsp capabilities by default

red flower
buoyant thorn
# distant junco call it? ive done the art and everything

yooooooooo
i know a little bit about glsl shaders
ive made some in the past
including ones that completely blocked out a specific color from being displayed
imagine if the joker had a custom edition that changed depending on the current suit
I'd love to help with that!

spice wadi
distant junco
cursive gazelle
buoyant thorn
cursive gazelle
#

I don’t think they can be dynamic or can pass variables through but i’m not an expert

buoyant thorn
distant junco
buoyant thorn
#

take one down

#

pass it around

cursive gazelle
buoyant thorn
#

three different shader in a folder

distant junco
cursive gazelle
#

Mhm

distant junco
#

which it is currently in and it didnt work

wintry solar
#

shaders can have variables passed in

cursive gazelle
#

And remember go undebuff them with context.end_of_round

cursive gazelle
pastel kernel
#

Ideal Joker Sprite

wintry solar
#

you can give them anything yeah

#

otherwise they wouldnt work

cursive gazelle
cursive gazelle
distant junco
cursive gazelle
#

😭I literally answered

buoyant thorn
#

@distant junco
here's one...

distant junco
cursive gazelle
#

Or just applied it into the image

buoyant thorn
cursive gazelle
buoyant thorn
#

which is a window manager for ||arch Linux||

distant junco
#

a-a-a-a-aaa-ARCH!!!?????

cursive gazelle
#

Arch is cool

#

If you know what you’re doing

distant junco
#

take away the c and the l and a p at the start

#

pArch is oo

buoyant thorn
cursive gazelle
#

I have an unused card area , i should probably add some form of buffs and nerfs there

distant junco
#

omg its like uno flip

buoyant thorn
#

oh yeah it is

#

also
no back for this deck?

distant junco
#

how could you have a back for double sided cards

buoyant thorn
#

a three sided card is perfectly normal

cursive gazelle
#

Not in normal 3d space

#

(Balatro is a 2d game )

distant junco
#

guhh?

#

where is my balatro 4d time travel mod

cursive gazelle
#

Probably can make that

#

But it will take a lot of save loads and management

buoyant thorn
#

in which the polychrome cards...-
sure
also
can you make the deck look like its a case?
can the stack animation be disabled?

cursive gazelle
#

Case ?

buoyant thorn
#

like
a card sleeve?

#

its square shaped

#

like a box for putting cards in

cursive gazelle
#

Oh yeah i can

red flower
#

like the cardsleeves mod?

buoyant thorn
cursive gazelle
#

Idk why i thought you meant csgo cases

#

I think i’m brainwashed

buoyant thorn
#

teehee

cursive gazelle
#

I should make an api mod like partner

rotund sable
cursive gazelle
#

What distro do you use

rotund sable
#

I used arch

#

But my laptop is too old for it to work

cursive gazelle
#

I see

rotund sable
#

And my main PC has too much filled storage for dual boot

#

(I'd rather upgrade the PC and not storage)

cursive gazelle
#

Maybe in the future

rotund sable
#

Maybe

#

Hopefully

cursive gazelle
#

Imo , you need arch for coding
There’s so much in windows that draws your attention

red flower
#

what does that mean

cursive gazelle
#

The only thing i do in my arch is coding and looking at my custom widgets

red flower
#

i need to have family guy and subway surfers while i code

cursive gazelle
rotund sable
#

Ooh

cursive gazelle
#

Having work spaces that you can access with one press is a blessing

buoyant thorn
red flower
#

i dont use alt tab ever

cursive gazelle
#

How do you switch windows

buoyant thorn
#

one of my friends didn't realize alt tab was a feature and thought it was added in a recent windows update lol
they didnt even believe me when i told them

red flower
#

why would i want to i have 2 monitors

cursive gazelle
#

I have 2 monitors but i use one for spotify

buoyant thorn
cursive gazelle
rotund sable
red flower
buoyant thorn
red flower
#

but seriously i just have the browser and vscode i dont need anything else

#

if i need multiple vscode windows i just split it

cursive gazelle
#

Understandable

#

I use blender/godot/browser/file explorer

#

At the same time

#

Because I can’t make 3d models

red flower
#

i would never use blender

#

not me

cursive gazelle
#

I have to if i want unique assets

#

Sadly

red flower
#

no i just hate 3d

cursive gazelle
#

I wish i understood how 3d works

#

What’s the 3d axis thing called again

red flower
#

fowards, up and to the side

#

the 3 axis

#

"later" is the fourth

cursive gazelle
#

I think it’s “uninstall”

buoyant thorn
gleaming crescent
#

I want to make my own engine, where X is up-down axis

cursive gazelle
#

I wish this was easier

buoyant thorn
#

depth*

red flower
#

in 2d y is the up-down one usually

buoyant thorn
gleaming crescent
buoyant thorn
#

yooo shining diamond pfp

#

i love insane crystal

cursive gazelle
#

How can i draw a shader on top of the background or replace it

buoyant thorn
#

clue*

cursive gazelle
#

It’s probably drawstep but how

#

@lament agate how did you replace the background art

buoyant thorn
#

also your balatro flip mod is so cool
how does it work?
does each suit+rank combo have a predetermined suit+rank combo that it can turn into?

cursive gazelle
#

It’s a button that flips cards , i can add it to cards and jokers with just adding
Absolute=true
(Custom Global variable)

#

Currently they just give x6! Mult when flipped upside down , but i want them to do something more unique

proven belfry
lament agate
cursive gazelle
#

Can you link the code

lament agate
#

shoutout to this person btw

lament agate
#

thats like

#

the entirety of it

#

also i think you need to tweak the CRT shaders too

cursive gazelle
#

Yeah i think i figured it out

#

I’m not gonna add an image I’m changing the shader

lament agate
#

well you can look at joyousspring

cursive gazelle
#

Joyous spring changes colors not the whole shader

#

With ease_background

cursive gazelle
lament agate
lament agate
#

useful

#

since yknow

#

its changing THE shaders

#

not the colors

cursive gazelle
#

I would like to preview my shader outside the game

lament agate
#

and then port it BACK again to F#

cursive gazelle
lament agate
#

who said this is an easy job

cursive gazelle
#

I rather kill myself

lament agate
#

a blunt reason why my mod doesnt have Editions

cursive gazelle
#

I coded 2 shaders

#

One turned out to be good

#

And the other is just bad

#

I’m not used to actually coding shaders with hand and not having the ability to preview them as i go ,

unkempt thicket
#

I've made a few, for practice to get better at making them.

lament agate
#

i tried coding DVD bounce and flashlight shaders, both workn't

#

like it works but not in game

#

i gave up and start playing valorant with my e-kittens

#

cuz im sigma

#

im so sorry to say that

cursive gazelle
#

Workn’t

lament agate
#

no other words can describe it perfectly

cursive gazelle
#

Anyways
Thanks for the help

lament agate
#

goodluc

buoyant thorn
#

THIS EXISTS?????

#

IM GOING TO 1 in 6 chance to destroy card at the end of round MYSELF

#

🍌

#

hehe am bana

cursive gazelle
lament agate
willow scroll
#

i am struggling to find proper documentation for smods
how would i check if the card that is being sold is of a specific consumable type?

                return {
                    func = function()
                    card.ability.extra.heldPages = math.max(0, (card.ability.extra.heldPages) - 1)
                    return true
                end,
                    message = "Lost..."
                }
        end```
i have this but am struggling to find how to use context.card:
manic rune
#

context.card.config.center.set == "Tarot" i think?

#

i was about to say your return looks wrong but its just the indentation

#

sob

willow scroll
#

yeah mb im using joker forge for more basic stuff because i find that easier than going through smods documentation, and their code gen is a bit wack, but otherwise i love that damn site

willow scroll
manic rune
#

but its very much worth learning how to code yourself though!

willow scroll
willow scroll
#

if i knew where to find all the functions of stuff i would probably do it myself

rotund sable
#

Otherwise I took most of my knowledge from N' in this channel

spice wadi
red flower
#

hi

spice wadi
#

You can add that to your VSC workspace

spice wadi
red flower
#

im modding

lament agate
#

im

#

swagging

modern kindle
red flower
modern kindle
#

youve forced my hand

red flower
#

what the hell

modern kindle
red flower
#

what do you mean 3 new gifts

modern kindle
red flower
#

thank you dilly

#

i will make sure to play them eventually some day

modern kindle
#

you have to go to the moon

stoic void
#

What did you get

red flower
#

i do love going to the moon and women

modern kindle
stoic void
#

Nice

modern kindle
#

i dont know any of these games

#

i think 2 of them were on sale so i figured why not

#

OH MY GOD I HAVE TO GIFT N SOMETHING IVE GIFTED ALL OF MY FRIENDS

willow scroll
modern kindle
#

now, N

red flower
#

im scared

modern kindle
#

you are not allowed to decline this gift or i will just constantly rebuy it until you do

red flower
#

i can just hide things from the library dont worry

rotund sable
red flower
modern kindle
#

LMAO

#

i have bought this game

#

20 times now

#

i had to check my purchase history

rotund sable
#

How much does it even cost?

modern kindle
#

99 cents

rotund sable
#

Damn

modern kindle
#

idk why but its always customary i gift my friends this game

#

this was when it started

rotund sable
#

I once gifted toilet simulator to my friend when we were at a school trip

hallow slate
#

I once got gifted Gay World

#

And then like 5 fidget spinner games

rotund sable
modern kindle
#

i wish there was an easy way for me to see in total how much ive spent on gifts vs stuff for my own acc

#

cause ive spent alot on friends too

#

soon ill hit the 1 million mark

#

oh my god i have to gift bepis that game too

#

soon...

latent perch
#

Money Lisa

manic rune
modern kindle
manic rune
#

hi dilly

modern kindle
manic rune
#

im staying out of modding-chat for a bit

#

its negative there

modern kindle
#

i dont like being in modding chat myself

manic rune
#

-# dont even bother checking

modern kindle
#

thats why here is my general

latent perch
manic rune
#

+1 Joker Slot

latent perch
#

+1 Discord channel

manic rune
#

good job :3

latent perch
#

thanks! :D

modern kindle
#

everyones art is perfect and i would give it all a nice little smooch

manic rune
#

so true

latent perch
#

so true đŸ”„

manic rune
#

predicted you were gonna say that

#

:3

latent perch
#

đŸ’„

modern kindle
#

bepis

#

you only have one game on your wishlist

#

what am i suppose to do with that

cursive gazelle
#

Hey dilly

modern kindle
#

hi

#

im gonna be going to a retro store here pretty soon today

#

'just gotta get off my lazy rear

manic rune
#

my pc is dogshit

#

so i cant really expect to play any games i want

#

no point in wishlisting in which case :3

modern kindle
#

how am i suppose to gift my friends smh

#

N has just been suffering by being my gift mule

manic rune
#

😭

rotund sable
#

Poor N'

modern kindle
#

poor guy now has to make 8 of my mods

manic rune
#

true...

modern kindle
#

and then he has to download me a car

manic rune
red flower
#

i will pirate u a car

red flower
modern kindle
wooden nexus
#

Alright, so I'm currently working on something and just trying to make sure I have this right.

manic rune
#

Game:start_run

#

:3

#

not startrun lmao

wooden nexus
#

I meant start_run lol

#

thanks

manic rune
#

mhm, but also, you want to put self.GAME.iScore = self.GAME.iScore or 0 in the hook, G.GAME doesnt exist by the time your files load i think

fossil nebula
#

can anyone think of a fix to this

#

or is it even possible

manic rune
#

are you trying to create and open a booster pack when round ends?

fossil nebula
#

yeah

red flower
#

in what context are you doing it

fossil nebula
#
    calculate = function(self, card, context)
        if context.end_of_round and context.main_eval and context.game_over == false and context.beat_boss then
            G.E_MANAGER:add_event(Event({
    func = function()
        G.E_MANAGER:add_event(Event({
            func = function()
                local booster = Card(G.play.T.x + G.play.T.w/2 - G.CARD_W*1.27/2, G.play.T.y + G.play.T.h/2-G.CARD_H*1.27/2, G.CARD_W*1.27, G.CARD_H*1.27, G.P_CARDS.empty, G.P_CENTERS.p_gfy_booster_gfy, {bypass_discovery_center = true, bypass_discovery_ui = true})
                booster.cost = 0
                G.FUNCS.use_card({config = {ref_table = booster}})
                booster:start_materialize()
                blocking = true;
                return true
            end
        }))
        return true
    end
}))
            return {
            }
        end
    end

}
wooden nexus
#

or is that literally just it?

manic rune
#

nope, G.GAME.iScore will always be 0 when a new run is started, but its value should retain when you resume the run

wooden nexus
#

oh cool.

manic rune
#

i was about to say myst's lcorp does the same but they made it happen here specifically

red flower
wooden nexus
#

So the idea is that I'm adding a pseudo imaginary score. it'll have its own tab possibly and it'll just be [iScore Value]+i as the ui

manic rune
#

oh my god are you actually doing that 😭

#

thats sick

wooden nexus
#

Yup

#

No crazy talisman shenanigans or anything

#

Just making a new container and using it in a slightly different way than people would think

manic rune
#

thats really nice, WE all hate talisman (yes, you and me)

wooden nexus
#

I really wish there was a fix for it though, I'm gonna have to make a lock for anything that would potentially need it for super high scores unless I just say "it's naneinf"

modern kindle
manic rune
manic rune
#

out of spite i literally imported a new num library from roblox into yggdrasil just so i dont need to use talisman

modern kindle
#

youre the mf who told me to put in talisman compat

fossil nebula
red flower
wooden nexus
#

So my process of Imaginary numbers is a bit different from the actual case.

see, in actual math i^2 = -1. but with how I'm implementing it, think of the imaginary number as a container that'll hold the imaginary score. That "iScore" as i'll call it, can become real through certain card effects.

fossil nebula
wooden nexus
#

You'll be able to turn Score into iScore and iScore into Score

red flower
wooden nexus
#

I just need to make a check for if iScore <= 0 to make it 0 basically

manic rune
#

damn im killing myself in the past then, brb

modern kindle
oblique lotus
#

Any way to disable edition sounds when a card is added to deck?

fossil nebula
red flower
wooden nexus
#

oh boy... what the heck is this in astronomica...

#

I'm trying to understand how their score calculation works to try and remake it

fossil nebula
red flower
#

is it not working at all or is it displaying the cards on top of the UI

fossil nebula
#

not working at all

umbral zodiac
#

in the extra table of card eval status text, whats the key for changing the sound played

red flower
red flower
fossil nebula
# red flower can you post the code
    calculate = function(self, card, context)
        if context.starting_shop and context.beat_boss then
            G.E_MANAGER:add_event(Event({
    func = function()
        G.E_MANAGER:add_event(Event({
            func = function()
                if G.STATE.COMPLETE then
                local booster = Card(G.play.T.x + G.play.T.w/2 - G.CARD_W*1.27/2, G.play.T.y + G.play.T.h/2-G.CARD_H*1.27/2, G.CARD_W*1.27, G.CARD_H*1.27, G.P_CARDS.empty, G.P_CENTERS.p_gfy_booster_gfy, {bypass_discovery_center = true, bypass_discovery_ui = true})
                booster.cost = 0
                G.FUNCS.use_card({config = {ref_table = booster}})
                booster:start_materialize()
                return true
            end
        end
        }))
        return true
    end
}))
            return {
            }
        end
    end

}

red flower
#

you will need to store it beforehand

fossil nebula
#

ughhh

wooden nexus
fossil nebula
#

and how would i do that?

red flower
#

try it without that beforehand

red flower
rotund sable
#

Where's the original function call?

wooden nexus
#

reference call?

fossil nebula
red flower
#

inside the function

wooden nexus
#

oh right

red flower
wooden nexus
fossil nebula
red flower
#

you wrote it wrong

wooden nexus
#

I did?

red flower
#

not you

wooden nexus
#

oh ok

fossil nebula
red flower
wooden nexus
#

oh ok

red flower
fossil nebula
#

i copied it from you

red flower
#

you have a . instead of a _

wooden nexus
#

Now to figure out where Round_Score's value is and where I'm gonna put the imaginary score

fossil nebula
#

ohhhh

#

Im dumb

#

ok now it isn't crashing

#

but it's still not working

red flower
#

can i see the code again

manic rune
#

N' do you want me to take a ss of their* code so you can read better 😭

red flower
#

no i want the new code

manic rune
#

i meant like, the formatting and stuff, since im actually worried how you can read code on phone

#

sob

red flower
#

it's not that long

wooden nexus
fossil nebula
# red flower can i see the code again
    calculate = function(self, card, context)
        if context.starting_shop then
            G.E_MANAGER:add_event(Event({
    func = function()
        G.E_MANAGER:add_event(Event({
            func = function()
                if G_STATE_COMPLETE then
                local booster = Card(G.play.T.x + G.play.T.w/2 - G.CARD_W*1.27/2, G.play.T.y + G.play.T.h/2-G.CARD_H*1.27/2, G.CARD_W*1.27, G.CARD_H*1.27, G.P_CARDS.empty, G.P_CENTERS.p_gfy_booster_gfy, {bypass_discovery_center = true, bypass_discovery_ui = true})
                booster.cost = 0
                G.FUNCS.use_card({config = {ref_table = booster}})
                booster:start_materialize()
                return true
            end
        end
        }))
        return true
    end
}))
            return {
            }
        end
    end

}
red flower
#

😭

manic rune
#

you dont need to add a return{} there

red flower
#

G.STATE_COMPLETE

manic rune
#

and yeah thats just, gone

#

wait i mean

#

that should be a .

fossil nebula
#

now how can i store that the boss was beaten

red flower
#

try it again with the end of round stuff

manic rune
#

unrelated but fix your indentation and remove the return{} at the end too, its not necessary

fossil nebula
red flower
#

damn

#

well you can do

if context.end_of_round and context.main_eval then
    card.ability.extra.beat_boss = context.beat_boss 
end
if context.starting_shop and card.ability.extra.beat_boss then
     -- your code here
end
steep bronze
#

Excuse me, how do I make the multi text appear as multiplication? like {C:mult}X3{}

red flower
#

{X:mult,C:white}

#

see the text styling page on the docs

knotty orchid
#

Hey! If I've created a new area and want to emplace a card on it. Why doesn't this work? I mean, the count limit increases as it should but the card is not shown. Any ideas?

---Adds card to managers area
---@param card table|Card|true card to add to the manager area
Pokerleven.add_to_managers = function(card)
    if card.edition and card.edition.card_limit then
        Pokerleven.ina_manager_area.config.card_limit = Pokerleven.ina_manager_area.config.card_limit +
            card.edition.card_limit
    end

    Pokerleven.ina_manager_area:emplace(card)
    card:add_to_deck()
end
red flower
#

did you remove it from the previous area

knotty orchid
#

Am I missing something?

manic rune
red flower
faint yacht
knotty orchid
red flower
#

that looks fine

manic rune
#

question, anyone knows where the code for adding buttons in the run info menu is

knotty orchid
red flower
#

i dont think so, im pretty sure it's already done before that code

knotty orchid
#

Man I'm desperate

#

don't know what's going on HAHAHA

wintry solar
#

Can you show your area definition

knotty orchid
# wintry solar Can you show your area definition
local game_start_run_ref = Game.start_run
function Game:start_run(args)
    self.ina_manager_area = CardArea(
        0,
        0,
        self.CARD_W * 1.9,
        self.CARD_H * 0.95,
        {
            card_limit = 5,
            type = 'managers',
            highlight_limit = 1,
        }
    )
    Pokerleven.ina_manager_area = G.ina_manager_area

    game_start_run_ref(self, args)

    Pokerleven.ina_manager_uibox = UIBox {
        definition = Pokerleven.create_UIBox_manager_area(),
        config = {
            align = 'cmi',
            offset = { x = 2.3, y = 3.5 },
            major = self.consumeables,
            bond = 'Weak'
        } }
end

Pokerleven.create_UIBox_manager_area = function()
    return {
        n = G.UIT.ROOT,
        config = { align = 'cm', r = 0.1, colour = G.C.CLEAR, padding = 0.2 },
        nodes = {
            {
                n = G.UIT.O,
                config = {
                    object = Pokerleven.ina_manager_area,
                    draw_layer = 1
                }
            },
        }
    }
end
wintry solar
#

Change the type to joker iirc

#

Your made up type won’t have any handling of what to do

#

So it defaults to acting like the discard area iirc

knotty orchid
#

let me try

#

FINALLY

#

I'M GONNA CRY THAT WAS THE THING

wooden nexus
#

How do i keep the text from growing

fossil nebula
#

why isn't the color changing on this pack?

wintry solar
#

I believe it should be in its own function like this


ease_background_colour = function(self)
        ease_colour(G.C.DYN_UI.MAIN, G.C.SET.ortalab_loteria)
        ease_background_colour{new_colour = G.C.SET.ortalab_loteria, special_colour = G.C.BLACK, contrast = 2}
    end,
fossil nebula
#

thx

knotty orchid
wintry solar
wooden nexus
knotty orchid
wintry solar
#

You just need to add handling for your type to all the cardarea functions that check the type

raven orchid
#

Does anyone know how to create a random skip tag? was looking at the steam modded and balatro jokers and i dont think there's any documentation on it

#

There's only really information on how to create specific tags

ocean sinew
#

wym random skip tag?

raven orchid
#

thanks!

red flower
#

i dont like this code

#

feels like im doing something wrong

#

maht

buoyant thorn
#

this doesn't work
says card is a nil value...
im gonna try something else...
maybe a local variable?
wish i knew more lua!

buoyant thorn
#

yoink!

red flower
buoyant thorn
#

hmmm
i see
so my reading comprehension being cooked is the problem?

#

gotcha

#

ill try that first then

#

thanks

#

it says ability is a nil value
i guess ill print these to log and see whats up then

red flower
#

is this for a joker or something else

buoyant thorn
#

deck

red flower
#

for decks it was something different let me check

buoyant thorn
#

oh thank you

red flower
#

card.effect

#

or back.effect depending on how you named the argument

buoyant thorn
#

you know, i wouldn't mind using variables if thats what a local is

#

is there any reason not to?

red flower
#

yes, things you save to a local are not kept between function calls

buoyant thorn
#

i see

#

so that means continuing a run would...

#

gotcha

#

thanks

#

okay

#

i have no clue what im missing

#

card.ability is apparently bad so...

#

card.effect.extra.*?

#

is that right?

#

i guess ill try that

ebon shell
#

why does this not work? i want it to add a blue seal to on random after scoring but it's not doing anything

misty radish
#

How do I make these actually readable?

ebon shell
#

im guessing other_card doesn't work with context.final_scoring_step?

red flower
# buoyant thorn
calculate = function(self, back, context)
    back.effect.extra.current_ante = G.GAME.round_resets.blind_ante or G.GAME.round_resets.ante
    if back.effect.extra.current_ante ~= back.effect.extra.last_ante then
        G.jokers.config.card_limit = G.jokers.config.card_limit + (back.effect.extra.current_ante - back.effect.extra.last_ante)
        back.effect.extra.last_ante = back.effect.extra.current_ante
    end
end
ebon shell
# red flower it doesnt

any alternatives? cuz with context.individual it adds the seals the moment the cards are played and it looks weird

red flower
#

try adding one more ,true to set_seal

buoyant thorn
buoyant thorn
red flower
buoyant thorn
#

actually
everything outside calculate only happens once right?

red flower
#

depends what you mean by everything

buoyant thorn
#

i mean

#

if i do

#

local variable = 1 outside calculate

#

that only happens every time i start playing the run right?

#

(both starting a new run and loading a save)

red flower
#

that happens everytime you open the game

#

so it will not reset between runs

#

but it will reset if you close the game

buoyant thorn
#

i can work with this i think

#

so just to be clear
i only need to type in "local" the first time i use a variable right?

red flower
#

yes

buoyant thorn
#

what if i need to change the value?

#

okay got it

ebon shell
#

here's the code in case it could help

red flower
buoyant thorn
#

local last_ante = G.GAME.round_resets.blind_ante or G.GAME.round_resets.ante local current_ante = last_ante calculate = function(self, back, context) current_ante = G.GAME.round_resets.blind_ante or G.GAME.round_resets.ante if current_ante ~= last_ante then G.jokers.config.card_limit = G.jokers.config.card_limit + (current_ante - last_ante) last_ante = current_ante end

#

that should do it...

red flower
#

no lol

#

the first two lines dont make sense when the game loads

buoyant thorn
#

sigh...

red flower
#

anyway i found the issue

#
calculate = function(self, back, context)
        back.effect.config.extra.current_ante = G.GAME.round_resets.blind_ante or G.GAME.round_resets.ante
        if back.effect.config.extra.current_ante ~= back.effect.config.extra.last_ante then
            G.jokers.config.card_limit = G.jokers.config.card_limit +
                (back.effect.config.extra.current_ante - back.effect.config.extra.last_ante)
            back.effect.config.extra.last_ante = back.effect.config.extra.current_ante
        end
    end
#

decks are weird

buoyant thorn
#

hmmm

red flower
#

i tested it and it works properly

buoyant thorn
#

bless u

steep bronze
#

hey, how do i change base hand values in my mod?

faint yacht
#

G.GAME.hands[handname].s_chips & G.GAME.hands[handname].s_mult

#

Just don't forget to update the total values at G.GAME.hands[hand].chips & G.GAME.hands[hand].mult respectively.

buoyant thorn
distant junco
#

yo, does this code need to be in a specific context? cuz at the minute it uhhh isnt doing anything

ebon shell
#

somehow despite having a not context.repetition context check, the code for enhancing the card still gets retriggered (doesn't show visually but the lucky card gives X2 mult as if it were a glass card)

#

how do i make it only trigger once?

rapid stag
#

why not just do the random enhancement inside a func() in the reptition return table?
also for random enhancement you don't need to do all that, you can just do
context.other_card:set_ability(SMODS.poll_enhancement{ guaranteed = true }, nil, true) and that'll give it a random enhancement

latent perch
#

The Card of Man.

ebon shell
#

but if it's unnecessary ill change it then

rapid stag
#

yeah, the message is superfluous too
from context.repetitionyou can just do lua return { repetitions = card.ability.extra.repetitions, func = function() context.other_card:set_ability(SMODS.poll_enhancement{ guaranteed = true }, nil, true) end } and then nix the top condition. that'll make it do the random enhancement only once, but i'm not sure where it puts it in the order of events

faint yacht
#

Forgot a , after repetitions = card.ability.extra.repetitions. 📝

rapid stag
#

oop

faint yacht
#

And you may want to also local context = context for the func outside of return.

rapid stag
#

true, context does change đŸ€”
i tend to just do local cardRef = context.other_card before the return and then do whatever i need to do to that

red flower
#

you dont need to i dont think because its not in an event

faint yacht
#

¯_(ツ)_/¯

rapid stag
#

? i'm fairly certain that most things you return from a joker end up in the event queue

red flower
#

not func

rapid stag
#

ah

ocean sinew
#

yah card edits

distant junco
#

@red flower i got it to work im so smart!!!!!!!

rapid stag
#

speaking of somewhat obscure optimisations, @red flower i looked at how vanillaremade does raised fist for a thing and i'm wondering if this constant iterating for every card in hand is performant

i feel like there's a better way to do this

#

like what if you have a massive hand

red flower
#

you can probably do it in an earlier context yeah

faint yacht
#

Find card in context.initial_scoring_step, tag it, then untag in context.after.

buoyant thorn
#

wow!
i somehow fixed it!!!

agile path
#

good evening my dear friends

buoyant thorn
#

yippeee

ebon shell
rapid stag
#

probably better to untag in hand_drawn and end_of_round

agile path
#

i want to try attempting to code again, but i'm kinda scared to ask and look stupid (part 2) 😓

buoyant thorn
#

shoutout to the letter n
definitely within the top 26 letters of the alphabet

faint yacht
faint yacht
red flower
#

because the table will be the same

faint yacht
#

Probably just me being overly cautious. 😅

red flower
#

no i mean it literally does nothing

#

you would need to copy the table

faint yacht
#

Then fair enough.

red flower
#

if the original context changes the local will change too

ebon shell
#

it's giving this crash and local context = context doesn't seem to solve anything

red flower
#

try local other_card = context.other_card

#

and then use that instead of context.other_card in the func

ebon shell
#

i put this one above return too right?

red flower
#

yes

buoyant thorn
#

oooh spooky
i can use the debug mod to +1 ante
but the joker slots doesnt update for some reason
beating a boss blind causes the ante to go up by one again but little joker slot number doesn't update

but when i try to buy a card, it works!
and the number suddenly increase by 2 to match the ante number...
very spooky...

#

probably a debug mod quirk though

agile path
#

chat, so
i was looking at the code for other mods and what does the "atlas" part mean

SMODS.Atlas({
key = "conjoined_joker",
path = "j_conjoined_joker.png",
px = 71,
py = 95,
})

this is from the multiplayer mod

red flower
#

it loads the sprites

agile path
#

what i'm not understanding is where i add any of this code-

wooden nexus
#

How do i make complex score not a "nil" and instead the number + the letter i at the end

red flower
agile path
#

wait, can i make a folder and make each separate joker there

red flower
#

you can organize it however you want

#

i have 400 jokers so i have to do folders lol

agile path
#

to do comments, i do " ---"?

rapid stag
#

also, is it known that if a modded joker is copied by invisible joker, the copy intially has the wrong atlas?

red flower
agile path
#

just two, got it

frigid cargo
#

N' why do you hate "n" and "N"

red flower
frigid cargo
#

OH because youre N(prime)

crystal spade
#

i'm working on a card that applies the blueprint effect to the card to its left and the card to its right. how can i return blueprint_effect() 2x? can i also apply a message? here's what my code looks like now

if context.joker_main then
            for i = 1, #G.jokers.cards do
                if G.jokers.cards[i] == self then
                    SMODS.blueprint_effect(self, G.jokers.cards[i-1], context)
                    SMODS.blueprint_effect(self, G.jokers.cards[i+1], context)
                    return {
                        message = "Divine Touch!",
                        card = self
                    }
                end
            end
        end```
red flower
#

it's en apostrophe

faint yacht
#

the ℕ

frigid cargo
#

N' my goat

red flower
#

to add a message you would need to add a third table to merge_effects with the message

agile path
#

how do i make my message appear as code? like you guys are doing

crystal spade
#

oh awesome thank you

red flower
#

```lua
```

crystal spade
#

three backticks

#

or one for a one-liner

agile path
#

oh

#

test

?

#

oh, nice

#

thank you!

#

assert(SMODS.load_file("jokers.lua"))()

can i add multiple of these? for like, each joker i mean

#

on my main.lua i mean

cursive gazelle
fossil nebula
#

if i have my consumable slots full

#

the booster goes into my joker slots

#

and the game is stuck

cursive gazelle
#

add a check for consumable slot

red flower
#

thats funny, i have no idea why

fossil nebula
agile path
#

updated smods

#

...game crashed lmfao

#

D,:

cursive gazelle
#

is a better approach

fossil nebula
#

it spawns them in the shop and then uses them automaticlly

cursive gazelle
#

how does it spawn in your joker slot lol

#

can i see the code

fossil nebula
#

well it's just here

cursive gazelle
#

oh that's a nice art

fossil nebula
# cursive gazelle can i see the code

loc_vars = function(self, info_queue, card, booster)

end,
calculate = function(self, card, context)
    if context.end_of_round and context.main_eval then
card.ability.extra.beat_boss = context.beat_boss 

end
if context.starting_shop and card.ability.extra.beat_boss then
G.E_MANAGER:add_event(Event({
func = function()
G.E_MANAGER:add_event(Event({
func = function()
if G.STATE_COMPLETE then
local booster = Card(G.play.T.x + G.play.T.w/2 - G.CARD_W1.27/2, G.play.T.y + G.play.T.h/2-G.CARD_H1.27/2, G.CARD_W1.27, G.CARD_H1.27, G.P_CARDS.empty, G.P_CENTERS.p_gfy_booster_gfy, {bypass_discovery_center = true, bypass_discovery_ui = true})
booster.cost = 0
G.FUNCS.use_card({config = {ref_table = booster}})
booster:start_materialize()
return true
end
end
}))
return true
end
}))
return {
}
end
end

agile path
faint yacht
#
[[patches]]
[patches.pattern]
target = '=[SMODS _ "src/crash_handler.lua"]'
pattern = "Oops! The game crashed"
position = "at"
payload = "Whoops! The game crashed"
match_indent = true

...doesn't appear to be hitting - is the pattern not valid?
-# Just trying to change string of it.

red flower
fossil nebula
#

Ugh

#

now i have no consumables

#

but the pack still went to my joker slot

#

😭 what is happening

cursive gazelle
#

your joker slot of the joker area in the shop*

crystal spade
#

i'm using an older version of steammodded. when i try to change the calculate function to take self, card and context, it tells me that context is nil. is that because the version i'm using doesn't support all three arguments? i've been using self and card interchangibly, should i not be?

fossil nebula
#

the game looks like this

agile path
#

oops, name reveal

red flower
red flower
crystal spade
#

yeah i just realized that lol

#

thanks for your help

agile path
fossil nebula
#

this game is cursed

faint yacht
# red flower the pattern has to be the whole line
[[patches]]
[patches.regex]
target = '=[SMODS _ "src/crash_handler.lua"]'
pattern = "Oops! The game crashed"
position = "at"
line_prepend = '$indent'
payload = '''Whoops! The game crashed'''
times = 1

...would this be it instead then?

red flower
fossil nebula
#

ok now if i have full consumable slot it works

#

i have no idea what is causing this bug

agile path
willow scroll
#
add_to_deck = function(self, card, from_debuff)
        SMODS.Enhancement:take_ownership('mult',
            {
                config = {
                    mult = 2
                }
            }, true)
    end,

it seems this applies only to mult cards created after this triggers, how would i do it properly so it applies to all mult cards when its held?

red flower
red flower
faint yacht
red flower
red flower
# faint yacht uh.

yeah you would need to do (.*) actually and add the matches to the payload

#

i never use regex patches so im not sure about the syntax

agile path
#

also, i noticed something

#

i have two lovely folders

agile path
#

is that normal?

ocean sinew
#

how to fix memory leaks

distant junco
#

how do i change the joker sprite. i know its in the update thing but im not sure how to do it properly

ocean sinew
ebon shell
#

if I use SMODS.has_enhancement(card) it should return true if card has ANY enhancement right? I don't need to specify an enhancement, do I?

distant junco
#

yep

#

as in yeah itll return true

agile path
#

graaahhh

cursive gazelle
#

make sure to include the subfolder in the string path if you have one

unkempt thicket
#

How can i get a handlist that is in the games current language?

ebon shell
distant junco
#

oh

willow scroll
faint yacht
red flower
red flower
red flower
willow scroll
#

fair enough

ebon shell
red flower
#

no

#

if not next(SMODS.get_enhancements(card)) then

agile path
frigid cargo
#

is it possible to have 2 of the same context used in one calculation?

ripe thicket
#

why does this booster pack show error when I use it? it displays all the info normally when it isn't opened

red flower
red flower
agile path
frigid cargo
red flower
#

remove it

fossil nebula
#

how can i give a number of stone cards depending on a variable

agile path
red flower
agile path
red flower
agile path
#

i fucking

#

i just

#

opened the json

#

and "main file" is empty

#

ffs

#

lmfao

cursive gazelle
#

lol

#

why's it empty

agile path
cursive gazelle
#

in an event

fossil nebula
cursive gazelle
#

at least you can fix it now

cursive gazelle
cursive gazelle
#

and have a variable in your config be

#

config={extra={stonecards=3}},

fossil nebula
#

thx!

cursive gazelle
#

to add stone cards use create_card or add_card

#

add_card being easier

fossil nebula
#

and what is the id of a stone card?

frigid cargo
#

how do i check if card has seal?

agile path
#

i figured out the crash

faint yacht
#

card.seal

cursive gazelle
agile path
frigid cargo
#

what if i want to check if seal is a specific seal?

cursive gazelle
agile path
#

...or perhaps the code in that file is fucked lol

faint yacht
agile path
#
    key = "trans_joker",
    path = "placeholder.png",
    px = 0,
    py = 0,
})

SMODS.Joker({
    key = "trans_joker",
    atlas = 'Trans Joker',
    pos = { x = 0, y = 0 },
    rarity = 1,
    discovered = true,
    blueprint_compat = false,
    eternal_compat = true,
    cost = 4,
})

this is what's in it