#💻・modding-dev

1 messages · Page 423 of 1

mild olive
#

first time modding is there something wrong with this that makes the game crash,,.

sonic cedar
#

cant you just hook into create_tag

tight notch
mild olive
tight notch
#

i've hooked something before but i still don't have a good understanding of it

#

does the joker do anything?

#

also a lot of paramaters are missing

#

like atlas

#

rarity

#

cost

mild olive
#

yeah but im trying to see if the joker even appears in collection

tight notch
#

i think you should fill it out first

#

just in case

mild olive
tight notch
#

it should have a sprite

shell harness
tight notch
#

finish coding it and then see if it crashes?

#

maybe

#

take everything i say with shaker of salt

sonic cedar
tight notch
#

oh yeah

mild olive
violet gulch
mild olive
sonic cedar
#

apparently your text table isnt being closed properly

#

try rebooting

shell harness
tight notch
#

it could be loc_txt

#

you have a variable in it even though you don't have loc_vars

shell harness
#

?

sonic cedar
tight notch
#

#3# means variable number 3

#

but there's no loc_vars

shell harness
mild olive
sonic cedar
#

that's part of localization

tight notch
#

if you want it to just display X3 then it would be {X:mult,C:white}X3{}

#

although i reccomend using variables(which requires a config i believe) so the value can change

mild olive
#

still crashing with the same error

#

ok but it's definitely something with the text i think

sonic cedar
#

bumping this

tight notch
#

yeah idk

violet gulch
# mild olive

Typed it out myself and doesn't crash. Anything else in the file?

granite nymph
#

i tried using pools but it gives like 31 errors

shell harness
#

man ive been trying for so long my brain isnt working apparently

tight notch
#

first off

#

foo and bar are not pools

#

foobar is a placeholder word

#

also

#

uh

#

there's a lot wrong with that

granite nymph
tight notch
#

why is that and blueprint_compat indented

#

well you need to define foo and bar

#

in main.lua usually

granite nymph
tight notch
#

i'll show my example

#

so here is my joekr

granite nymph
#

im just trying to put all the jokers from my mod into one pool

tight notch
#

btw there is no colon for pools

#

it's always equals

#

and

#

this is my main.lua

granite nymph
tight notch
#

which defines the pool as an object type

#

that's not part of the code block

#

so if you define your pool basically like i did then put it in your joker it should work

granite nymph
#

thank you ^_^

mild olive
#

maybe its the json file idk

shell harness
#

chat my brain has completely shut off what do i do here (trying to add cards to the deck)

#

idk if im even on the right track

sonic cedar
#

what

shell harness
#

?

sonic cedar
#

what are you wantin- hi somecom

#

what are you wanting to achieve

shell harness
sonic cedar
#

that's like the broadest thing ever though

shell harness
#

ok uh

daring fern
sonic cedar
#

see that's what i wanna say but

#

what if they want an edge case

#

the 1/10 in a 9/10 situation if you will

shell harness
daring fern
sonic cedar
mild olive
#

solved it

violet gulch
mild olive
#

it was maining a different main.lua for some stupid reason idk what even happend

sonic cedar
#

why did you have 2 😭

violet gulch
#

that would do it

mild olive
sonic cedar
#

🥀

tight notch
#

🪫

violet gulch
tight notch
#

"this shit"

shell harness
#

or am i just stupid

tight notch
#

i think set is like a pool/object type

#

like if you have a pool defined you can put it in set

#

i think

#

that worked for me anyway

#

i think area is what you need

sonic cedar
tight notch
#

oh nvm

granite nymph
#

is there any way to make this check for a pool?

mild olive
#

ok got it why's the mult thing completely black now 💔

tight notch
daring fern
mild olive
# tight notch can you send the loc_txt

loc_txt = {
name = 'Starrushers',
text = {
'Gives {X:Mult,C:White}X3{} Mult',
'if hand contains a',
'{C:attention}Flush{} of {C:diamonds}Diamonds{}'
},
},

sonic cedar
mild olive
#

OH

granite nymph
sonic cedar
#

0.5 is crazy

tight notch
#

why'd you nerf it 🥀

daring fern
#

SMODS.add_card({set = "Playing Card", rank = rank, suit = suit, seal = seal, edition = edition})

mild olive
#

HELL YEAH WE GOT IT

tight notch
#

congrats expect more like this in the future

#

i've only been modding for 2 weeks and my game has crashed so many times

#

and it

#

*it's always something stupid i did

granite nymph
sonic cedar
#

bumpnado

shell harness
violet gulch
#

that should be a part of debugplus

daring fern
granite nymph
#

a mod (i forgot i think aikoyori's shenanigans) has a joker which gives mult depending on how many crash logs you have

sage crater
mild olive
sonic cedar
#

because before flipping would flip it over once

#

and then flip it up after calling it again

daring fern
sonic cedar
#

ok but it didnt do this before

#

that's why i had flip twice

#

because i needed to call flip again to flip it face up

sage crater
steep rain
steep rain
#

keeps saying there's an unexpected symbol near '=' when thjeres nothing there

steep rain
#

sorry

sonic cedar
pure salmon
#

does context.end_of_round exist for boss blinds?

sage crater
sonic cedar
#

why is your atlas the filename

sonic cedar
steep rain
sonic cedar
daring fern
violet gulch
pure salmon
sonic cedar
sage crater
sonic cedar
#

oh ok

steep rain
sage crater
# sonic cedar oh ok

do any of the other functions you use flip over the card by default?
maybe you're effectively doing flip -> flip -> do effect -> unflip -> unflip or something

humble elk
#

when returning a func from an SMODS calculate function, where can you access that function again? i cant find it on the wiki

pure salmon
#

also, you're calling card.ability.extra instead of card.config.extra

steep rain
#

I'm getting a new error now

#

"items/jokers.lua"]:20: '}' expected (to close '{' at line 8) near 'atlas'

daring fern
pure salmon
#

that also

#

will help a lot for syntax errors

steep rain
#

the what

sage crater
steep rain
#

I'm very new to this wdym Lua Extension

sonic cedar
sage crater
#

could be wrong, but that's what my code uses and I copied a lot of my code from other mods

pure salmon
#

install the lua LSP from here

daring fern
steep rain
#

ohhhhhhhh

sage crater
sonic cedar
#

it's 3 events as you can see

sage crater
granite nymph
#

does anyone know what these colors are called and if theres a hexcode converter

merry raven
#

Finally got back into modding after 3 months of neglecting my mods
How do I quick restart my game again

sage crater
sage crater
sonic cedar
steep rain
#

I'm still confused

pure salmon
#

by?

daring fern
sage crater
# sonic cedar odd

ok, probably remove the first one then lol
but hover over it and see what it says. If it says something about return type, that probably means you don't need it unless you're trying to return something specific

sonic cedar
#

end of function expected huh

#

guess ill just remove the first one

sage crater
sonic cedar
#

ok funny guy

sage crater
#

ok yeah, probably just remove the return true's then

sonic cedar
#

only the one

steep rain
pure salmon
#

while you're at it, create a .luarc.json file in your mod directory with this in it

{
    "workspace.library": [
      "C:\\Users\\[PUT YOUR USER NAME HERE]\\AppData\\Roaming\\Balatro\\Mods\\Steamodded\\lsp_def\\folder",
    ],
    "diagnostics.disable": [
        "undefined-global",
        "lowercase-global",
        "need-check-nil",
        "duplicate-set-field",
        "inject-field",
        "undefined-field"
    ],
    "runtime.version": "LuaJIT",
    "type.weakUnionCheck": true,
    "type.weakNilCheck": true
}

this will give you much better autofill, and also stops all those unhelpful warnings from appearing

sage crater
sonic cedar
#

we'll see?

daring fern
steep rain
#

New problem now:

[SMODS _ "src/game_object.lua"]:364: Failed to collect file data for Atlas rref_Jokers

sage crater
pure salmon
sonic cedar
# sonic cedar THERE

ran this in (0.5x speed) to see what happens
it flips face down, juices up, flips face up
then does it again
then stays face up

steep rain
pure salmon
#

if you didn't do them yet then that's why it's failing to find the file data

sage crater
humble elk
sage crater
#

this channel really needs to use threads

humble elk
#

yes

sonic cedar
#

bet

sturdy compass
#

I'm trying to convert my create_playing_card calls to SMODS.add_card calls I haven't a clue why this is crashing lol

sonic cedar
#

do you mind sending your code in a

daring fern
humble elk
#

i have a context.before that does a bunch of math to figure out what to do with the hand later, i want it to return a function that can look up a card to figure out what to do with it during scoring

sonic cedar
#

i cut off the line numbers gdi

sturdy compass
sonic cedar
#

ik

sturdy compass
#

I think the problem is due to the card not being created correctly but idk why with the arguments I'm passing in

#

I did some digging into SMODS.create_card and it doesn't look like I need to define a suit

urban wasp
sonic cedar
merry raven
#

How do you target a specific Joker's config values, or even target a specific Joker in general again

for _, joker in ipairs(G.jokers.cards) do
                if joker.key == "fm_ward_of_dawn" or joker.key == "fm_shadowshot" then
                    G.E_MANAGER:add_event(Event({
                        func = function()
                            joker.ability.extra.charge = (joker.ability.extra.charge or 0) + extra_charges
                            return true
                        end
                    }))
                end
            end

fm_... is my mod's prefix

daring fern
sonic cedar
merry raven
#

Oh yeahhhh gotcha

daring fern
urban wasp
sonic cedar
#

or i guess yeah not here

sturdy compass
daring fern
#

I tried using it, it didn't crash but it seemed to be ignoring the rank and suit I was giving it?

humble elk
#

returning func from context.before calculate

merry raven
#

Is it joker.ability.extra.xxxxxx or joker.config.extra.xxxxxxx to access a Joker's custom config values

sonic cedar
urban wasp
#

wdym

sonic cedar
#

like

sonic cedar
# urban wasp wdym

{ key = blabla, set = 'Edition', config = if needed? i know perkeo does {extra = 1}}

urban wasp
#

i mean like this is the full code

SMODS.Tag {
    key = "four-dimensional_tag",
    atlas = "crp_tags",
    pos = { x = 3, y = 3 },
    name = "Four-Dimensional Tag",
    config = { type = "store_joker_modify", edition = "crp_four-dimensional" },
    min_ante = 8,
    loc_vars = function(self, info_queue)
        info_queue[#info_queue + 1] = G.P_CENTERS["e_crp_four-dimensional"]
        return { vars = {} }
    end,
    apply = function(self, tag, context)
        if context.type == "store_joker_modify" then
            local _applied = nil
            if Cryptid.forced_edition() then
                tag:nope()
            end
            if not context.card.edition and not context.card.temp_edition and context.card.ability.set == "Joker" then
                local lock = tag.ID
                G.CONTROLLER.locks[lock] = true
                context.card.temp_edition = true
                tag:yep("+", G.C.DARK_EDITION, function()
                    context.card:set_edition({
                        ["crp_four-dimensional"] = true
                    }, true)
                    context.card.ability.couponed = true
                    context.card:set_cost()
                    context.card.temp_edition = nil
                    G.CONTROLLER.locks[lock] = nil
                    return true
                end)
                _applied = true
                tag.triggered = true
            end
        end
    end,
    crp_credits = {
        idea = { "Glitchkat10" },
        art = { "Glitchkat10" },
        code = { "Glitchkat10" }
    }
}
#

er

#

wait do you mean the edition

sonic cedar
#

yes

urban wasp
#

uhhh

sonic cedar
#

which is why it says

#

edition

#

im talking about your infoqueue

urban wasp
#

here

#
SMODS.Edition {
    key = "overloaded",
    weight = 0.03,
    shader = "overloaded",
    sound = {
        sound = "crp_e_overloaded",
        per = 1,
        vol = 0.5,
    },
    in_shop = true,
    extra_cost = 0,
    get_weight = function(self)
        return G.GAME.edition_rate * self.weight
    end,
    config = { eee_chips = 1.03, eee_mult = 1.03, trigger = nil },
    loc_vars = function(self, info_queue)
        return { vars = { lenient_bignum(self.config.eee_chips), lenient_bignum(self.config.eee_mult) } }
    end,
    calculate = function(self, card, context)
        if
            (
                context.edition -- for when on jokers
                and context.cardarea == G.jokers -- checks if should trigger
                and card.config.trigger -- fixes double trigger
            ) or (
                context.main_scoring -- for when on playing cards
                and context.cardarea == G.play
            )
        then
            return { eee_chips = lenient_bignum(self.config.eee_chips), eee_mult = lenient_bignum(self.config.eee_mult) }
        end
        if context.joker_main then
            card.config.trigger = true -- context.edition triggers twice, this makes it only trigger once (only for jokers)
        end
        if context.after then
            card.config.trigger = nil
        end
    end,
    crp_credits = {
        idea = { "Glitchkat10" },
        art = { "Glitchkat10" },
        code = { "Glitchkat10" },
    },
}
#

wAIT

#

wrong edition 😭

sonic cedar
#

it is

urban wasp
#
SMODS.Edition {
    disable_base_shader = true,
    disable_shadow = true,
    key = "fourdimensional",
    weight = 0.2,
    shader = "fourdimensional",
    in_shop = true,
    extra_cost = 5,
    sound = {
        sound = "crp_e_fourdimensional",
        per = 1,
        vol = 0.5,
    },
    get_weight = function(self)
        return G.GAME.edition_rate * self.weight
    end,
    config = { retrigger_chance = 4, retriggers = 24 },
    loc_vars = function(self, info_queue, center)
        local chance = center and center.edition and center.edition.retrigger_chance or lenient_bignum(self.config.retrigger_chance)
        local retriggers = center and center.edition and center.edition.retriggers or lenient_bignum(self.config.retriggers)

        return { vars = { G.GAME.probabilities.normal, chance, retriggers } }
    end,
    calculate = function(self, card, context)
        if
            context.other_card == card
            and (
                (context.repetition and context.cardarea == G.play)
                or (context.retrigger_joker_check and not context.retrigger_joker)
            )
        then
            local should_retrigger = pseudorandom("crp_fourdimensional") <= G.GAME.probabilities.normal / lenient_bignum(self.config.retrigger_chance)
            return {
                message = localize("k_again_ex"),
                repetitions = should_retrigger and lenient_bignum(self.config.retriggers) or 0,
                card = card,
            }
        end
    end,
    crp_credits = {
        idea = { "Glitchkat10" },
        art = { "Glitchkat10" },
        code = { "Glitchkat10" },
    },
}
#

ahhhhh

#

oops

#

js realized

sonic cedar
#

uh huh

#

maybe go and change the infoqueue now

urban wasp
#

okay now i'm really confused

#
SMODS.Tag {
    key = "four-dimensional_tag",
    atlas = "crp_tags",
    pos = { x = 3, y = 3 },
    name = "Four-Dimensional Tag",
    config = { type = "store_joker_modify", edition = "crp_four-dimensional" },
    min_ante = 8,
    loc_vars = function(self, info_queue)
        info_queue[#info_queue + 1] = G.P_CENTERS["e_crp_four-dimensional"]
        return { vars = {} }
    end,
    apply = function(self, tag, context)
        if context.type == "store_joker_modify" then
            local _applied = nil
            if Cryptid.forced_edition() then
                tag:nope()
            end
            if not context.card.edition and not context.card.temp_edition and context.card.ability.set == "Joker" then
                local lock = tag.ID
                G.CONTROLLER.locks[lock] = true
                context.card.temp_edition = true
                tag:yep("+", G.C.DARK_EDITION, function()
                    context.card:set_edition({
                        ["crp_four-dimensional"] = true
                    }, true)
                    context.card.ability.couponed = true
                    context.card:set_cost()
                    context.card.temp_edition = nil
                    G.CONTROLLER.locks[lock] = nil
                    return true
                end)
                _applied = true
                tag.triggered = true
            end
        end
    end,
    crp_credits = {
        idea = { "Glitchkat10" },
        art = { "Glitchkat10" },
        code = { "Glitchkat10" }
    }
}
#
SMODS.Edition {
    disable_base_shader = true,
    disable_shadow = true,
    key = "four-dimensional",
    weight = 0.2,
    shader = "fourdimensional",
    in_shop = true,
    extra_cost = 5,
    sound = {
        sound = "crp_e_fourdimensional",
        per = 1,
        vol = 0.5,
    },
    get_weight = function(self)
        return G.GAME.edition_rate * self.weight
    end,
    config = { retrigger_chance = 4, retriggers = 24 },
    loc_vars = function(self, info_queue, center)
        local chance = center and center.edition and center.edition.retrigger_chance or lenient_bignum(self.config.retrigger_chance)
        local retriggers = center and center.edition and center.edition.retriggers or lenient_bignum(self.config.retriggers)

        return { vars = { G.GAME.probabilities.normal, chance, retriggers } }
    end,
    calculate = function(self, card, context)
        if
            context.other_card == card
            and (
                (context.repetition and context.cardarea == G.play)
                or (context.retrigger_joker_check and not context.retrigger_joker)
            )
        then
            local should_retrigger = pseudorandom("crp_fourdimensional") <= G.GAME.probabilities.normal / lenient_bignum(self.config.retrigger_chance)
            return {
                message = localize("k_again_ex"),
                repetitions = should_retrigger and lenient_bignum(self.config.retriggers) or 0,
                card = card,
            }
        end
    end,
    crp_credits = {
        idea = { "Glitchkat10" },
        art = { "Glitchkat10" },
        code = { "Glitchkat10" },
    },
}
daring fern
#

Remove #

sonic cedar
granite nymph
#

thank you

urban wasp
#

it's four-dimensional in both codeblocks

sonic cedar
#

ignore the image

wild escarp
#

How would I make this only copied cards that aren't negative and make the copied card negative?

if context.using_consumeable and context.consumeable and context.consumeable.ability.set == 'Spectral' then
    local copied = copy_card(context.consumeable)
    copied:add_to_deck()
    G.consumeables:emplace(copied)
end
urban wasp
sage crater
#

@daring fern "latter" generally means "the second"

urban wasp
sonic cedar
daring fern
#

What you said was false

#

It's card.ability

urban wasp
#

i'm not really sure what you mean by centers

sage crater
sage crater
#

oh

urban wasp
sage crater
#

wait how did I do that lol
I even looked at my code and still said the wrong thing

sonic cedar
merry raven
#
for _, joker in ipairs(G.jokers.cards) do
                if joker.config.center.key == "fm_ward_of_dawn" or joker.config.center.key == "fm_shadowshot" then
                    print("Ward of Dawn or Shadowshot found")
                    G.E_MANAGER:add_event(Event({
                        func = function()
                            joker.config.extra.charge = (joker.config.extra.charge or 0) + extra_charges
                            return true
                        end
                    }))
                end
            end

In my snippet of code above, is it the right way to check for specific modded Jokers? For some reason it still didn't reach the print message

urban wasp
#

i thought i changed my edition's key to match the infoqueue

sonic cedar
#

youre still using the infoqueue that uses centers

urban wasp
#

is that not the case??

sonic cedar
#

you didnt change the infoqueue

urban wasp
sonic cedar
#

but the key wasnt

#

the

urban wasp
#

i don't want to change the infoqueue from four-dimensional to fourdimensional, i want it to stay as four-dimensional. so, i changed the edition key to four-dimensional

#

am i stupid because a ton of this is just making me more and more confused

sonic cedar
#

instead of this

sonic cedar
#

the key wasnt the issue

urban wasp
#

i didn't even know that was a thing

sonic cedar
#

it's your formatting of the infoqueue

urban wasp
#

weirdd i've never seen that before

sonic cedar
#

why did you ask me "wdym" and then just mentally skip what i meant

urban wasp
#

so like this?

loc_vars = function(self, info_queue)
    info_queue[#info_queue + 1] = { key = four-dimensional, set = 'Edition'}
    return { vars = {} }
end,
wild escarp
#

How would I check if a consumeable is negative? context.consumeable.edition.negative gives me a crash telling me that edition is a nil value.

sonic cedar
#

i know you can do it like that for jokers

urban wasp
#

😭

sonic cedar
#

NOOO IT WAS FOR THE INFOQUEUE 😭

wild escarp
sonic cedar
#

hrmm

urban wasp
#

oh does it need to be a string

#

oops

urban wasp
#

anyway i think i'm done

#

...nope

#

it wants to index config

#

ohhh

#

right

sonic cedar
#

you realize

#

good

urban wasp
#

i mean, you told me it was optional 😭

#

okay i think it should work now

sonic cedar
#

i meant the value not the param itself

#

like {}

urban wasp
#

eh?

loc_vars = function(self, info_queue)
    info_queue[#info_queue + 1] = { key = "four-dimensional", set = "Edition", config = {retrigger_chance = 4, retriggers = 24 } }
    return { vars = {} }
end,
sonic cedar
#

it's an edition remember

daring fern
sonic cedar
#

it needs the class tag

granite nymph
#

this joker is only spposed to aply to jokers in the "yip" pool but its working with all of them

daring fern
sonic cedar
#

didnt we just do this

granite nymph
#

yeah but i didnt type the code right

sonic cedar
#

oh lmao

daring fern
granite nymph
daring fern
# granite nymph

G.P_CENTER_POOLS["yip"][context.other_joker.config.center.key]

granite nymph
#

i have no idea how that s got there

#

my bad

#

nnope still broken

#

"attempted to index field "other_joker" a nil value"

daring fern
granite nymph
#

ohhhhh

#

im dumb sorry

#

it doesnt work :(

#

i have this udner very joker i want it to apply to

hasty mist
#

is it possible to modify a joker's rarity on the fly?

#

actually, could i just use G.P_CENTERS?

daring fern
daring fern
granite nymph
#

i put it in the main.lua and not jokers.lua

hasty mist
#

hm, how would i go about targeting a random joker with G.P_CENTERS

#

like, a random joker in the collection

#

not a random joker owned

daring fern
granite nymph
hasty mist
daring fern
hasty mist
#

alright, so this is probably not how i'm supposed to do it, right?

#

hm i can see many issues with this

#

this is complicated

daring fern
hasty mist
#

Many aspects of this are things ive never used before, so forgive my incompetence

desert ore
#

I notice in vanilla remade, all things that use context.before, then use context.main_eval, I've made jokers without, and it works perfectly. what's the purpose?

daring fern
#

Also the game would break with a modded rarity.

hasty mist
#

i just want to get this working for now

#

i also just realized i have no easy way of testing if it actually works once i DO get it working

granite nymph
#

does anyone know why the joker isn't working?

hasty mist
#

does something like this look alright?

daring fern
hasty mist
#

huh

#

should i switch them around then

#

current = pseudorandom element?

lament agate
#

how do you add custom tooltips to a joker

daring fern
lament agate
#

i want to credit someone

#

like other mods with lile artist tooltip

daring fern
#

And put the thing you want at key in set in your localization.

lament agate
#

it doesn't output what i want

humble elk
#

ok wierd crash now

game.lua:2763: bad argument #1 to 'push' (boolean, number, string, love type, or table expected)
Stack Traceback
===============
(1) Lua upvalue 'orig' at file 'main.lua:612'
        Local variables:
         msg = string: "game.lua:2763: bad argument #1 to 'push' (boolean, number, string, love type, or table expected)"
         (*temporary) = Lua function '?' (defined at line 31 of chunk [SMODS _ "src/logging.lua"])
         (*temporary) = string: "Oops! The game crashed\
"
(2) Lua local 'handler' at file 'debugplus/console.lua:576' (from lovely module debugplus.console)
        Local variables:
         msg = string: "game.lua:2763: bad argument #1 to 'push' (boolean, number, string, love type, or table expected)"
(3) LÖVE function at file 'boot.lua:352' (best guess)
        Local variables:
         errhand = Lua function '(LÖVE Function)' (defined at line 575 of chunk [lovely debugplus.console "debugplus/console.lua"])
         handler = Lua function '(LÖVE Function)' (defined at line 575 of chunk [lovely debugplus.console "debugplus/console.lua"])
(4) method C function 'push'
(5) Lua upvalue 'gameUpdateRef' at file 'game.lua:2763'
        Local variables:
         self = table: 0x0753d120  {F_GUIDE:false, F_CRASH_REPORTS:false, F_QUIT_BUTTON:true, HUD_tags:table: 0x081386d8, F_ENGLISH_ONLY:false, viewed_stake:1, HUD:table: 0x080c31f8 (more...)}
         dt = number: 0.0069605
(6) Lua upvalue 'update_ref' at Steamodded file 'src/ui.lua:84'
        Local variables:
         self = table: 0x0753d120  {F_GUIDE:false, F_CRASH_REPORTS:false, F_QUIT_BUTTON:true, HUD_tags:table: 0x081386d8, F_ENGLISH_ONLY:false, viewed_stake:1, HUD:table: 0x080c31f8 (more...)}
         dt = number: 0.0069605
(7) Lua method 'update' at file 'main.lua:1470'
        Local variables:
         self = table: 0x0753d120  {F_GUIDE:false, F_CRASH_REPORTS:false, F_QUIT_BUTTON:true, HUD_tags:table: 0x081386d8, F_ENGLISH_ONLY:false, viewed_stake:1, HUD:table: 0x080c31f8 (more...)}
         dt = number: 0.0069605
(8) Lua field 'update' at file 'main.lua:999'
        Local variables:
         dt = number: 0.0069605
(9) Lua function '?' at file 'main.lua:938' (best guess)
(10) global C function 'xpcall'
(11) LÖVE function at file 'boot.lua:377' (best guess)
        Local variables:
         func = Lua function '?' (defined at line 909 of chunk main.lua)
         inerror = boolean: true
         deferErrhand = Lua function '(LÖVE Function)' (defined at line 348 of chunk [love "boot.lua"])
         earlyinit = Lua function '(LÖVE Function)' (defined at line 355 of chunk [love "boot.lua"])```

the stack trace doesnt touch my code. this crash happens about 1-2 seconds after the "cash out" button appears and this started happening when i manually added a function to the card.ability.extra table during the calculate function. (notably my desired functionality works now) any idea what it means?
hasty mist
#

alright, did some organization and switched around the = statement, is there anything wrong with this?

daring fern
sonic cedar
granite nymph
daring fern
#

You set an atlas and a pos.

hasty mist
# daring fern Yes, remove `G.P_CENTERS[]` on all of them.

i'm lost, i'm trying to check for the rarity specifically on a random joker, unless i'm mistaken, the code i have here is setting card.ability.extra.current to the key of a random joker, and the if statements are checking for the rarity of the joker specified in card.ability.extra.current and subtracting the rarity by one, is that not correct?

keen totem
#

whats your atlas definition

granite nymph
#

its at least not crashing but its not triggering on the cards'

#

im not sure if its an issue with the joker or the pool

keen totem
#

ok

#

then how isnt it just crashing?

#

is it using the base game enhancements file?

#

why?

daring fern
keen totem
daring fern
keen totem
#

then why would it have a modprefix

daring fern
keen totem
#

yea that file literally doesnt exist

#

not even in base game

north lodge
#

The button on the bottom updates the value which the cycle_option at the top adjusts (through its function). When I click the button, in the background the value updates, but not the cycle_option page. How can I change this through a function that is not the function associated with the cycle_option?
(Notably if I refresh the menu which this ui exists in, it does change the page, but that's because on creation the current_option is linked to the value which it sets with its function)

keen totem
#

so its not even using a base game file

#

your game should be crashing right now

#

but somehow isnt

#

weird

#

base game's file is Enhancers.png

#

not Enhancements

#

but out of curiousity

#

why aren't you just using an Atlas?

#

yea no

#

you need to use an atlas

#
SMODS.Atlas{
  key = "pick a name",
  path = "fileName.png",
  px = 71
  py = 95
}
#

key is what you put as atlas in your enhancement

chrome widget
#

Acrobat should be a common tbh

keen totem
#

so with this atlas, you would put atlas = "pick a name"

daring fern
granite nymph
#

what should i be using?

daring fern
chrome widget
#

Justifying commons is hard sometimes lmao

keen totem
#

add atlas = "water" in your enhancement

#

otherwise its just using no atlas

daring fern
#

Also it is SMODS.Enhancement

keen totem
#

atlas, not Atlas

#

what does your mod folder look like?

#

also do you have a localization file or what?

#

cause your enhancement wont have a name OR description

hasty mist
#

okay so apparently hotswapping rarities IS possible

keen totem
#

what does your Enhancements.png look like?

#

ok

#

could you send me your mod in DMs so i can just see everything to do with your mod rq

#

you can remove any jokers or wtv

#

but atp i really dont get it

hasty mist
sonic cedar
hasty mist
#

LMAO

sonic cedar
#

is it gonna apply to ignoramus or was this just testing purposes

hasty mist
#

i just KNOW this fucking code is gonna get messy as hell when its done

hasty mist
sonic cedar
#

thought so

vale glen
hasty mist
daring fern
vale glen
#

Ah okay

sonic cedar
#

wrong reply

hasty mist
daring fern
# hasty mist how?

You would have to remove it from the previous rarity pool and insert it into the new one I think.

hasty mist
#

oh god

#

that sounds complicated

#

again though, how would i do that?

daring fern
hasty mist
#

oh that sounds easy enough

#

for oldpool and newpool, are those the same number/name as the rarities?

#

like 4 for legendary or 'cry_exotic' for exotic?

daring fern
hasty mist
#

or is there more

daring fern
granite nymph
#

this joker once again doesnt work

#

for some reason

hasty mist
daring fern
hasty mist
#

okay what

#

i don't quite understand all the wording here

hybrid shadow
granite nymph
hybrid shadow
daring fern
daring fern
hasty mist
hasty mist
# daring fern Yes.

awesome, can i do the same thing for the adding to the other pool as well? (for i, v in ipairs(G.P_JOKER_RARITY_POOLS[rarity]) do if v == center then table.insert(G.P_JOKER_RARITY_POOLS[rarity], i) break end end)

daring fern
daring fern
#

Actually no, it would be G.P_JOKER_RARITY_POOLS[rarity][key] = center

#

Also center needs to be the center of the joker.

hasty mist
#

alright, i think i'm getting closer

hasty mist
daring fern
hasty mist
#

alrighty

#

so now it looks alright?

daring fern
hasty mist
#

alright, thank you so much for your patience

#

I know i can be a tad dumb when it comes to modding

#

sometimes

granite nymph
#

can someone help me with a tarot card real quick

#

im gonna go to bed after this one but i know im not gonna let myself sleep until then

hasty mist
#

now, time for the pseudoseed stuff

daring fern
hybrid shadow
granite nymph
#

its a tarot if that wasnt clear

hasty mist
#

If i do card.ability.extra.current = pseudorandom_element(G.P_CENTER_POOLS.Joker, pseudoseed("seed")), that'll set card.ability.extra.current to the key of a random joker in the collection, right?

hybrid shadow
daring fern
granite nymph
daring fern
granite nymph
#

the issue is that joker code and consumable code are different

daring fern
daring fern
# hasty mist bump

No, you would want to do card.ability.extra.current = pseudorandom_element(G.P_CENTER_POOLS.Joker, pseudoseed("seed")).key

hasty mist
#

alright, cool

daring fern
hasty mist
#

and how would i make the key specified in card.ability.extra.current be wrapped in quotation marks? ('')

granite nymph
#
SMODS.Consumable {
    key = 'fool',
   atlas = 'reverse',
    set = 'reversetarot',    pos = { x = 0, y = 0 },
   loc_vars = function(self, info_queue, card)
   end,
    use = function(self, card, area, copier)
        G.E_MANAGER:add_event(Event({
            trigger = 'after',
            delay = 0.4,
    func = function()
        local copied_card = copy_card(pseudorandom_element(G.consumeables.cards, pseudoseed('vremade_perkeo')))
        copied_card:add_to_deck()
        G.consumeables:emplace(copied_card)
        return true
    end
}))
        delay(0.6)
    end,
    can_use = function(self, card)
        return 1 < #G.consumeables.cards
    end
}```
daring fern
hasty mist
#

oh it would? awesome

#

tytyty

daring fern
# granite nymph

It seems that it was overlooked in VanillaRemade that pseudorandom_element returns 2 values.

granite nymph
#

what shall i do then?

daring fern
# granite nymph what shall i do then?
G.E_MANAGER:add_event(Event({
    func = function()
        local copied_card = copy_card(pseudorandom_element(G.consumeables.cards, pseudoseed('vremade_perkeo')), nil)
        copied_card:set_edition("e_negative", true)
        copied_card:add_to_deck()
        G.consumeables:emplace(copied_card)
        return true
    end
}))
``` Perhaps?
granite nymph
#

it duplicates the card but it doesnt make it negative

daring fern
granite nymph
#

wait nevermind

#

i was playing on the holographic deck

#

anyways YAY IT WORKS!

hasty mist
#

hm, what broke here?

manic rune
#

do you not have lua extension??

daring fern
granite nymph
#

i personally use the tencent one

manic rune
#

most use the sumneko one (including me)

granite nymph
#

2 cards done today thanks to yall

hasty mist
#

okay it just turned an exotic into a common instead of a legendary

sonic cedar
#

Common Iterum Fear

hasty mist
#

this is the code that is supposed to make it a legenary

#

oh wait

#

i think it's somehow running recursively

#

how the fuck did that happen

manic rune
#

whats the whole code

sturdy compass
hasty mist
frigid cargo
#
    config = { extra = {xmult = 1, min = 5, max = 20, tempxmult = 0, shapecount = 0}},

    loc_vars = function(self, info_queue, center)
        info_queue[#info_queue+1] = {key = 'batrocity_craig', set = 'Other', vars = {center.ability.extra.xmult, ((center.ability.extra.min + center.ability.extra.shapecount)/10), center.ability.extra.max, center.ability.extra.tempxmult, center.ability.extra.shapecount}}
        return { vars = {center.ability.extra.xmult, ((center.ability.extra.min + center.ability.extra.shapecount)/10), center.ability.extra.max, center.ability.extra.tempxmult, center.ability.extra.shapecount}  }
    end,

    calculate = function(self, card, context)
    for i = 1, #G.jokers.cards do
        if G.jokers.cards[i].config.center.pools and G.jokers.cards[i].config.center.pools.Shape then
            card.ability.extra.shapecount = card.ability.extra.shapecount + 1
        end
    end
    if context.setting_blind then
            card.ability.extra.tempxmult = (pseudorandom("Craig", (card.ability.extra.min + card.ability.extra.shapecount), card.ability.extra.max)/10)
            card.ability.extra.xmult = card.ability.extra.tempxmult
    elseif context.joker_main then 
        return {
            xmult = card.ability.extra.xmult
        }
    end
end,
}

for some reason the xmult just continues growing which is not what I want,
how this code works is per shape joker, min mult is added by 1 but it just keeps growing and i dont know why

manic rune
#

i

#

use elseif instead of new if statements

hasty mist
#

alright

manic rune
#

of course that will become common 😭

manic rune
#

i wouldnt advise doing this

frigid cargo
hasty mist
#

ok its still running recursively

#

i think

#

NEVERMIND

#

im stupid

manic rune
#
    config = { extra = {xmult = 1, min = 5, max = 20, tempxmult = 0, shapecount = 0}},

    loc_vars = function(self, info_queue, center)
        local shape_count = 0
        if G.jokers and G.jokers.cards then
          for i = 1, #G.jokers.cards do
        if G.jokers.cards[i].config.center.pools and G.jokers.cards[i].config.center.pools.Shape then
            shape_count = shape_count + 1
        end
    end
        end
      
        info_queue[#info_queue+1] = {key = 'batrocity_craig', set = 'Other', vars = {center.ability.extra.xmult, ((center.ability.extra.min + shape_count)/10), center.ability.extra.max, center.ability.extra.tempxmult, shape_count}}
        return { vars = {center.ability.extra.xmult, ((center.ability.extra.min + shape_count)/10), center.ability.extra.max, center.ability.extra.tempxmult, shape_count}  }
    end,

    calculate = function(self, card, context)
    if context.setting_blind then
      local shape_count = 0
      for i = 1, #G.jokers.cards do
        if G.jokers.cards[i].config.center.pools and G.jokers.cards[i].config.center.pools.Shape then
            shape_count = shape_count + 1
        end
            card.ability.extra.tempxmult = (pseudorandom("Craig", (card.ability.extra.min + shape_count), card.ability.extra.max)/10)
            card.ability.extra.xmult = card.ability.extra.tempxmult
    elseif context.joker_main then 
        return {
            xmult = card.ability.extra.xmult
        }
    end
end,
}
#

you should do smt like this instead

#

-# i typed on discord so the indentation is fked, fix it on your end thanks :3

sonic cedar
manic rune
#

oh, also

#

change center in loc_vars to card

zenith hedge
#

where do i find my crash logs

frigid cargo
hasty mist
#

uh oh

#

it does not reset when starting a new run

manic rune
#

wat

zenith hedge
#

new to balatro modding

manic rune
#

like, the rarity goes back to exotic after reentering the run?

#

can_use is set up wrong

zenith hedge
hasty mist
manic rune
#

change center in loc_vars to card
-# not that it affects anything

zenith hedge
#

it says "tried to compare to nil"

manic rune
#

you are changing the pool itself

granite nymph
zenith hedge
#

who

hasty mist
#

is there any way to reset it when you start a new game?

manic rune
#

yeahhpiehh

manic rune
hasty mist
#

i kinda have to, it's apart of the joker's effect

manic rune
#

id suggest comparing your code to stuff in here, most of it is set up wrong

manic rune
hasty mist
#

decreases the rarity of a random joker in the collection by 1 per reroll

manic rune
#

with that out of the way

#

this doesnt exist (jokers.ability.extra.jokers)

#

so you are comparing with nil here

#

stuff in config extra will be in your jokers.ability.extra, basically, but im assuming you wanted to refer to jokers.ability.extra.cards here
-# god jokers in place of card is so cursed

frigid cargo
#

how do i check if a modded card is part of a pool?
like i wanna give 1.35 per specific joker of this certain pool, which code is that?

daring fern
frigid cargo
#

ok thanks

manic rune
# north lodge Bump

:3 i cant tell if my reading comprehension is just horribly fked up or this is very confusing to understand

north lodge
#

Probably the latter, I am very tired

manic rune
#

yeah i understand

#

itd be easier if you can provide a clearer explanation of your problem though :p

north lodge
#

I am trying to change the page that the option_cycle is on via another ui element (the button below it)

#

But I cannot figure out how to access the value which controls which page it is on

frigid cargo
daring fern
frigid cargo
zenith hedge
#

how do i fix this

#

the code

hybrid shadow
#

would it be possible to have a joker whose functionality is handled entirely by other cards? (related question, what would the parameter be for checking if the player doesnt have the joker)

zenith hedge
#

im new to modding so idk

hybrid shadow
zenith hedge
#

oh

manic rune
#

download lua extension!!!!

north lodge
# manic rune can you show me your create_option_cycle code rq
local t = create_option_cycle({
        id = 'ante_cycle_page',
        label = "Ante",
        w = 4,
        options = antes,
        no_pips = true,
        opt_callback = "change_search_ante",
        func = 'change_search_func',
        colour = G.C.PURPLE,
        current_option = Showman.config.SEEK.search_ante or 1
    })
manic rune
#

one sec

zenith hedge
north lodge
#

The func was an attempt to solve this, it isn't helping though sdaly.

manic rune
#

there

zenith hedge
manic rune
#

just an idea 🤔

north lodge
#

It doesn't change anything, no.

#

Not visually, immediately

hybrid shadow
north lodge
#

If I back out of the menu and go back in though, it does update to that.

frigid cargo
manic rune
#

i see

manic rune
#

yeah so i guess it doesnt update until manually made to do so, so you have two approaches here:
- make the code reopen the ui
- have func check its current_option, if its changed then call e:recalculate(), probably

hybrid shadow
north lodge
sonic cedar
#

based asf tag bepis

manic rune
#
local t = create_option_cycle({
        id = 'ante_cycle_page',
        label = "Ante",
        w = 4,
        options = antes,
        no_pips = true,
        opt_callback = "change_search_ante",
        func = 'check_co_change',
        colour = G.C.PURPLE,
        current_option = Showman.config.SEEK.search_ante or 1
        check = Showman.config.SEEK.search_ante or 1
    })
...
G.FUNC.check_co_change = function(e)
   if e.check ~= Showman.config.SEEK.search_ante then
      print("work please??")
      e.current_option = Showman.config.SEEK.search_ante
      e.check = Showman.config.SEEK.search_ante
      e:recalculate()
   end
end
#

probably smt like this?

manic rune
frigid cargo
daring fern
zenith hedge
#

where do i put my textures for my seals

north lodge
manic rune
#

oh wait

#

i changed it, try again

frigid cargo
north lodge
#

Mmm, still no.

north lodge
#

If it matters this is an options ui element, not something within the main game screen.

manic rune
#

odd

#

does it at least print something inside the if statement?

north lodge
#

No

manic rune
#

huh

frigid cargo
# daring fern Code?
    config = { extra = {xmult = 1.35} },
    loc_vars = function(self, info_queue, card)
        return { vars = { card.ability.extra.xmult } }
    end,
    calculate = function(self, card, context)
        if context.other_joker then
            if G.P_CENTER_POOLS['Shape'] then 
                return {
                xmult = card.ability.extra.xmult
            }
            end
        end
    end,
}
manic rune
#

changed again again, try againagain :3

daring fern
frigid cargo
#

ah ok thanks

north lodge
manic rune
#

ack

#

what the hell

#

it doesnt even print??

north lodge
#
G.FUNCS.change_search_func = function(e)
    if e.current_option ~= Showman.config.SEEK.search_ante then
        e.current_option = Showman.config.SEEK.search_ante
        e:recalculate()
        sendDebugMessage("recalculated!")
    end
    sendDebugMessage("## test!")
end

It won't even print "## test"

manic rune
#

sob

north lodge
#

(that's the one you made, I just didn't change the name)

manic rune
#

i guess func just doesnt work the same in create_option_cycle, somehow

north lodge
#

😭

#

But it does for create_toggle buttons...

manic rune
#

uhhhh

north lodge
#

err, UIBox_Buttons

manic rune
#

my last approach would probably be to add a func to the G.UIT.C/R containing that node to change it instead

north lodge
#

How would I access the option_cycle's current_option from the G.UIT.R though? Is there a get_child_by_id (or something) function, and that would let me do it?

manic rune
#

oh wait

#

can you try changing func to opt_callback in the create_option_cycle, just to check smt 🤔

shell kite
#

How could i discard all the cards held in hand? any idea?

north lodge
#

I get a crash on recalculate

manic rune
#

oh

#

thats a good signn then, at least it runs now

#

🤔

north lodge
#

Well that makes sense because opt_callback is called on the button press of the option_cycle

#

I just doubt func was ever getting called and thus why it wouldn't try anything

#

But this is the error, so I am not sure it is a great sign.

manic rune
#

ngl at this point probably just run the function that opens the ui 😭

#

i have no idea

#

change the :recalculate() part with the function that opens your ui

north lodge
#

That's disappointing that there isn't a better way to do it. That just feels wrong.

zenith hedge
#

how do i fix this

frigid cargo
#
    config = { extra = {xmult = 1.35} },

    loc_vars = function(self, info_queue, card)
        return { vars = { card.ability.extra.xmult } }
    end,
    calculate = function(self, card, context)
        if context.other_joker then
            if G.P_CENTER_POOLS['Shape'][context.other_joker.config.center.key == "Shape"] then
                return {
                    xmult = card.ability.extra.xmult
                }
            end
        end
    end,
}

I dont think i did my code right because it just doesnt work? can anyone help?

zenith hedge
#

dont think anyone is gonna help us

frigid cargo
#

womp wompsad

zenith hedge
#

why r u saying womp womp literally no one is gonna help you or me right now probably

frigid cargo
#

i know

keen totem
zenith hedge
#

alright

#

the main.lua right?

keen totem
#

the place where the error is

zenith hedge
#

ok

#

think its around here

north lodge
#

Include line numbers when you ss code

#

It's a good habit to make

keen totem
zenith hedge
keen totem
zenith hedge
keen totem
#

your atlas is wrong

zenith hedge
#

what in the atlas is wrong

keen totem
#

copy the key from the SMODS.Atlas over to the atlas part of the config in your seal

#

those have to be the same

zenith hedge
#

ooooooooohhhhhhh

keen totem
#

the atlas config in an object literally is "what key do i use?"

zenith hedge
#

i just started doing balatro mods today

#

so uhhh

#

thx for the help

keen totem
#

i think

zenith hedge
#

it broke

keen totem
#

that will have a giant red line under it

zenith hedge
#

no idea what that means

keen totem
#

syntax errors are gibberish to a coding language

zenith hedge
#

so where do i go to fix it

keen totem
#

fix the big red line

zenith hedge
#

i dont see it

north lodge
#

This particular one is about the rule that every { needs a } to close it. Just like every ( needs a ), and [ with ]

north lodge
keen totem
#

oh yhea

#

yea

zenith hedge
#

where do i find lua extention

keen totem
#

vscode extensions

#

its a whole tab

zenith hedge
#

ok

north lodge
zenith hedge
north lodge
zenith hedge
#

im using microsoft visual studio

north lodge
#

Oh visual studio

#

Mmm not vscode

zenith hedge
#

whats vscode

north lodge
#

extentions has its own menu in vs studio

frigid cargo
keen totem
#

use a for loop ig

#

iterate through the pool

north lodge
keen totem
#

see if anything has the joker that triggered's key

zenith hedge
#

oh ok

#

this one right

north lodge
#

Yes

zenith hedge
#

ok

north lodge
#

I'm off to bed, good luck

north lodge
#

Just remember a programmer's best friend is Google/any search engine

keen totem
#

then those become your best friend

regal ether
#

(stares at three specific people)

frigid cargo
keen totem
#

a complex for loop

#

for i,v in ipairs(table) do

end

frigid cargo
#

i mean i know for loops but how do i check if the joker is part of the pool

keen totem
#

iterates through table (in order in ipairs, whatever the hell it feels like if pairs) and you can run code for each item in it

#

tbh idk how pools store their info

#

so idk on that

north lodge
regal ether
frigid cargo
keen totem
#

its cutoff date was literally BEFORE balatro was released

#

or probably even started

zenith hedge
#

i still dont see the syntax error

keen totem
#

so good luck on mods

#

for a game

regal ether
keen totem
#

that it doesnt think exists

north lodge
keen totem
#

so yea

#

it doesnt think SMODS exists

north lodge
#

I'm not using smods in any of my work 😅
Then again I'm not making jokers so

north lodge
#

The Soul but in game

keen totem
#

the soul is in the game

north lodge
#

Everything works in just ironing out the fine details

zenith hedge
north lodge
#

The seed analyzing tool

keen totem
#

ah

zenith hedge
#

how do i fix this

keen totem
zenith hedge
#

i did

keen totem
#

then there should be

zenith hedge
keen totem
#

the big ass red underline

zenith hedge
keen totem
#

yes

zenith hedge
#

oh i see the red lines

#

managed to iron out some of them

#

but idk how to fix the others

#

????

#

uhhh dude

subtle merlin
# zenith hedge

the comma after end line 206

I can't help with the rest partly because Idk shit abt events, and mainly bc i can't understand the formatting for the life of me

urban wasp
#

what am i doing wrong?

loc_vars = function(self, info_queue)
    info_queue[#info_queue + 1] = { key = "e_crp_four-dimensional", set = "Edition", config = { retrigger_chance = 4, retriggers = 24 } }
    return { vars = {} }
end,
SMODS.Edition {
    disable_base_shader = true,
    disable_shadow = true,
    key = "four-dimensional",
    weight = 0.2,
    shader = "fourdimensional",
    in_shop = true,
    extra_cost = 5,
    sound = {
        sound = "crp_e_fourdimensional",
        per = 1,
        vol = 0.5,
    },
    get_weight = function(self)
        return G.GAME.edition_rate * self.weight
    end,
    config = { retrigger_chance = 4, retriggers = 24 },
    loc_vars = function(self, info_queue, center)
        local chance = center and center.edition and center.edition.retrigger_chance or lenient_bignum(self.config.retrigger_chance)
        local retriggers = center and center.edition and center.edition.retriggers or lenient_bignum(self.config.retriggers)
        return { vars = { G.GAME.probabilities.normal, chance, retriggers } }
    end,
    calculate = function(self, card, context)
        if
            context.other_card == card
            and (
                (context.repetition and context.cardarea == G.play)
                or (context.retrigger_joker_check and not context.retrigger_joker)
            )
        then
            local should_retrigger = pseudorandom("crp_fourdimensional") <= G.GAME.probabilities.normal / lenient_bignum(self.config.retrigger_chance)
            return {
                message = localize("k_again_ex"),
                repetitions = should_retrigger and lenient_bignum(self.config.retriggers) or 0,
                card = card,
            }
        end
    end,
    crp_credits = {
        idea = { "Glitchkat10" },
        art = { "Glitchkat10" },
        code = { "Glitchkat10" },
    },
}
plain gazelle
#

how do I create a negative consumable using SMODS.add_card {}?

sage crater
hybrid shadow
plain gazelle
sage crater
sage crater
subtle merlin
hybrid shadow
plain gazelle
sage crater
#

I was told it should be

hybrid shadow
plain gazelle
#

still doesn't work

hybrid shadow
hybrid shadow
sage crater
hybrid shadow
subtle merlin
molten musk
#

morning

plain gazelle
subtle merlin
molten musk
#

want this to give copy of last used consumable

sage crater
hybrid shadow
sage crater
#

returning funcs

subtle merlin
#

also it seems like Dex is filling in for N' rn lol

sage crater
#

trying a bit haha

#

I don't know everything, but I know enough to help with jokers and atlas stuff

hybrid shadow
# subtle merlin huh, the more you know

yeah its an interesting quirk i learned, though i suppose i learned it due to any creation of objects requiring commas up until the last line (since the object creations are also tables)

hasty mist
#

taking a stab at this again, anyone know what's wrong here?

hybrid shadow
sage crater
hasty mist
wintry solar
sage crater
#

very cool

plain gazelle
#

like that? still creates normal, not negative consumables

hybrid shadow
hasty mist
#

exponentia utilizes it

subtle merlin
#

"cryptid is dark magic"

wintry solar
#

Cryptid has a weird loading system it’s probably for that

hasty mist
#

what should i use instead?

hybrid shadow
hasty mist
#

would calculate work

sage crater
#

assuming you want init to happen as soon as the card appears

#

if you want it when it enters your slots, there's a context for that

hasty mist
#

i was simply overthinking it i think

sage crater
#

happens

wintry solar
molten musk
#

i was forgotten lol

wintry solar
#

Though the hooks are pretty scuffed tbh

subtle merlin
#

oh right i was here bc i had an issue:

I have an enhancement that counts every time it's played. The third time it's played, it self-destructs but provides 3x mult. The issue is that no matter what i try, I can't seem to get a joker to increase every scored timer by 1 whenever a timer hits 3. The image is my most recent attempt

sage crater
#

want this to give copy of last used

hasty mist
#

dammit

#

another mod is tripping it

sage crater
hasty mist
#

why would the first two hooks that i had before not crash while the last two do crash?

shell timber
#

four mluff.....

subtle merlin
wintry solar
whole lava
#

why this one isn't working ( a deck that destroy played card if the played card have multiple suits)?

hasty mist
#

set mult to chips when chips exceed mult and vice versa basically

sage crater
sage crater
hasty mist
#

wdym

subtle merlin
#

Afaik it's the selected cards, I've used it before but I could probably just use context.scoring_hand

wintry solar
hasty mist
#

i always get them switched up

#

its hard to say lmao

#

but like

sage crater
# hasty mist wdym

I misspoke-- a max func. Just put

chips,mult = math.max(chips,mult)
``` wherever you need the code to go
hasty mist
#

if you have 100 chips and then mult goes to 200, chips instantly jumps to 200 as well

sage crater
#

yes

#

if you use this correctly, it will make the lower of the two values jump to the higher of the two values

hasty mist
#

i'm trying to do it with mod_mult and mod_chips because they constantly update instead of just doing it after scoring or something

sage crater
#

oh, interesting

wintry solar
#

Give me a few minutes to get off my phone and I can type up a rough structure for you

umbral zodiac
#

is tehre a way to make a message from card_eval_status_effect last longer onscreen

hasty mist
#

taking this for example (something i know works perfectly) is a boss blind that makes mult always equal to 1

umbral zodiac
#

also howdy riley funny seeing you here

hasty mist
#

updating during scoring, it simply keeps mult at 1 no matter what you do

molten musk
#

whats the key for specific spectral cards?
is it just their names or do i put spectral_ before them?

hasty mist
#

and yet the EXACT SAME THING, using hand_chips instead of 1, doesn't work

hasty mist
umbral zodiac
#

that includes spectrals

molten musk
umbral zodiac
#

then just c_key

molten musk
#

like i wanna create a vanilla one?

#

ok

subtle merlin
umbral zodiac
sage crater
umbral zodiac
hasty mist
#

yeah no difference with fixed indentation

#

It seems to be tripping this line of code in another mod i have installed, and i cant figure out why

#

its just so weird to me because theres like

#

almost no difference in the hooks

#

yet one crashes and not the other

hasty mist
#

where it updates during scoring, rather than after

#

which SHOULD work fine, assuming mod_mult and mod_chips dont completely break

wintry solar
#

oh hang on no

#

that's better

hasty mist
#

alrighty

#

i will try it

sage crater
#

I still think you could use a max function

lament agate
#

can you make a custom one instead of the vanilla tooltips?

maiden phoenix
#

Yes, my mod has custom ones if you need refs

sage crater
maiden phoenix
#

Tho im on phone so I cant pinpoint where its localized

lament agate
lament agate
#

ks

maiden phoenix
#

Check for "set ="Other""

lament agate
#

wait this is tags

hasty mist
#

okay ive never seen a crash like that in my life

maiden phoenix
#

No

lament agate
#

so like

#

return
description
tags
and then that

sage crater
maiden phoenix
#

Thats for tooltip desc

lament agate
#

misc
v_text?

maiden phoenix
#

You want to make a joker tooltip?

lament agate
#

yeah, like

#

a joker tooltip

maiden phoenix
#

But a custom one right?

lament agate
#

yes

maiden phoenix
#

Or like referencing smt

lament agate
#

nah custom

maiden phoenix
#

And find the key in the loc/default.lua

wintry solar
hasty mist
maiden phoenix
#

Ye

wintry solar
hasty mist
#

😭 😭 😭

#

i need like

#

a hotkey to automatically wrap selected text in to_big

maiden phoenix
subtle merlin
wintry solar
#

I have an easy code smaple you could use to solve the problem

#

if Talisman then love.event.quit() end

hasty mist
#

i, unfortunately, rely heavily on talisman

#

just wait until luajit2 becomes meta...