#💻・modding-dev

1 messages · Page 291 of 1

modern kindle
#

I can't read

paper zealot
#

Consistently mad as hell that they waste genuinely excellent feature concepts on gag updates, never to be mentioned again

zealous glen
#

Can I code the *pr*g Joker

#

Is the story published anywhere

tall wharf
#

isn't it crazy how we got custom dimensions after the infinite update

manic rune
#

i saw a comment saying that microsoft doesnt care what they add for april fool updates

#

so maybe thats why

zealous glen
#

There’s Confused cards in my mod

tall wharf
zealous glen
#

Cute

Are you dating NL

manic rune
#

did u beat the boss in craftmine yet aiko

tall wharf
#

no

#

it's actually pretty fun

manic rune
#

ye

#

still cant believe those floating icy islands exist tho

#

🥀

stark geode
#

Cinema

zealous glen
quartz ravine
#

oh that looks great

manic rune
#

🧊

modern kindle
zealous glen
thin anchor
#

how would i create a list of jokers to randomly create

manic rune
#

sakdasldksalk i dont wnat to do thsisss

#

😭

#

im so gonna die

#

but i gotta get my mod done

thin anchor
#

the real invisible joker!

quartz ravine
#

Ok, I was struggling to find something fun to do with my hidden easter egg joker, A kuma.

My whole mod is animal themed, but I had to include my boy

zealous glen
quartz ravine
#

So I had him as a bear with a fur pattern of Akuma, lol!

manic rune
zealous glen
manic rune
#

lemme rotate my screen rq

zealous glen
#

You can copy the layer then rotate it

#

By reflecting twice

manic rune
#

ih

#

oh

#

i see

#

no it wasnt

#

where the fuck did i just put the dot at

#

😭

#

dementia

zealous glen
#

demetia

modern kindle
manic rune
#

there

zealous glen
manic rune
#

that seems accurate

thin anchor
#

what

tall wharf
#

please make art for my mod

manic rune
#

1 gazillion dollars for 1 jonkler

tall wharf
#

ok

#

send pay paler

zealous glen
manic rune
#

you cant use my own magic against me victin

#

💔

manic rune
tall wharf
manic rune
#

egg irl

tall wharf
#

r/egg_irl

zealous glen
#

the only subreddit which consists entirely of NL

tranquil panther
zealous glen
#

Oh I thought you were gonna answer the other ping

tall wharf
#

hello where can i find Cryptid mod

red flower
tranquil panther
#

Oh I could, that joker? Uh yeah sure

tall wharf
#

i meant to say lore

#

idk where that went

#

Balatro cryptic mod lore

tranquil panther
#

The lore

#

Is that

zealous glen
tranquil panther
#

M

tall wharf
#

no like

#

not the m lore

#

the lore of the mod

thin anchor
#

how would i create a list of jokers

tranquil panther
quartz ravine
#

What is needed to make a blue seal work with a custom hand? I am getting crashes when a blue card procs for me for a custom hand

zealous glen
#

@mellow sable what would be the lore of the film adaptation of Cryptid starring Jack Black

red flower
red flower
tall wharf
zealous glen
#

creeper boom

tranquil panther
#

Creeper

#

Aw man

zealous glen
#

I used to rule the world

thin anchor
manic rune
#

i just realized

zealous glen
#

Chunks would load when I gave the word

manic rune
#

the 3d model im taking reference of

#

isnt even accurate to the character's weapon

#

😭

red flower
manic rune
#

its only off by a few details, but like

red flower
#

hoyoverse washed

manic rune
#

do i go for full accuracy and kill myself afterwards

#

or

#

hm

#

eh, i value my sanity too much :3

tall wharf
#

guys I'm going to spoil Minecraft Movie

quartz ravine
#

Ok I will go away, bbl

tall wharf
#

Jack Black actually said "I am Steve"

tall wharf
zealous glen
tall wharf
zealous glen
#

can’t trust anyone smh my head

manic rune
#

i

#

am steveeee

zealous glen
#

Have you seen baby Jack Black

manic rune
#

🤨

thin anchor
#

brainrot-tro

zealous glen
rapid stag
#

my new solution - i removed the set_sprites() from my joker and just had the mod look for a function to updatestate and call it as part of onrunstart.

and new issue (also the joker sprite should not be a 2 of hearts girldmDead ):
i remember running into attempt to index local 's' (a number value) before, but that was when i was doing UI code stuff and the issue was that i forgot to double nest it, iirc? cirLost but i'm not doing any UI code stuff here. this should just be returning a table from calculate() for each discard.

i'm also getting something printing "line not found" to my lovely console and i'm not sure where it's coming from cirLost i only know that it's not the decrement counter print

tall wharf
#

wtf

#

Puyo Puyo Tetris 2S

#

Nintendo Switch™ 2にて、『ぷよぷよ™テトリス®2S』発売決定!

国民的、世界的アクションパズルゲームの「ぷよぷよ™」と「テトリス®」。
誰もが知っている二大アクションパズルの頂上決戦が、『ぷよぷよ™テトリス®2S』となってスペシャルにパワー...

▶ Play video
#

1 new mode...

#

mouse control

mellow sable
tall wharf
manic rune
#

kill me pls omfg

tall wharf
manic rune
#

m7's bow

#

😭

tall wharf
#

don't tell me you used shopee prop as reference

manic rune
#

its a 3d model

#

😭

tall wharf
#

ok good then

manic rune
#

-# but technically, its a shopee prop if you print it and sell it there

#

💔

quartz ravine
#

Nice dude! You picked up Thori'dal, the Stars' Fury

reef belfry
#

This is EXCRUCIATING

spark pumice
#

Looks amazing tho

manic rune
#

allat for ONE joker

#

im cooked

modern kindle
#

that looks so out of place

#

lmfao

zealous glen
zealous glen
zealous glen
manic rune
zealous glen
manic rune
#

aka this girl

zealous glen
#

Does she not stand under the light

tall wharf
#

K

#

is m7 trans

zealous glen
#

Yes

manic rune
#

😭

zealous glen
#

Why is her name a date though

hardy viper
#

hi guys im november 7th

tall wharf
#

the date of her thawing ig

zealous glen
tall wharf
#

idk lol

zealous glen
#

-# did you mean “hatching”

manic rune
#

nop

#

she was floating in the space completely frozen

formal parrot
manic rune
#

when astral express (a train that travels through space to help planets with their stuff) found her

#

she lost all of her memories, so they named her after the date she thawed

formal parrot
#

Are you talking about stelle ?

zealous glen
manic rune
#

she lost her memories too, but she definitely wasnt in an ice cube floating in the space

zealous glen
#

Was she in a space cube floating in the ice

manic rune
#

space cube floating in the ice??

#

😭

formal parrot
#

Idk the lore

zealous glen
formal parrot
#

Genshin’s lore is more pathetic

zealous glen
#

You changed avatars

#

I didn’t recognize you

formal parrot
#

Yeah LMAO

#

AHAHAHAHAHA

#

My bad

hushed field
#

I played about 40 hours of Genshin and I can't tell you what that game is about

zealous glen
#

I played 0 hours of Genshin and I can tell you what it is about

formal parrot
reef belfry
#

Who plays it for the story

manic rune
reef belfry
#

I play it to gamble

manic rune
#

added another one my friend made :p

#

22 jokers left

zealous glen
#

and gambling

manic rune
formal parrot
zealous glen
#

This too is yuri

formal parrot
manic rune
#

time to draw a trash bag

formal parrot
#

Reference

manic rune
#

would it be funny if i get gappie to draw a trash bag

formal parrot
#

Hot take

manic rune
#

:3

formal parrot
#

Draw genshin

crisp coral
#

actyuakly you know what

#

havging multiple literal trash should give you pulls eonce a month\

formal parrot
manic rune
#

good idea, it should also fix your keyboard once in a blue moon too ❤️

hushed field
crisp coral
#

to fix my tupoes

manic rune
#

are you having a choke myst 😭

crisp coral
#

jesus fucking christ this isnt intentional i swear

#

😭

hardy viper
#

tupoes 🔥🔥🔥

manic rune
#

sending an ambulance 💔

formal parrot
#

Toes

crisp coral
#

totally a wilsonthewolf impressionist

#

frfr

zealous glen
manic rune
#

actually

hushed field
#

they might be

manic rune
#

i will ask if gappie is interested lol

crisp coral
#

dwearh

#

death

manic rune
#

💔

zealous glen
#

my friend talking like a snake because their S key broke

#

also dysssslecis

manic rune
#

their snake key broke

#

i can see why

zealous glen
#

But the repeated Ss were mainly broken S key not the dislecsee

crisp coral
#

i suyre hopoe none of my keys break

manic rune
#

i think myst underwent lobotomy

#

maybe they should make a mod like... i dunno, lobotomy corporation...

formal parrot
#

chat

#

Is voice acting fun

manic rune
#

likely

#

im not a voice actor so i dunno

#

but i heard its pretty fun

rapid stag
#

what was the context for on joker create again?

manic rune
#

i dont think theres any

reef belfry
#

That hair is gonna be a placeholder for a really hot minute cuz i am NOT doing allat

manic rune
#

this is the closest one though

zealous glen
manic rune
#

🧎‍♂️

#

wait

#

what happened to the text though?

zealous glen
crisp coral
manic rune
#

true true

zealous glen
#

Oops sorry

manic rune
#

i still dont know how thats a placeholder when it already looks fucking perfect

#

😭

crisp coral
#

im going to fucking kill you all raghhhh

zealous glen
#

I misclicked

manic rune
#

lobotomyst

#

🪫

zealous glen
#

The M stands for Lobotomy

manic rune
#

the S stands for sane

zealous glen
#

the tand for ane

manic rune
#

rate joker

tall wharf
#

❤️

modern kindle
manic rune
manic rune
#

ur burning me alive

#

-# stream when

zealous glen
#

Boss Blind

The Cook
Fight Aiko IRL

manic rune
#

perfect

hushed field
#

I think cardsets is working fully for jokers and consumables, but I'm trying to set it up basically globally. Everything that every gets pulled from a pool is basically in G.P_CENTERS, no?

hushed field
manic rune
#

jars 😭

rapid stag
#

how do i convert a number to a string

manic rune
#

tostring()

manic rune
hushed field
#

I guess playing cards and suits would be exempt, huh

zealous glen
manic rune
#

am i cooking

red flower
#

yes

zealous glen
#

Maybe Seals or Stickers

manic rune
#

oh hey

zealous glen
hushed field
#

Seals are, I thought but I'll check, yeah

manic rune
#

dunno, thats the touhou texture pack

hushed field
#

I should see if enhancements actually get banned if they're in the banned keys, as well. Otherwise this set up might not really work

red flower
#

i need to see if my custom pooling system works with banned keys

faint plank
#

im trying to get a tag working for my booster pack, but i cant seem to get the key right

hushed field
faint plank
#

it'd be "p_prefix_booster" right?

red flower
red flower
manic rune
#

jesus CHRIST

#

I JUST FORMATTED MY FILE MAN 😭

faint plank
#

its thowing up an invalid center key error :P

#

i think

hushed field
#

I'm so ready for this mod to result in so many bug reports entirely unrelated to it, but just due to other mods spawning in stuff without checking the banned keys, haha. That is, assuming other people actually start playing with this mod, of course

faint plank
#

not sure why this wouldnt be working, code is copied from the game's tags

apply = function(self, tag, context)
        if not tag.triggered and tag.config.type == context.type then
            tag:yep('+', G.C.GREEN,function() 
                local key = 'p_kmjs_wallet'
                local card = 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[key], {bypass_discovery_center = true, bypass_discovery_ui = true})
                card.cost = 0
                card.from_tag = true
                G.FUNCS.use_card({config = {ref_table = card}})
                card:start_materialize()
                G.CONTROLLER.locks[lock] = nil
                return true
            end)
            tag.triggered = true
            return true
        end
    end,
red flower
#

oh wait i misread the code

faint plank
#

its identical to any other tag that would give a booster

red flower
#

whats the crash log

faint plank
#

how do i copy it?

red flower
#

you can ctrl-c the crash screen

faint plank
#

tried changing the key again

rapid stag
#

what context do i look for if i want a joker effect to trigger after the hand has been played and after the scord has been tallied

#

like right before the draw

#

wait hold on cirDerp

red flower
zenith quarry
#

anyone wanna try my sapphire mod pack

manic rune
#

?????????

red flower
faint plank
zenith quarry
#

can anyone vc i need help cwith a calculate function

faint plank
#

huh nope hunterkek

#

said this line broke it
G.CONTROLLER.locks[lock] = nil

red flower
#

yeah youre missing the lock variable

#

i dont think thats the other problem tho

zenith quarry
#

@manic rune can you help me with rsomething rreal quick

manic rune
#

...surely im not fucked

manic rune
#

u can post the code here and tell me if smts wrong though

zenith quarry
#

thatsa fine can you just help me here

manic rune
#

mhm

zenith quarry
#

im trying to spaw in a planot card how do i do that

red flower
#

SMODS.add_card{set= "Planet"}

zenith quarry
#

do i just put that in the context.setting_blind

faint plank
#

just noticed the line thats throwing errors isnt the key, but is this line
local card = Card(G.play.T.x + G.play.T.w/2 - G.CARD_W*1.27/2,

red flower
red flower
zenith quarry
#

i wnat it to be when eyou select the blind

red flower
#

then yes

manic rune
zenith quarry
#

alright ill try it

faint plank
zenith quarry
#

@red flower thankyou

faint plank
#

i know i need the set and key, not sure which others i need
SMODS.create_card('Booster', nil,nil,nil, nil, nil, key,nil,nil,nil,nil)

red flower
#

it takes a table

faint plank
#

ah

spring lantern
#

does Joker.update not work in the collection?

daring fern
spring lantern
#

that's what i thought

red flower
faint plank
#

somthing about a "_type" being nil

spring lantern
red flower
spring lantern
#

is dt just like an unused variable

red flower
#

yeah dt pauses in the collection iirc

spring lantern
#

fuck me

red flower
#

you need to use G.real_dt or something like that

manic rune
#

......hm

faint plank
#
apply = function(self, tag, context)
        if not tag.triggered and tag.config.type == context.type then
            if context.type == 'new_blind_choice' then 
                tag:yep('+', G.C.GREEN,function() 
                    local key = 'p_arcana_mega_'
                    SMODS.create_card(key)
                    return true
                end)
                tag.triggered = true
                return true
            end
        end
    end,
manic rune
#

i might be cooked yall

spring lantern
#

6

rain slate
#

bro I keep getting insane seeds during testing

red flower
manic rune
#

i blame phase 2 for wiping off my entire hand

#

💔

rain slate
#

baron in ante 1 💔

normal crest
#

Just getting a baron is not that useful tho

manic rune
#

true

spring lantern
#

god dammit i forgot description text doesn't update when you have the menu pulled up

manic rune
#

u still need to build your deck surrounding it

spring lantern
#

fukin annoying

manic rune
#

which can take a while

rain slate
spring lantern
faint plank
#

now the center is a nil value manimdead

red flower
# spring lantern

you could try adding a main_end UI to the description and set the text to a ref_table

normal crest
sullen fern
#

how do i give a custom consumable a classification like how planet cards do

onyx sonnet
spring lantern
sullen fern
onyx sonnet
normal crest
#

pretty sure main_end is meant to be a table you return in your loc_vars function that is a UI table

faint plank
sturdy compass
sullen fern
#

thank you

sturdy compass
#

Check the docs for more info on it

red flower
faint plank
#

uhhhhhh

daring fern
#

How could I put an info queue or similar on a card saying how many seals it has?

red flower
# faint plank uhhhhhh

that means it worked, try adding the rest of the stuff back to see if it opens correctly

faint plank
#

yeah

rain slate
#

is there something you have to do with talisman with numbers in message? It's crashing in card_eval_status_text cuz number comparison and that hasn't been patched by talisman so I assume it's something I have to handle myself

#

like do I have to do something here ```lua
message = localize {
type = 'variable',
key = 'a_xmult',
vars = { card.ability.extra.x_mult }
}

faint plank
#

huzzah! it works! now i just have to get my actual booster key

red flower
spring lantern
rain slate
red flower
rain slate
#

so I just show the new X mult whenever it does

#

but talisman : (

spring lantern
red flower
#

i mean the main_end

spring lantern
#

ohh shit okay

faint plank
#

YES! finally got it working!

#

thank you @red flower

rapid stag
#

is this a thunk moment?!? wtf is happening???????????????????????
is there a process that runs through all the boolean values in a joker's config while the hand is processing and forces them to be false? there's no reason this should be randomly being set to false immedaitely after i set it to true

spring lantern
red flower
#

you need to make a dynatext for that i think

spring lantern
#

ough

#

hows that work

#

i am clueless when it comes to ui

red flower
#

this is how the game does it

#

you would replace assembled_string for {ref_table = table, ref_value = "value"}

sullen fern
spring lantern
#

oh man this is gonna be fun

#

hold on what's part

red flower
manic rune
#

i realized

#

i forgot to put the code to actually refresh the deck when entering phase 3

#

:p

#

silly me

red flower
#

so you would replace those with the colour and the scale

spring lantern
#

ohh okay i get it now tysm

sullen fern
rich geyser
#

What do ya'll think of my totally useful joker?

spring lantern
#

erm what the scallop

red flower
#

it needs to be a G.UIT.O node

spring lantern
#

i love 1 shot

spring lantern
sullen fern
strong jacinth
#

How would i create something similar to the Index card from the ortolab mod

sullen fern
#

how do we feel about this so far

strong jacinth
sullen fern
rapid stag
sturdy compass
#

Average coding issue

rain slate
#

I thought it was because it's like the status text and that makes it show a status text but apparently not

#

so idk wtf I need to change here for talisman to work ```lua
if context.joker_main then
return { xmult = card.ability.extra.x_mult }
end

    if context.end_of_round and context.cardarea == G.jokers and not context.blueprint then
        local dollars = math.floor(G.GAME.dollars * 0.5)

        ease_dollars(-dollars)

        dollars = dollars + card.ability.extra.dollar_buffer

        card.ability.extra.x_mult = card.ability.extra.x_mult + card.ability.extra.growth * math.floor(dollars / card.ability.extra.dollar_needed)
        card.ability.extra.dollar_buffer = dollars % card.ability.extra.dollar_needed

        return {
            message = localize {
                type = 'variable',
                key = 'a_xmult',
                vars = { card.ability.extra.x_mult }
            },
            colour = G.C.XMULT
        }
    end
red flower
#

what's the crash log

rain slate
#

it crashes in common_events.lua:1094 in card_eval_status_text

#

lemme get the log real quick but I couldn't make sense of it

red flower
#

it seems to be the x_mult thing

manic rune
#

i might or might not know the cause

rain slate
#

well yes

manic rune
# rain slate

can u show me that line rq, istg it was because of an oversight in talisman in my case

rain slate
#

it's not the return in end_of_round tho because I tried removing it and it still crashes

rain slate
manic rune
#

YES

#

THAT

#

AMT IS A FUCKING TABLE

#

ok look

rain slate
#

yeah cuz it's like bignum or smtn

manic rune
#

i know this sounds stupid

#

but turn on Disable Scoring Animations

#

and it shouldnt crash

red flower
#

i love talisman

rain slate
#

is there a way for it to not crash with scoring animations on

manic rune
#

gotta ask MathIsFun to fix it on his end 💔

rain slate
#

you're correct

modern kindle
#

oh bepis did you ever open your issue regarding disable scoring anims

manic rune
#

.

#

oh fuck i didnt

#

aflsamflsam

modern kindle
#

you freaking buffoon

manic rune
#

😭

#

my bad my bad

modern kindle
#

i have officially cancelled balatro star rail

manic rune
#

NAWWWW

rain slate
manic rune
#

you would need to patch it urself

rain slate
#

well yes

#

that's what I mean

manic rune
#

change if amt > 0 or amt < 0 then to if amt > to_big(0) or amt < to_big(0) then in ur lovely patch

rain slate
#

yeah I was thinking that

#

thought maybe some string bullshit with the big nums might get in the way

manic rune
#

prob good enough

#

wait actually

#

i wonder if its already fixed in the latest ver, hol on

rain slate
#

I am on the latest version (I think)

#

I like just downloaded Talisman

manic rune
#

this one?

rain slate
#

oh nah just the release

#

ah feb 23

#

nvm then

manic rune
#

i can confirm it wasnt fixed

#

we love talisman ❤️

red flower
#

when does that crash happen

manic rune
#

dunno, lemme check when the amp comparison happens

sullen fern
manic rune
#

whenever smt uses this

rain slate
#

wait wtf

#

I've patched it but I just crashed on the same thing

manic rune
#

check ur dump file

red flower
rain slate
#

why isn't it patched

#

smh

manic rune
#

mathisfun gatekeeping talisman for his own mod 💔

rain slate
#

i guess i put the path wrong

#

it's in a folder

red flower
#

should be functions/common_events.lua

rain slate
#

yes

#

no it's actually just still happening

#

it's patched in the dump file and it still crashes there

manic rune
#

huh

hardy viper
#

can't edit dump files

#

those are generated

rain slate
#
[[patches]]
[patches.pattern]
target = "functions/common_events.lua"
pattern = '''
if amt > 0 or amt < 0 then
'''
position = "at"
payload = '''
if amt > to_big(0) or amt < to_big(0) then
'''
match_indent = true
times = 1
manic rune
#

yeah wait, maybe the problem is that it didn't read the to_big function from talisman, since balatro files are loaded first?

#

actually no

hardy viper
#

considering you just said you fixed it in the dump file im assuming you modified the dump file lol

manic rune
#

that doesnt make sense

#

since its not defined in common_events.lua, it should use to_big from talisman, i think?

red flower
#

yes

hardy viper
manic rune
#

yeah uh, talisman shenanigans :3

hardy viper
#

ideally wrap both in to_big

rain slate
#

yeah lemme try that

hardy viper
#

well the same issue

manic rune
#

whats amt i wonder

hardy viper
#

bleh

rain slate
#

but then I wonder

#

what was the table before

#

if now it's the other big number

hardy viper
manic rune
#

why is it even a table

#

💔

#

who need omeganum amt 😭

hardy viper
#

it has to be

rain slate
#

now it works

rain slate
#

everything is a table now

manic rune
#

💔

#

this is talisman, not lua!!!

hardy viper
rain slate
#

ok now that one works

#

time to check all my other jokers for talisman compat :)

#

fun

crisp coral
#

what the HELL

hardy viper
#

it's peak smh

manic rune
#

surely mathisfun didnt plan on making a card juice up with an amt of 1 gazillion

hardy viper
#

dissing my grannyline

manic rune
red flower
crisp coral
manic rune
#

o h

#

:3

#

i blame that on cg - too many amt

hardy viper
#

lol

manic rune
#

yeah it makes sense why it needs to_big then

red flower
#

in that case they were making the xmult into a table by using G.GAME.dollars

hardy viper
#

ah makes sense

red flower
#

but its weird that never comes up in cryptid almanac or something

manic rune
#

surely that wasnt already in one of their lovely patches

hardy viper
#

almanac used old smods/cryptid/talisman before dollars were bignum

#

oh wait if it's in card eval it'd just be

#

everything

#

hm

#

yeah i have no way of knowing without looking at the code idk

spring lantern
#

how do i fix the text in the badge :v

red flower
#

i will make smallnum

rain slate
spring lantern
#

ah thx

rain slate
#

there's another one if that doesn't work but it's loc file

manic rune
hardy viper
#

certified moment

rain slate
manic rune
#

i dont see the if amt < 0 part, weird

#

maybe cryptid has some black magic installed into it, idfk 💔

hardy viper
#

does C even have short floats

manic rune
#

i dont see it patching that part

hardy viper
#

i actually have no clue

crisp coral
#

uhhh no no short float actually

#

only short int

hardy viper
#

not in C standard

#

looked it up

#

luajit compiles with MSVC so let me see if msvc has it

#

it probably doesn't because msvc has nothing

rapid stag
#

how do i get the amount of hands played in the current blind

hardy viper
#

okay you could probably compile luajit with gcc or a c++ compiler or something which does have 16 bit floats

manic rune
#

G.GAME.current_round.hands_played i think

hardy viper
#

and then you can have smallnum

manic rune
#

😭

rain slate
#

what happened to my deck bro 💔

manic rune
hardy viper
#

you could do the same thing

rain slate
#

what if you
wanted to x < y
but god said
attempt to compare number with table

manic rune
#

me when attempt to compare number with table

red flower
#

i will approach thunk to remake balatro in php

rain slate
#

rustify balatro 💔

manic rune
#

i never knew glass joker was hard-coded

rain slate
#

what isn't hard coded in balatro

manic rune
#

true...

spring lantern
#

how should i go about applying a modded sticker to a card?

daring fern
#

Is there a way to make the message for the gold seal show up at context_post_trigger instead of before the card scores?

#

Without returning?

spring lantern
lucid owl
#

where would a custom consumable type's localization entry go? i'd rather not use loc_txt in the actual definition

spring lantern
#

descriptions.[consumable type key]

#

so like

lucid owl
#

oh awesome, i wasn't sure if it'd just go off of the consumable key

lucid owl
spring lantern
#

good question, for this one i used loc_txt for the name/collection/undiscovered loc soo idk

lucid owl
#

yeah that's what i had wanted to avoid, guess i'll have to trial and error

sullen fern
rapid stag
#

what was the function for making a string lowercase?

spring lantern
#

:lower() i think

#

am i stupid

#

oh my god i forgot GAME

scarlet spire
#

bringing this back up

#

anyone know what the deal with this is?

daring fern
sullen fern
rapid stag
#

actually, i should try

#

with a fresh instance

#

yeah nope, same error

rain slate
#

why does it have my mod badge on it

rapid stag
#

did you take ownership of it

rain slate
#

yeah I think it's because of that

rapid stag
#

or otherwise override the key

#

take ownership has a silent argument that prevents mod badge

sullen fern
manic rune
#

try card.ability.extra.active:lower()

#

-# it will bug out if its not a string

#

actually

#

it might be something setting a var as "string"

#

for some reason

faint yacht
#

:lower() yeah... I recall using that during modding for SRB2's Lua.

manic rune
#

whats SRB2?

modern kindle
#

star rail balatro 2

manic rune
#

😭

rich geyser
#

guys, quick question, why is my code not working??

calculate = function(self, card, context)
    if context.scored then
        local queen_count = 0
        for _, c in ipairs(context.scored or {}) do
            if c.base and c.base.rank == 12 then -- 12 is Queen
                queen_count = queen_count + 1
            end
        end
        print("Scored queens:", queen_count) -- <--- Debug line (optional)
        if queen_count > 0 then
            local mult_gain = queen_count * card.ability.extra.mult_per_queen
            return {
                card = card,
                Xmult_mod = mult_gain,
                message = 'x' .. mult_gain .. ' (Queens)',
                colour = G.C.MULT
            }
        end
    end
end

}

I think it should work, but it's not really doing anything

manic rune
#

i will forcefully claim ownership of what was once mine

manic rune
#

i never heard of it before

rapid stag
# manic rune weird

eh, i ended up just changing how i was doing this but i'll try it.

a more pressing concern i have - i'm returning a table from calculate() and the game is just straight up ignoring it.

i've tried xmult, Xmult_mod and this.
the table is being built correctly and returned. the game is just straight up not doing it. what am i doing wrong?
should i just switch out for SMODS.calculate_effect()?

rich geyser
modern kindle
#

i think theres scoring_hand isnt there

manic rune
#

watchu tryin to do

rich geyser
manic rune
#

i see

#

use joker_main instead

#
if context.joker_main then
   --run a loop through context.scoring_hand here, check how many queens were scored and return mult * (queenNum) basically 
end
rapid stag
#

cirLost ...i didn't even notice it was post_joker. i always thought i wrote joker_main there. i was about to lose my shit

rich geyser
#

let me try real quick

faint yacht
manic rune
#

😭 wha

#

thats cool

rich geyser
# rich geyser let me try real quick

nope, it ain't working yet. It prints what it should print to see if it activates, but I just tried to score two hands and it's still not working, not really sure why

manic rune
#

show me ur code

#

-# preferably a ss, since im on phone rn

rich geyser
#

k

daring fern
manic rune
#

its not context.scoref

#

its context.scoring_hand

pseudo cape
#

does anyone know how I can use take_ownership in smods to replace the background shader?

rich geyser
#

So like this?

manic rune
#

mhm

rich geyser
#

sorry for bothering btw, i'm trying my best

toxic flicker
#

how do i get the total hands played in the run?

manic rune
#

its all good, dw :p

red flower
rich geyser
#

it's still not scoring ;-;

peak obsidian
toxic flicker
rain slate
#

is there like SMODS.find_card but also any blueprints/brainstorms copying it?

red flower
#

i dont think so, i made my own for jokerdisplay

manic rune
rain slate
manic rune
#

wait

#

did void leave the server???

#

-# the blueatro dev, and the one replacing hands and discards with a timer fyi

red flower
red flower
manic rune
#

:3

#

i feel bad for them

rich geyser
rain slate
#

I think I'll just make it not blueprint compatible to avoid thinking about this

red flower
manic rune
#

oh also N', did u check out my m7 art :3
-# i think u did, but at the same time i think u didnt idfk 🥀

red flower
#

yes its cool

manic rune
#

nice

#

its my first time making a joker art so wasn't too confident it will come out acceptable :p

rich geyser
rain slate
#

or stacking

rich geyser
#

tysm

manic rune
rapid stag
rain slate
#

your context must be wwrong

red flower
#

you can

rapid stag
#

i've tried xchips, chips_mod and xchips_mod and nothing works

#

no, because xmult works just fine

rain slate
#

code?

red flower
#

i see in the video that the return worked, just not the multiplying

lucid owl
long urchin
#

where can i find the chances for each rarity to spawn?

rain slate
#

you'll find the default weights of each vanilla rarity

red flower
lucid owl
rapid stag
#

there is xmult working - and that's the relevant section of calculate()

rain slate
# lucid owl that's probably the case yeah

have a utility function I made to set the rank of a card ```lua
function Card:set_rank(new_rank)
local suit_prefix = string.sub(self.base.suit, 1, 1)..'_'
local rank_suffix = to_big(new_rank)

if rank_suffix < 10 then rank_suffix = tostring(rank_suffix)
elseif rank_suffix == 10 then rank_suffix = 'T'
elseif rank_suffix == 11 then rank_suffix = 'J'
elseif rank_suffix == 12 then rank_suffix = 'Q'
elseif rank_suffix == 13 then rank_suffix = 'K'
elseif rank_suffix == 14 then rank_suffix = 'A'
end

self:set_base(G.P_CARDS[suit_prefix..rank_suffix])

end

#

oh shit talisman stuff

#

lemme edit

long urchin
lucid owl
red flower
#

xchips does

lucid owl
rapid stag
#

ah, lowercase girldmDead thanks

long urchin
rain slate
#

👁️👄👁️

rain slate
#

go to line 814

long urchin
#

girl theres only 54 lines

rain slate
#

???

#

the fuck

long urchin
rain slate
#

...can you show the folder path?

#

I'm confused

red flower
#

thats the lsp_def

rain slate
#

bro

#

src/game_object.lua not lsp_def

long urchin
#

i went to my steammodded folder in my mods folder,

#

oh

digital niche
#

i was making a thing for making cards of a selected enhancement turn into another but im getting this crash

daring fern
long urchin
#

well my bad theres 2 files named game object and i just used the search function and that was the first i saw >:(

rain slate
#

yeah your fault bro

#

jk

long urchin
#

ah, thanks

rain slate
#

I haven't really fiddled around with enhancements yet but I feel like G.P_CENTERS is not what you should be using here

#

and it also probably needs like your mod prefix

digital niche
#

oh, lemme try!

red flower
#

they get saved in p_centers

rain slate
#

uh huh

#

ok

red flower
#

but also you dont need a center for set_ability anymore, just the key

digital niche
red flower
#

did you add the mod prefix?

digital niche
#

OH true

#

is it like ["fusion.claws"] ?

#

fusion being the prefix

red flower
#

"m_fusion_claws"

digital niche
#

oh okok!

#

its telling me to add a ( and a ) but when i add it gives me errors

red flower
#

show code

digital niche
red flower
#

othercard:set_ability("m_fusion_claws", nil, true)

digital niche
#

tyty!

digital niche
modern kindle
#

howdy ho fellas

    press_play = function(self)
        print("[DEBUG] Sticker Storm triggered.")
        local min_apply = 1
        local max_apply = 3
        local available_cards = {}

        -- Collect all cards in the player's hand
        for _, card in ipairs(G.hand.cards) do
            table.insert(available_cards, card)
        end

        -- Select 1-3 random cards
        local num_to_apply = pseudorandom("sticker_storm_effect", min_apply, max_apply)
        for i = 1, num_to_apply do
            if #available_cards == 0 then break end
            local chosen_card, chosen_card_key = pseudorandom_element(available_cards, pseudoseed("random_card_sticker"))
            table.remove(available_cards, chosen_card_key)

            -- Ensure the chosen card is valid
            if chosen_card and chosen_card.ability then
                -- Generate pseudorandom values for Perishable and Rental abilities
                local perishable_roll = pseudorandom('perishable_' .. tostring(chosen_card.uid or os.clock()))
                local rental_roll = pseudorandom('rental_' .. tostring(chosen_card.uid or os.clock()))
                local perishable_chance = 0.5 -- 1 in 2 chance
                local rental_chance = 0.5 -- 1 in 2 chance

                -- Debug: Log the rolls and chances
                print("[DEBUG] Card:", chosen_card.name or "Unnamed Card")
                print("[DEBUG] Perishable Roll:", perishable_roll, "/ Chance:", perishable_chance)
                print("[DEBUG] Rental Roll:", rental_roll, "/ Chance:", rental_chance)

                -- Apply Perishable ability
                if perishable_roll < perishable_chance then
                    chosen_card.ability.perishable = true
                    print("[DEBUG] Perishable ability applied to card:", chosen_card.name or "Unnamed Card")
                end

                -- Apply Rental ability
                if rental_roll < rental_chance then
                    chosen_card.ability.rental = true
                    print("[DEBUG] Rental ability applied to card:", chosen_card.name or "Unnamed Card")
                end

                -- Add a visual effect for the card
                G.E_MANAGER:add_event(Event({
                    func = function()
                        chosen_card:juice_up() -- Visual effect
                        return true
                    end
                }))
            else
                print("[DEBUG] Invalid card or missing ability field.")
            end
        end

        G.GAME.blind.triggered = true -- Ensure the Blind is marked as triggered
        return true
    end

im attempting to make a blind which will apply the rental and perishable stickers to a random amount of cards between 1-3 (which is succesful)

im applying to the cards properly, but im running into this error when the round ends

rapid stag
#

...why is my shop under my card area?

i also can't figure out if a specific mod is causing the problem because it fixes itself on game restart

placid star
#

anyone know how to get a joker's description to pop out with a context thingy, like this: that describes steel cards effects

zealous glen
zealous glen
red flower
#

in loc_vars

modern kindle
zealous glen
#

The issue is a big number being compared with—

#

Wait that's a nil not a number

digital niche
red flower
modern kindle
#

which, im not sure how it can be nil with both perishable and rental providing their values

digital niche
red flower
#

yes

#

and code would be useful too

zealous glen
digital niche
red flower
#

you can copy and paste it here

digital niche
modern kindle
lucid owl
#

how do i use SMODS.change_base() while still covering for face cards/aces? the id returned doesn't change the card

normal crest
#

G.hand.highlighted[i].base.value

#

And remove the tostring

#

Also should add a check in case the other card doesn't have a rank, like a stone card

lucid owl
#

alright

placid star
#

how do you check for the key of a joker with G.jokers.cards[i]?

daring fern
placid star
daring fern
placid star
#

ahhh okay tysm

inland charm
#

Is there any way to modify how an base game event is done? Like I know how to do it by modifying the source code but is there anyway to do that via steammodded?

inland charm
#

I want to modify the add_to_deck function to make it so that all playing cards added are hearts if you have a specific joker. There is no easy way to convert cards added to hearts with just joker code, so that's why I have to modify it.

last sentinel
#

What ended up being the solution to the calculate issue you were having? I've been having the same issue for the past few days.

inland charm
#

I have it working by modifying the source code. Works with DNA and crpytid too. Just don't know how / if I can modify it with a normal steammodded mod

graceful magnet
dapper sun
#

how do i get when a card or joker is destroyed?

red flower
graceful magnet
dapper sun
#

ty

#

i'd ctrl+f'd in there before but couldn't find one that worked

red flower
#

i dont think there's one for when a joker is destroyed

dapper sun
#

what about for when a card is destroyed?

inland charm
red flower
dapper sun
#

ty

red flower
dapper sun
#

wait that's for discarding, not destroying

#

according to the warning

#

and i want it to happen every time a card is destroyed

daring fern
dapper sun
#

yea

red flower
#

it says also

lucid owl
#

is there an easy way to count a played hand as another one? (played two pairs, if they're the only cards played, act as a 4oak)

dapper sun
#

wait so can i check if scoring_hand is nil?

red flower
#

im pretty sure

last sentinel
graceful magnet
dapper sun
#

and will this work for each destroyed card?

red flower
dapper sun
#

_ _

red flower
#

i was wondering because i use it to count all destoyed cards in a run and it wasnt triggering on discard

dapper sun
#

so it should work?

red flower
#

yeah

placid star
#

does anyone have any ideas what could be causing the trouble here

daring fern
red flower
placid star
#

ty guys !!!

last sentinel
graceful magnet
last sentinel
#

nah only ever function(self, card, context)

graceful magnet
#

then shrug, I got nothing

last sentinel
#

nards

red flower
last sentinel
graceful magnet
#

I don't think decks have a calculate

red flower
#

they do

graceful magnet
#

ah

red flower
#

i think its a new thing so idk exactly hwo it works

red flower
last sentinel
#

nope, but the config, name, and atlas initialize and the deck shows up in game

placid star
#

whats the context for when a hand has been played but before scoring?

last sentinel
#

context.before i think

placid star
#

ah yeah u right ty

red flower
last sentinel
#
    key = 'modulo',
    loc_txt = {
        name = 'modulo',
        text = {'Test'},
    },
    atlas = 'decks',
    pos = {x = 0, y = 0},
    config = {hands = 10, discards = 10},
    loc_vars = function(self, info_queue, card)
        return {}
    end,
    calculate = function(self, card, context)
        print('please run')
    end,
}```
red flower
#

ty

inland charm
red flower
last sentinel
red flower
last sentinel
#

appreciate you trying that that rules things out

red flower
#

whats your smods version?

last sentinel
#

1.0.0-beta-0401a

red flower
#

hmm yeah it should work then

inland charm
last sentinel
#

yeah, ill keep trying things, thanks

#

hmm okay.. i disabled all of my jokers and now it runs... i dont know why they'd be overwriting though if im using calculate = function tho

sleek siren
#

How would I be able to spawn in a tag?

inland charm
#

Does priority matter for a lovely patch?

red flower
inland charm
#

ok

#

So I can just set it to like 1 or something and be fine

faint yacht
red flower
placid star
#

how would you destroy a playing card in a played hand? this is the code i used but it doesn't do anything

red flower
#

use context.destroy_card

#

why is it to the right

daring fern
placid star
# red flower

so for destroying the first card in a played hand would the code be

cardarea = G.play
destroying_card = G.play.cards[1]``` 

or am i stupid
last sentinel
#

cardarea should also be in the if statement

red flower
placid star
red flower
#

card*

zealous glen
#

@red flower by the way, I'm gonna try using copy_card to transform a Consumeable: by briefly creating a new Consumable then removing it

red flower
#

thats consumable abuse

placid star
red flower
#

yes

#

destroying_card too

modern kindle
#

while i set the perishable sticker on the backburner, ive noticed that for some odd reason rental sticker on playing cards seems to trigger its effect twice per card instead of just once

ie, if you have 4 cards rental will take 8 sets of 3 instead of 4

any idea what could be causing this?

placid star
daring fern
red flower
rich geyser
#

He never forgets...

red flower
#

why is this reversed

formal parrot
modern kindle
# daring fern I tested this and it only happened once.

interesting, i have it happening every single time for some odd reason, below is the blind

SMODS.Blind({
    key = 'sticker_storm',
    loc_txt = {
        name = 'Sticker Storm',
        text = {
            'Randomly selects 2 cards',
            'from your hand and applies',
            '{C:attention}Rental{} ability!'
        }
    },
    pos = { x = 0, y = 40 },
    atlas = "blind",
    dollars = 5,
    mult = 2,
    boss = { min = 1, max = 10 },
    boss_colour = HEX('FFA500'), -- Orange to represent chaos

    -- Function to apply abilities to exactly 2 randomly selected cards
    press_play = function(self)
        print("[DEBUG] Sticker Storm triggered.")
        local num_to_apply = 2 -- Always select exactly 2 cards
        local available_cards = {}

        -- Collect all cards in the player's hand
        for _, card in ipairs(G.hand.cards) do
            table.insert(available_cards, card)
        end

        -- Ensure there are enough cards to apply the ability
        if #available_cards < num_to_apply then
            print("[DEBUG] Not enough cards in hand to apply Rental ability.")
            return false
        end

        -- Select exactly 2 random cards
        for i = 1, num_to_apply do
            if #available_cards == 0 then break end
            local chosen_card, chosen_card_key = pseudorandom_element(available_cards, pseudoseed("random_card_sticker"))
            table.remove(available_cards, chosen_card_key)

            -- Ensure the chosen card is valid
            if chosen_card and chosen_card.ability then
                -- Check if the card already has the Rental ability
                if chosen_card.ability.rental then
                    print("[DEBUG] Card already has Rental ability:", chosen_card.name or "Unnamed Card")
                else
                    -- Apply Rental ability
                    chosen_card.ability.rental = true
                    chosen_card.ability.rental_applied = true -- Ensure it is only applied once
                    print("[DEBUG] Rental ability applied to card:", chosen_card.name or "Unnamed Card")

                    -- Add a visual effect for the card
                    G.E_MANAGER:add_event(Event({
                        func = function()
                            chosen_card:juice_up() -- Visual effect
                            return true
                        end
                    }))
                end
            else
                print("[DEBUG] Invalid card or missing ability field.")
            end
        end

        G.GAME.blind.triggered = true -- Ensure the Blind is marked as triggered
        return true
    end
})

im not really certain why it would duplicate its effects when im not telling it to

placid star
red flower
placid star
#

WORKSPACE???

red flower
#

yes that

placid star
#

is that the tabs you have open?

red flower
#

or open the whole mods folder like i do

#

or you can also put it in the lua config but idk how

placid star
#

ahh

#

tysm thatll help alot!!

daring fern
modern kindle
daring fern
modern kindle
#

i wonder if its because i have the cardarea of g.deck enabled as an optional feature

rapid stag
#

anyone know how to get the current game state? like whether it's a blind or a shop or w/e

daring fern
modern kindle
#

interestingly im running neither
let me try disabling the g.deck feature

#

hmm, nope not that

daring fern
#

I found this.

modern kindle
#

yea, that solved it

#

thanks

inland charm
#

How would I set up an if...then to check if someone has a joker and make sure it isn't debuffed.

zealous glen
inland charm
#

Idk lol

#

I'm making a lovely patch rn that changes the add_to_deck function to convert cards added to hearts if you have the joker

dapper sun
#

how do i get the round score and the blind goal?

modern kindle
#

g.game.chips for player total, g.game.blind.chips for the blind req iirc

dapper sun
#

ty

zealous glen
inland charm
#

I've tried with just making the joker but I couldn't find a way to do it.

daring fern
#

Is there a way to have red seals on jokers retrigger editions?

zealous glen
#

Is there a way to have red seals on jokers

modern kindle
#

yes

modern kindle
#

something, myself and i think nopetoofast are doing it that come to immediate recollection

zealous glen
#

I mean that, it's a modded functionality not supported by SMODS

#

so, like, ask whoever made the mod

#

Autumn had Joker Seals too

modern kindle
#

well, not too easy to ask autumn

#

lmfao

zealous glen
#

I'm just giving an example

zealous glen
modern kindle
#

hes the one whos making it

#

lol

zealous glen
zealous glen
modern kindle
zealous glen
zealous glen
#

I reckon SMODS adds 1 more at least

rapid stag
# zealous glen it is

girldmSad i just looked through an output of print(tprint(G.GAME))) and couldn't find anything that would show this girldmDead is it not in G.GAME?

zealous glen
rapid stag
#

ohhh, so G.STATE?

zealous glen
#

The states also comprise states outside of the run

limber blaze
#

depending on what you need it for you might get 999 as the state too which is smods opened booster state

zealous glen
#

As I said, SMODS added at least 1 more

rapid stag
#

G.STATES?

spiral crown
#

does anyone have an example of adding a new type of consumeable to the game?

rapid stag
spiral crown
#

yeaaaaa was hoping someone knew of one or was developing one lol