#💻・modding-dev

1 messages · Page 619 of 1

wind steppe
#

show config in joker definition

tight pumice
daring fern
tight pumice
#

Well that got it a lot closer to working

#

Now it works TOO well, it's summoning a spectral card per card discarded

#

But that's better than it was

#

I've got it lined up with the implementation for ancient joker, shouldn't it be okay? It runs through each suit but excludes the one that trash_card currently is, right?

wind steppe
#

you're checking trash_suit

tight pumice
#

Oh that's just a naming error

#

There is no trash_card, I meant to change them all to trash_suit

#

Whoops

wind steppe
tight pumice
#

Thanks

#

It all works now

#

Thank god

#

This one was obnoxious

mossy minnow
#

how do i check if the player is in the shop

daring fern
mossy minnow
#

peak ty

mossy anchor
#

make this a deck

#

Wall Deck

#

the only blind per ante is The Wall

lament agate
#

how do you add spacing for dynatext

obsidian spear
#

joker display problem, how do I display a joker that has both xmult and plus mult

obsidian spear
#

anyone?

glass scaffold
lament agate
#

how do you detect a joker trigger

red flower
red flower
lament agate
red flower
lament agate
rugged crown
#

is it possible with a deck or anything to preset the boss blind for certain antes?

red flower
gilded blaze
#

my code was a so much of huge mess that I actually managed to trigger race condition

wheat jewel
#

i get an error at line 6685 where i try to get an edition of a playing card from the card array but that somehow isn't allowed to be done

gilded blaze
#

too many ipairs calls at once that the next function just fails to work sometimes

#

yay I love race condition

wheat jewel
#

does there exist a method to get the edition of a card because I couldn't find any documentation for it

daring fern
plucky berry
#

how do i make a modifier to make all blinds bosses and disable skips?

vale grove
#

how do you localize seals?

#

i know the format is like
Jokers = {
j_modprefix_jokerkey = {"
name = "test"
text = { text}

#

but

#

i cant seem to figure out the logic for seals

#

<@&1133519078540185692>

daring fern
vale grove
#

so no s_modprefix?

#

just modprefix?

daring fern
vale grove
#

alr ty

vale grove
#

is there something wrong with this?

#

YA being my mod prefix Discord being the seal key

#
return {
    descriptions = {
        Other = {
            Seals = {
                YA_Discord = {
                    name = "test",
                    text = {
                        "test"
                    }
                }
            },
```nestled like this
daring fern
vale grove
#

oh just other?

daring fern
vale grove
# daring fern Yes.
return {
    descriptions = {
        Other = {
            YA_Discord = {
                name = "test",
                text = {
                    "test"
                }
            },

is there anything wrong with this?

#

because it just doesnt do anything which i find weird

slim ferry
#

it has to have _seal at the end of the key

vale grove
#

oh right

#

im so smart

#

it still doesnt work

#

this is so annoying

slim ferry
#

show

vale grove
#
return {
    descriptions = {
        Other = {
            YA_discord_seal = {
                name = "test",
                text = {
                    "test"
                }
            },

this is what this looks like right now

#

the only two differences from the previous one is the capital D (i changed the key)

#

and the _seal

#
    key = "discord",
    loc_txt = { name = "Discord", text = {
        'gives you a {C:spectral}Discord {}message ',
        "When this card triggers gain {X:mult,C:white} X1,1{} mult",
        "{C:inactive}did someone ping me?{}"
    } },
    pos = { x = 0, y = 0 },
    config = { extra = { X_mult = 1.1, } },
    atlas = "discordseal",
    badge_colour = G.C.SECONDARY_SET.Spectral,
```with this being the seal code
slim ferry
#

oh wait

#

localization keys are all lowercase

#

also if its just the label not working under the card, you need to have a ya_discord_seal entry in misc.labels

vale grove
#

labels are an issue for later

slim ferry
#

since the text for the collection should work fine

vale grove
#

that ssomething ill get a headache over later

#

first i wanna get the thingie in dutch because then i can write that off as done

slim ferry
#

ah okay

#

well i think its just make the key in the loc file all lowercase

vale grove
#

what key tho?

slim ferry
#

the

#

YA_discord_seal

vale grove
#

bcs my mod prefix is uppercase in other places where it works

slim ferry
#

oh

vale grove
#
            j_YA_mango = {
                name = "Mango",
                text = {
                    '{C:chips}+6{} fiches{}',
                  
``` like this one that works
slim ferry
#

zes zeven

vale grove
#

yes

slim ferry
#

anyway

vale grove
#

it also gives zeven multi

slim ferry
#

i have no fucking clue anymore

vale grove
#

which i accidently left out

vale grove
slim ferry
#

things are often chopped and cooked before they're served and ate

#

or smth

vale grove
#

smth like that yeah

#

but

#

can you in that case help with with the error tag?

#

bcs i wanna be done with the mod for the most part today

#

because tomorrow evening is the last chance i get to work on it so i dont wanna push things off even more

slim ferry
#

yeah, the seal needs an entry in misc.labels with the text for it

vale grove
#

idk what misc.labels are tho?

#

i dont even have a label yet lol

slim ferry
#

label is the tag below the description

vale grove
#

so lets start with how does one go about making a label

vale grove
slim ferry
#

as an example

vale grove
#

oh like that

#

but what i wanna do is make one label from my mod and apply it to everything

slim ferry
#

i mean that should happen by default for all mods

#

you might have turned off displaying mod badges in steamodded config

vale grove
#

maybe but i havent even made the label yet

slim ferry
#

it just uses the display_name and badge_colour fields from metadata

#

or the mod name and white by default

slim ferry
#

yeah

#

well

#

without the # before the colour

vale grove
#

okay so

#

what should that do exactly?

#

because this makes the label but what does it apply on?

slim ferry
#

any items from your mod iirc

#

well anything with a standard description, tooltips and blinds wont show it outside the collection

humble pawn
vale grove
#

now that i think about it

#

maybe this isnt te play

#

maybe i just need to do what is more normal lol

slim ferry
#

what

vale grove
#

well i dont think my mod would really benefit from its own label all too much

#

ofc my seals need labels

slim ferry
#

i mean its like 2 seconds to add

vale grove
#

but besides that i dont think it adds much

slim ferry
#

and mods have it by default regardless

vale grove
#

first let me make the seals label i can "pieker"(idk the english on the top of my head lol)

#

so how do you update the badge text

slim ferry
#

wdym

#

did you save

vale grove
#

badge text

#

im stupid

#

label text

slim ferry
#

okay but wdym update

vale grove
#

well it says error

#

id like it to say Discord_seal yk

slim ferry
#

well you have the label in your localization file right

vale grove
#

is it vremade_ sealkey?

slim ferry
#

no vremade is just the vanilla remade mod prefix

vale grove
#

ah

#

so

#

YA

slim ferry
#

its just YA_discord_seal still

vale grove
#

aha

slim ferry
#

also vanillaremade is peak

#

great reference material

vale grove
#

ive taken alot of it and remade it for my own mod yeah

#

like this one

#

the 1 in 4 to become a lucky card is straight from midas mask

slim ferry
#

wizar

vale grove
#

nyway

vale grove
#

i added wizard(tovenaar) and magician(goochelaar)

slim ferry
#

its fun

#

stone joker core

vale grove
#

this one

#

might be my magnum opus joker

#

its thematic, effect and just overall fun to have

#

is so incredible

slim ferry
#

peak

vale grove
#

and also feels very vanilla to me

#

but yeah i really like lucky cards

#

so i thought id add more

rugged crown
#

is it possible with a deck or anything to preset the boss blind for certain antes?

vale grove
slim ferry
#

not sure

#

try making YA lowercase i guess

vale grove
#

oh okay

#

yeah that was just it

#

weird

vale grove
#

as a fellow dutch person

#

should i translate discord or keep it the same?

slim ferry
#

i mean discord is a brand name

#

so should stay the same

vale grove
#

alright

#

when i looked it up

#

none of these really make sense either

slim ferry
#

i mean discord is also an actual word

vale grove
#

another fun dutch typo

slim ferry
#

im the $ _ _
3

vale grove
#

theres alot of them

#

i figured out while translating them

slim ferry
#

its a feature now 🔥

vale grove
#

also

#

iam doing all of this just for this joker

slim ferry
#

Currently

vale grove
#

currently doesnt matter because this is in collection

slim ferry
#

yeah but currently in dutch

vale grove
#

OH

#

you righ

#

ty kind sir

#

or madam

#

idk

#

person🔥

slim ferry
#

true..

vale grove
#

balatrue

#

lmao

#

but yeah

#

im doing all of this

#

just for that one inside joke

#

of him enjoying translating memes in dutch

slim ferry
#

i mean localization files are also quite a bit more organized imo

tranquil gull
#

is there any good way to set the win ante of a challenge

slim ferry
#

change G.GAME.win_ante in apply

tranquil gull
#

doesn't seem to be an apply field

slim ferry
#

there is

tranquil gull
#

why is it undocumented???

slim ferry
#

because the page hasnt been updated since july

#

*june

#

and the feature is from after that

tranquil gull
#

what arguments does apply take

slim ferry
#

for challenges its just self iirc

vale grove
#

also eris

#

one quick question

#

is it possible to update loc_vars?

#

when something happens?

#

like lets say i buy blueprint, for the local vars to then say "you obtained blueprint"

#

just an exmaple

hardy viper
#

so you can refer to deck documentation for it ig

slim ferry
slim ferry
#

well that depends on what youre doing

vale grove
#

okay well full context

slim ferry
#

but youll be doing that in calculate

#

usually

vale grove
#

i have two jokers that are matching with eacother

#

one stacks itself on highcard

#

the other gives money and a tarot on highcard

#

i want both of them to get buffed when you have the other one

#

so the stacking one gets additional stacking and the money one gives a level to highcard for example

#

now what i think would be cool would be to update local vars saying like "you found the other end, now gaining (specific buff)

slim ferry
#

you can return key = ... in loc_vars to change the localization key it uses

#

so you can check for the other in loc_vars and add a key to the return if so

#

anyway i gotta eat now

vale grove
#

but i think i sort of get it

crystal perch
#

how do i detect if you use a specific consumable card. like the judgement tarot card for example
i've tried a lot of permutations of if context.using_consumable and context.consumable.ability.key == "c_judgement" then but nothing seems to work

frosty rampart
#

it's context.using_consumeable and context.consumeable...
with an extra e
because localthunk doesn't fix his typos

normal crest
#

also

#

the second part should be and context.consumeable.config.center_key

crystal perch
#

<@&1133519078540185692>

frosty rampart
#

<@&1133519078540185692>

novel violet
karmic creek
#

neat

crystal perch
#

w mods

novel violet
#

ty mods we love you

#

mwah type shit

frosty rampart
#

thanks mods

rigid pebble
#

thanks mods

crystal perch
#

yeah it was the typo thing

#

thank you thunk

#

💀

karmic creek
#

lol

novel violet
#

i believe that was global thunk, as opposed to local

plucky berry
slim ferry
vale grove
plain apex
#

probably done horribly but i have successfully implemented determining of the latest video on a youtube channel and how many views it has

vale grove
#

i make two of the same joker desciription in localization

#

i make a local variable

#

true = 1 version
false = 2 version

#

and the variable checks for if the other joker is in joker_main

slim ferry
#

thats pretty similar to what entropy does except that its stored in the ability instead of being a local variable

#

so you can just return key = <bool> and self.key or <other key>

#

or the other way around

#

whichever is before the or is whats used when the bool is true

vale grove
#
                for _, j in ipairs(G.jokers.cards) do
                    if j ~= card and not j.getting_sliced then
                        local key = j.config and j.config.center and j.config.center.key
                        if key then
                            if key:find("ice_cream") then
                                card.ability.extra.chips = card.ability.extra.chips + 50
                                j.getting_sliced = true
                                j:start_dissolve({ G.C.RED }, nil, 1.6)
```so something similar to this without the slicing part is what im thinking
slim ferry
#

and probably also using key == ... instead of string.find

#

but yeah

slim ferry
#

check if the string is equal to something

#

rather than string.find with some part of the key youre looking for

vale grove
#

oh yeah wait

#

i should probably put this in update shouldnt i

slim ferry
#

why

vale grove
#

so it always checks for the loc_vars?

slim ferry
#

wdym

#

loc_vars always runs when hovering the joker

vale grove
#

ohh i see i see

vale grove
slim ferry
#

what is the code currently

vale grove
#

okay well the full code is a little more than just that

#

but i already have a joker main

#
        if context.joker_main then
            return {
                chips = card.ability.extra.chips,
                mult = card.ability.extra.mult,
                Xmult = card.ability.extra.Xmult

            }
        end
```being this
#

idk how i add the check for the other joker key into this

slim ferry
#

you should be able to just add key = next(SMODS.find_card(<joker key>)) and self.key .. "_alt" or self.key to the loc_vars return

#

you can do the same here

#

by using a different number

#

instead of a different string

vale grove
#

whats the and self.key used for?

#

wait actually

slim ferry
#

self.key is the joker key

vale grove
#

just for logical purposes i might need that

#

this is just kinda making my head spin

slim ferry
#

fun thing about lua is that <condition> and <thing 1> or <thing 2> just works

vale grove
#

ive never worked inside of loc_vars othar than card.abillity.extra smth

vale grove
slim ferry
#

it adds _alt to the end of the returned key if the other joker is present

#

so itll get its own key with _alt at the end from the localization instead

vale grove
#

im so confused at all of this

#
        return { vars = { 
            card.ability.extra.chips, card.ability.extra.chip_mod, card.ability.extra.mult, card.ability.extra.mult_mod, card.ability.extra.Xmult, card.ability.extra.Xmult_mod },
            key = next(SMODS.find_card(<YA_matthsilly>)) and self.key .. "_alt" or self.key
        }
        
    end
```this on its own already gives 2 errors on they key line
slim ferry
#

yeah you do have to make the joker key a string

#

in the SMODS.find_card

#

"j_YA_mathsilly"

vale grove
#

i even then i get this load of errors

slim ferry
#

show the code in editor

vale grove
slim ferry
#

yeah remove the <>

vale grove
#

okay so

#

now i just make in my loc_vars

#

what i have and add _alt

#

and then just

#

it works?

slim ferry
#

well assuming you have that key in your localization file yes

vale grove
#

yes i do

slim ferry
#

okay yeah then it should work

vale grove
#

okay got it to work

#
        Tarot = {
            t_YA_fentanyl = {
                name = "Fentanyl",
                text = {
                    "Geeft een kaart de{C:attention}Fent zegel{}"
                }
            }
        },
        Spectral = {
            s_YA_Everyone = {
                name = "@Everyone",
                text = {
                    "Geeft een kaart de {C:spectral}Discord zegel{}",
                    "{C:inactive}wtf bro waarom zou je dat doen?{}"
                }
            }
        }

any idea why these arent working? @slim ferry

slim ferry
#

its c as a prefix for any consumable

vale grove
#

i recall them working before

frosty rampart
#

it's still c as a prefix for any consumable

wind steppe
vale grove
#

correct

north brook
#

hey, fun issue. For whatever reason, a Joker I have crashes when trying to modify a card using a variable. The issue line is

frosty rampart
#

rank takes rank keys, not IDs. so "Jack", "Queen", "King", and "Ace", not "11", "12", "13", and "14"

north brook
#

does the local ranks = { not convert the ID to a Key?

daring fern
frosty rampart
north brook
#

one little change

#

damn

#

thanks

#

I really appreciate it

strong plume
#

Hi, massive noob question - what does the pseudorandom function do? I know the string there is like some seeding for it, but what range does it give out - is it a 0 to 1 deal, a 0 to 100, 0 to 255, what's the usual range of numbers it spits out?

slim ferry
#

its 0 to 1 by default

#

but you can add the min and max arguments to get a random integer in any other range

strong plume
#

Alright, thanks!

wicked heron
#
if context.starting_shop then
            for i = 1, #G.GAME.tags do
                if G.GAME.tags[i]:apply_to_run({ type = 'new_blind_choice' }) then break end

            end
        end

This code causes all the booster tags to overlap - is there a way to make each tag wait until the previous tag is resolved?

slim ferry
#

why do you need to do this

#

tags calculate this by default

wicked heron
#

I have a joker that adds booster tags during the round. In the following shop, the tags begin to trigger at unusual times

#

like when you buy something

#

the above code is to have the tags trigger when the shop begins

slim ferry
#

they already trigger after ending a booster, the best you can do is just completely copy the original tag calculation if you really want them to go at the start of the shop

wicked heron
#

hmmm, I hear you

#

I'll dig a little more

#

ty

stone dagger
#

Hello. ObjectType can be used to create pools for specific jokers? Does anyone have an example of this?

wind steppe
# stone dagger Hello. ObjectType can be used to create pools for specific jokers? Does anyone h...
PSI.republicans = {
    ["j_castle"] = true,
    ["j_baron"] = true,
    ["j_hanging_chad"] = true,
    ["j_popcorn"] = true,
    ["j_even_steven"] = true,
    ["j_diet_cola"] = true,
    ["j_caino"] = true,
    ["j_triboulet"] = true,
    ["j_burglar"] = true,
    ["j_wrathful_joker"] = true,
    ["j_onyx_agate"] = true,
    ["j_para_republicandiscordserver"] = true,
}
local function inject_republicans(self)
    for k, v in pairs(PSI.republicans) do
        if G.P_CENTERS[k] or SMODS.Centers[k] then
            local center = G.P_CENTERS[k] or SMODS.Centers[k]
            if not table.contains(self, center) then
                self:inject_card(center)
            end
        end
    end
end
SMODS.ObjectType({
    key = "para_republican",
    default = "j_hanging_chad",
    cards = PSI.republicans,
    inject = function(self)
        SMODS.ObjectType.inject(self)
        inject_republicans(self)
    end,
#

and then i can spawn a random one with ```lua
SMODS.add_card {
set = 'para_republican',
key_append = 'para_republicandiscordserver'
}

hardy viper
#

fym republicans 😭

daring fern
stone dagger
#

Thanks!!

slim ferry
timid parrot
wind steppe
obtuse silo
#

was wondering how to get this artist credit popup when you hover over the deck skins
(taken from base game)

tepid crow
#

that's in the base game???

#

oh it's not, it's something that smods adds to the base game deckskins

obtuse silo
#

oh mb

#

didn't know that-

obtuse silo
#

i mean this sort of helps but idk how to get it working-
this isn't mentioned in the smods wiki for some reason, not even in the deckskin page

obsidian spear
#

how do I get the cards in G.play

daring fern
obsidian spear
#

I swear i tried that

#

but alr

stone dagger
#

Hello. I'm trying to create a deck that spawns a random negative, eternal joker. But when I create the joker it spawns in the Joker area but then I can move it anywhere, can't sell it and it doesn't work. Any idea why?

Here's the create code. I can provide the rest if needed.

SMODS.create_card({set = 'Joker', area=G.jokers, key = random_joker, stickers={"eternal"}, edition="e_negative"})

slim ferry
#

use SMODS.add_card rather than create_card

stone dagger
#

fair enough

dusty fractal
#

do u guys know why a voucher would just not generate in the dictionary in game

strong plume
#

Hello, I have a dialogue system for the jokers talking mid-game.
Right now tho it says all 3 lines at once; "remove dialogue" is how long the message stays, but they fire all at once.

How can I add a "delay" to the code'? Is there like a wait function?

sharp arch
#
    key = "jimble",
    path = "jimbonium.png",
    px = 142,
    py = 171,
    atlas_table = 'ANIMATION_ATLAS',
    frames = 70

}``` I KNOW THE CRASH HAS SOMETHING TO DO WITH THIS BUT CAN YALL HELP
#

sorry caps

daring fern
sharp arch
daring fern
sharp arch
#

what then how do would i animate a joker

crystal perch
plucky berry
#

guys can someone help me make a challenge similar to Enter the Gungeon in cryptid that code is gibberish for me

#

i want to make all blind bosses and unskippable

crystal perch
#

you can set the delay with the delay value

#

i think it's in seconds by default, but you can scale it to game speed by multiplying it by G.SETTINGS.GAMESPEED

#

like delay = 0.2 * G.SETTINGS.GAMESPEED

strong plume
#

I see, thank you

sharp arch
#

ok well uhh how do I animate a joker

crystal perch
#

i do not know, the vanillaremade wiki is working on a section on that but it's not done yet

#

i have a question of my own, is there an easy way to change the sound and colour of chip, mult, and xmult calc returns? my current code does not work

return {
  sound = { sound = "foil1", per = 1.2, vol = 0.4 },
  colour = G.C.DARK_EDITION,
  chips = 50
}
#

it just returns the chips but the colour is still blue and the sound is the default chip sound

daring fern
#

Also sound would be a string.

crystal perch
#

so would per and vol just be separate lines

sharp arch
#

whats the play here

daring fern
daring fern
sharp arch
daring fern
sharp arch
#
    key = "music_getr",
    path = "music_jimbum.ogg",
    vol = 0.6,
    pitch = 0.7,
    selectmusictrack = function()
        if G.jokers then
            if next(SMODS.find_card("j_jabong_jimbyramid")) then
                return SMODS.Mods.jamod.config.getr
            end
        end
    end
    
}``` ok so it didnt work, but i'm on the right track, right
daring fern
#

What is not working about it?

#

It's modprefix_key

crystal perch
sharp arch
crystal perch
#

but it's not subject to that because i'm overriding the default message

daring fern
crystal perch
#

no i have a joker which makes foil, holo, and poly cards score in hand

calculate = function(self, card, context)
        if context.individual and context.cardarea == G.hand and context.other_card.edition and not context.end_of_round and not context.blueprint then
            if context.other_card.edition.foil then
                return {
                    chips = 50,
                    chip_message = {
                        message = "+50",
                        sound = "foil2", 
                        pitch = 0.8, 
                        volume = 0.4,
                        colour = G.C.DARK_EDITION
                    }
                }
            elseif context.other_card.edition.holo then
                return {
                    mult = 10,
                    mult_message = {
                        message = "+10",
                        sound = "foil2", 
                        pitch = 1.0,
                        volume = 0.4,
                        colour = G.C.DARK_EDITION
                    }
                }
            elseif context.other_card.edition.polychrome then
                return {
                    xmult = 1.5,
                    xmult_message = {
                        message = "X1.5",
                        sound = "foil2", 
                        pitch = 1.2, 
                        volume = 0.4,
                        colour = G.C.DARK_EDITION
                    }
                }
            end
        end
    end
}
daring fern
#
local oldcalcedition = Card.calculate_edition
function Card:calculate_edition(context)
    local g
    if self.edition then
        if (self.edition.foil or self.edition.holo or self.edition.polychrome) and context.cardarea == G.hand then
            if next(SMODS.find_card("j_modprefix_key")) then
                context.cardarea = G.play
                g = oldcalcedition(self, context)
                context.cardarea = G.hand
            else
                g = oldcalcedition(self, context)
            end
        else
            g = oldcalcedition(self, context)
        end
    end
    return g
end
crystal perch
#

oh thank you

crystal perch
tight pumice
#

what's the context for just sitting in a blind? no cards selected, nothing being played or discarded

red flower
tight pumice
#

I've got this snippet of code to make the joker jiggle when its active, but its a lil funky

#

It gets progressively juiced kind of? Seems like if I'm on my last discard and play hands the jiggle gets more intense

#

So I thought maybe finding a proper context for it to activate the jiggle is the answer

#

Maybe I should trigger context.after

red flower
#

yeah if theres no context check it will happen over and over

tight pumice
#

I figured that was the issue

#

I'm unsure what context to use since its discard specific, and there's not a first_hand_drawn equivalent for last discard(?)

red flower
#

just do that check you have right now in context.pre_discard

tight pumice
#

It won't only jiggle once the discard has begun to be used?

red flower
#

if you do the check correctly it will start once you do the second to last discard but yeah if something else messes with discards it wont work

#

hmm i would probably do it in update then

#

instead of calculate

tight pumice
#

in update?

red flower
#

yes, check in update when discards is 1 and you're in a blind (G.GAME.blind.in_blind) and start the juice then, you also need to set a flag so it doesnt juice again that blind

#

it would basically be what you were trying to do

#

but doing it in calculate would be bad because it will be dependent on contexts instead of being every frame like update

frosty rampart
#

(e.g. if you had a burglar-esque joker that left you with one discard, the joker would never jiggle because you never actually discarded down to the point where you had one discard left, you lost them to external factors)

tight pumice
#

Got it to work, ended up going about it like this

dusty fractal
#

booster_size_mod how does booster_size_mod function?

#

i was doing a lovely patch but i saw it ha dimplementation

frosty rampart
#

the game adds G.GAME.modifiers.booster_size_mod to the number of cards available in any given booster pack, its default is zero

dusty fractal
#

yeah but trying to access it

#

it returns as a nil value

frosty rampart
#

right its default is nil if nothing's touched it before

#

my bad

#

before you do anything with it, you'll need to check if it's nil, and if it is, set it to 0

dusty fractal
#

ah easy fix

tepid crow
#

oh it's only 3 months old

lament agate
#

how do i color dynatext to look like xmult text

#

since afaik you can only color the text

bold gyro
#

hey y'all, i'm trying to dick around with shaders. how would i get the horizontal position of a pixel(?)? i've tried to use texture_details.x and sprite_pos_x, which is code from the flipped.fs shader, but both seem to be set as 0 regardless of position.

vec4 effect( vec4 colour, Image texture, vec2 texture_coords, vec2 screen_coords )
{
    vec4 tex = Texel(texture, texture_coords);
    vec2 uv = (((texture_coords)*(image_details)) - texture_details.xy*texture_details.ba)/texture_details.ba;

    const vec3 BALATRO_RED = vec3(0.992, 0.373, 0.333);
    const vec3 BALATRO_BLUE = vec3(0., 0.612, 0.992);
    
    float sprite_width = texture_details.z / image_details.x; // Normalized width
    float sprite_pos_x = texture_details.x * sprite_width; // Normalized pos_x

    vec4 hsl = HSL(tex); // convert texture to HSL values
    vec4 bhsl = HSL(tex); // make a base copy of HSL values

    vec3 sepiaVec = tex.rgb;
    sepiaVec.r = 0.05 + (1 * tex.r + 1 * texture_details.x / sprite_width);
    sepiaVec.g = 0.05;
    sepiaVec.b = 0.1 + (1 * tex.b + 1 * texture_details.x / sprite_width);

    tex = vec4(sepiaVec, tex.a);

    // Does not do anything. Required for shader to not crash.
    if (uv.x > 2. * uv.x) {
        uv = evil;
    }

    // required
    return dissolve_mask(tex*colour, texture_coords, uv);
}
final jewel
#

I have an animation bug with my seal by upgrading it it disapear at start of the animation but like I just want it to be upgrade by turning the card. I know why it does that (cause set_seal make the seal nil at start) but how can I solve this

final jewel
# daring fern Code?
function upgrade_seal(selected_card)
    G.E_MANAGER:add_event(Event({
        trigger = 'after',
        delay = 0.4,
        func = function()
            selected_card:juice_up(0.3, 0.5)
            return true
        end
    }))
    G.E_MANAGER:add_event(Event({
        trigger = 'after',
        delay = 0.15,
        func = function()
            selected_card:flip()
            selected_card:juice_up(0.3, 0.3)
            return true
        end
    }))
    delay(0.2)
    selected_card:set_seal(G.P_SEALS[selected_card:get_seal()].giga_data.seal_upgrade)
    G.E_MANAGER:add_event(Event({
        trigger = 'after',
        delay = 0.15,
        func = function()
            selected_card:flip()
            selected_card:juice_up(0.3, 0.3)
            return true
        end
    }))
    G.E_MANAGER:add_event(Event({
        trigger = 'after',
        delay = 0.2,
        func = function()
            G.hand:unhighlight_all()
            return true
        end
    }))
    delay(0.5)
end

I use this function when I need to upgrade a seal

normal crest
#

you could set the seal while the card is flipped and use the immediate argument

final jewel
#

oh yeah. and if like a seal is upgraded while a hand is play like a joker effect does it going to have the effect of the upgraded seal ?

final jewel
#

by doing that it set the seal after the flip animation

river grail
#

Is it possible to give playing cards tooltips without giving it, like, an edition? For example, if I switch the suit of a card, am I able to add a tooltip to the side for elaboration? (It's for the card merging mechanic)

river grail
#

i'll look into that

normal crest
#

and you'd put the set_seal call in an event that happens after 0.2

#

instead of the delay

final jewel
#

oh

tight pumice
#

Is there a way to use pseudorandom stuff to grab a random tag?

normal crest
# final jewel so like that

presumably, idk which argument the immediate one is, but also you're forgetting the trigger = "after" on the event

final jewel
#

wait hw does it got remove

#

hell yeah it work now thx srockw

normal crest
#

np mryamitsu

red flower
final jewel
#

now no one can say that my seal animation are broker

#

I mean someone was laughing about my wacky animation

wraith jolt
#

is there limit to how many mods can be downloads but not active

wraith jolt
# daring fern No.

Because I had like 70 and the mod manager keep crashing and deleted like 8 and it came back

winter flower
wraith jolt
#

this really odd and this mods were working yersteday too

winter flower
wraith jolt
#

Ya that what going to do

proper relic
#

Potentially stupid question is it possible to add a Joker and have it NOT appear in the collection?

tight pumice
# red flower tag you own or any random tag

I figured out the random tag thing, but on rare occasion no tag spawns and the game crashes upon leaving a shop. Does the game not allow certain tags to show up at certain antes? I know they can't show up as skips, but I figured that it would be okay if given manually

#

I checked through the tag options that can be selected and none seem to be invalid or spelled wrong or anything

frosty rampart
tight pumice
#

I want to make it work with blueprint at some point which will require altering some things but I haven't gotten there yet

daring fern
# tight pumice
local tag = Tag(get_next_tag_key())
tag:set_ability()
add_tag(tag)
tight pumice
#

Would blueprint work if I make the first if statement
if context.ante_change or context.blueprint then

daring fern
red flower
tight pumice
daring fern
tight pumice
#

Getting "attempt to index nil value" crashes after beating a boss blind with this code

fluid steppe
#

anyone have any idea? i can't run mods as of right now which is really hampering my ability to. actually develop my mod

tight pumice
#

wait

#

I see the issue

#

Yep it works now thanks so much

#

It does still have a crashing issue with orbital tags but I think I'm going to temporarily leave those out of the pool of tags and figure that out another itme

#

time*

#

or something

red flower
winter flower
tight pumice
#

Yes you may what should I look at

red flower
#

search for tag

#

there's a section on how to create a random tag that accounts for orbital

winter flower
#

it’s 11:30 i shouldn’t be here rn

tight pumice
#

The wiki is seperate from the github?

#

the repo i mean

#

nvm i see it

#

Can't find a spot on specifically orbital tags

#

I saw this for random tag generation

red flower
#

yes

#

the "small" part handles that

tight pumice
#

Interesting

#

Implemented that but it still crashed when a orbital tag got picked

red flower
#

what's the crash and the code

tight pumice
#

One sec

#

So ofc now I can't get the crash to happen

#

Okay finally

red flower
tight pumice
#

Is that a thing

#

Dang

red flower
#

yeah in Mods/lovely/log

#

also can i see the code

#

do you still have the set_ability thing

tight pumice
red flower
#

hmm

#

oh it might be a timing thing

#

i fixed this in hot potato let me search for it

tight pumice
#

I'll have to come back to this potentially

#

Is there a way I can temporarily exclude the orbital tag just to not crash for now

#

like while selected_tag == 'UNAVAILABLE' or selected_tag == 'tag_orbital'

red flower
#

yeah

fluid steppe
pastel kernel
#

how do i use mod.calculate to check for if score reaches 1e100 with played hand being a flush five of spades?

faint yacht
#

Compare SMODS.calculate_round_score() to that.

pastel kernel
faint yacht
#

if SMODS.calculate_round_score() >= 1e100

pastel kernel
#

how do i make it so that played hand must be a flush five of only spades? (i'm changing clubs to spades)

mystic river
#

well :is_suit() looks at one card and returns a boolean, so comparing it to a number isn't gonna do it

#

also you're not passing context into the calculate function there

#

or more accurately you're naming the context table

stuck ore
#

add_tag(Tag('tag_rare'))
So this isn't correct for creating a rare tag, just curious about what the key for a rare joker tag would be

faint yacht
#

tag_rare is the key though.

stuck ore
#

odd

faint yacht
#

This yielded the tag.

stuck ore
#

Thank you kindly, I will simply strangle my code till it works

pastel kernel
#

i'm still new to this lua stuff

#

despite knowing a bit more

stuck ore
#

I'm curious if there's some super obvious way to change the local text of a joker (The description) when a condition is met, I've been trying for a bit to decypher another mod but I realized I should ask

faint yacht
stuck ore
#

Thank you for the response and also the example

lament agate
#

@shell timber hey i was wondering how did you do atlas for rotated tarot card since it's tilted and not the usual vertical

shell timber
#

its not tilted

lament agate
shell timber
#

its not rotated

lament agate
shell timber
#

its just a larger square

long sun
#

how do you remove a card's seal or edition?

daring fern
long sun
#

cheers ^^

#

does this also work with set_ability?

daring fern
long sun
#

grand :D

#

tytyty!

long sun
#

i have this blind ability:
First scored card in poker hand is debuffed
how might this be implemented?

daring fern
long sun
#

ah, thanks ^u^

#

also one more thing

#

this is swapping chips and mult, but then swapping it back

#

what have i missed?

daring fern
long sun
#

👍

pastel kernel
#

okay what about poker_hands? @faint yacht

faint yacht
#
if context.after and context.poker_hands and next(context.poker_hands['Flush']) then
  if bigscore then -- put the score check here.
    local allspades = true -- assume all Spades.
    for k, v in ipairs(context.scoring_hand or {}) do -- 'or {}' is fallback in case context.scoring_hand somehow doesn't exist?
      if not v:is_suit('Spades') then allspades = false; break end
    end
    if allspades then
      -- spawn the goober.
    end
  end
end
faint yacht
#

With your to_big(getscore) >= to_big(1e50) check.

split saddle
#

how do you check if a card is debuffed?

red flower
#

card.debuff

split saddle
#

if card.debuff == true?

hardy viper
#

you can just do if card.debuff then

tranquil gull
obtuse silo
#

any way i can learn how to put stuff on the title screen?
i wanna try to add something on the bottom right of the logo

rigid solar
#

I found there's a dependencies field for object parameters, but the object will only load if all the dependencies are present. Is there a way to load something if only one is present?

#

I wanna make a deck that only loads when playing multiplayer, but there's Multiplayer and NanoMultiplayer and obv you don't want both multiplayer mods at the same time

daring fern
frosty rampart
#

i would hope that nanomultiplayer just is set up to provide regular multiplayer though

rigid solar
#

i guess that works yeah

frosty rampart
rigid solar
#

nah you have to check for both

frosty rampart
#

what is nanomultiplayer anyway

rigid solar
#

multiplayer but with more than 2 players gamemodes

slim ferry
#

isnt that already on some branch of multiplayer

rigid solar
#

yeah that's nanomultiplayer

slim ferry
#

why does that have a seperate mod id

rigid solar
#

🤷‍♂️

slim ferry
#

it definitely shouldnt do that

frosty rampart
#

yea that should really be something for multiplayer to fix

#

if i cared about it at all i'd join the server just to pester them about it

#

but i don't

rigid solar
#

well there are some differences

slim ferry
#

thats like one of the worst practices

frosty rampart
#

so that's someone else's job

rigid solar
#

some things work with multiplayer that don't work with nano

#

and the opposite

slim ferry
rigid solar
#

for example, for a joker of mine

slim ferry
#

why the fuck do they do that

rigid solar
#

don't ask me im not the multiplayer dev lol

obtuse silo
#

hold on
how do i get the name of the booster pack being opened

slim ferry
#

also the branch doesnt even exist on the github

#

at least not with that name

rigid solar
#

yeah it's a different repo i believe

frosty rampart
obtuse silo
#

ok thing is i'm doing this for a patch that makes a dumb sound play when a specific booster pack is opened

slim ferry
#

could you do that in a mod calculate

frosty rampart
#

yea i'd just do that in a mod calculate

slim ferry
#

or in an i == 1 check in the booster's create_card

obtuse silo
#

this doesn't seem to be doing anything

daring fern
frosty rampart
#

^context.card is the whole card object, not just the key

glass scaffold
#

Anyone know what I'm doing wrong?

obtuse silo
daring fern
obtuse silo
#

just implemented that
it still hasn't done anything
i think it's a fault with the logic seeing as how i haven't had any crashes

slim ferry
frosty rampart
#

put a print statement in to see if it's even making it through the context check in the first place

obtuse silo
slim ferry
#

it does because that means you define it twice

#

and the last one overrides all the previous

frosty rampart
#

yea everything needs to go into a single calculate function, you can't have two of them

obtuse silo
#

i see i see

#

alrighty
i think it's worth me making a new file to contain this calculate function :]

wintry solar
obtuse silo
mossy anchor
#

how do i make a textbox like the profile name

#

i want a spot i can type stuff in

loud summit
#

hey uh whats the diff between card.base.value and card.base.id

daring fern
loud summit
#

oh

frosty rampart
#

the key of the rank is consistent, the ID isn't (because it could change if another mod loads a custom rank before you do)

mighty quiver
#

Hey guys, i'm trying to code a joker that switches languages when owned and i have no idea why this doesn't work. Can anyone help me?

loud summit
#

also how does smods watch file work

lament agate
shell timber
#

just change the size

lament agate
shell timber
#

yeah sure

versed swan
#

does anyone know what the difference is between _c and card in generate_card_ui?

#

(function in common_events)

loud summit
daring fern
versed swan
#

is _c the center of card?

daring fern
versed swan
#

i see, thank you

loud summit
#

how do you use debugplus watch file

lament agate
#

how do you make a seperate button for custom consumables

#

@slim ferry help

slim ferry
#

idkf man

#

i dont do card buttons

#

ask ruby :trol:

lament agate
#

LIKE IN ADDITIONS TAB

#

😭

slim ferry
#

oh

#

it already does that

lament agate
#

theres a set parameter

slim ferry
#

what

lament agate
slim ferry
#

yes

red flower
#

you need a ConsumableType

#

if that's what you're asking

lament agate
#

right

#

can someone link me the wiki for constype

red flower
#

it's the one for ObjectType

#

my internet is trash rn or id do it

lament agate
#

tyyy

#

mwah

slim ferry
lament agate
#

damnit

lament agate
slim ferry
#

Uhhhhhhh

#

I think secondary is text and collection button

#

And then primary idk

#

Or the other way around

lament agate
#

N' save me

#

imma have to look at lucky rabbit's code again

#

@lucid owl help me

lucid owl
#

yeah you got that

lament agate
lucid owl
#

i forgot

lament agate
#

ah fuck it

lucid owl
slim ferry
lament agate
#

wii

red flower
#

there's a new parameter for the button text that idk if it's documented

wind steppe
strong plume
#

Does anyone know how to do an if statement that checks to see if the player has 0 vouchers?

lament agate
#

how would i use it if theres no documentations for it

#

😭

strong plume
#

thanks!

wind steppe
#

and find it while searching for something else

lament agate
#

am i doing this right

daring fern
lament agate
frosty rampart
daring fern
lament agate
#

cards function?

daring fern
lament agate
lament agate
daring fern
lament agate
#

fixed it

#

now how do i fix this

solid salmon
#

is there something like this but for discards?

solid salmon
daring fern
lethal juniper
#

So I've got an enhancement that give xmult when a Joker triggers it while it's held in hand. I'm using post_trigger to do it, but I want to limit it to only giving xmult once per (re)trigger pass instead of giving xmult for every effect, like it would when scored. Any suggestions on how to limit it like that?

#
if context.post_trigger and context.other_context.individual and context.other_context.cardarea == G.hand and not context.other_context.end_of_round and context.other_context.other_card == card then

these are the contexts I'm using

red flower
red flower
cerulean rose
cerulean rose
lethal juniper
cerulean rose
#

so in the same context as a baron?

cerulean rose
red flower
cerulean rose
#

each baron happens once

red flower
#

can you let the person that im helping reply to my question

lethal juniper
#

but also mime gives a retrigger so its 4 baron triggers total

#

and yeah with no mime the enhancement triggers twice

red flower
#

thanks
hmm that's a bit hard because I don't think the contexts get if it's being retriggered

lethal juniper
#

yeah for real, been scratching my head at this thing for a bit lol

red flower
#

the naive solution would be to flag each joker but each enhancement would have to do it separately

wind steppe
#

someone should make an smods pr for that retrigger checks seem to be a fairly common effect

lethal juniper
#

is there any way to check how many retriggers are calculated for a card? Maybe I could cobble together a fix with that?

solid salmon
#

i implemented

#

THE COLLECTOR

azure ember
#

I'm trying to add a variant of rare spectral cards that appear rarely in spectral packs like how the soul card rarely spawns in tarot packs. to be clear, they are registered as spectral cards. how can i do that, i want them to not appear in spectral packs like the other ones unless the rare chance is rolled. how do card pools work, is it from the entire consumable type?

azure ember
azure ember
#

thanks for the help

weary merlin
#

trying to make something similar to baseball but for negative editions, can't figure out exactly what to include in the calculae function to get this to enact on negative editions

--Antimeme
SMODS.Joker{
    key = "j_antimeme",
    
    loc_txt = {
        name = "Antimeme",
        text = {
            "{C:dark_edition}Negative{} Jokers",
            "each give {X:red,C:white} X#1# {} Mult"
        },
        unlock = {
            "Have at least {C:attention}3",
            "{C:dark_edition}Negative{} Jokers"
        }
    },
        
    rarity = 3,
    cost = 10,
    blueprint_compat = true,
    
    pos = { x = 4, y = 0 },
    atlas = "jesters",
    
    config = { extra = { xmult = 2 } },
    loc_vars = function(self, info_queue, card)
        return { vars = { card.ability.extra.xmult } }
    end,
    
    calculate = function(self, card, context)
        if context.other_joker then
            return {
                xmult = card.ability.extra.xmult
            }
        end
    end,
    
    unlocked = false,
    check_for_unlock = function(self, args)
        if args.type == 'modify_jokers' and G.jokers then
            local count = 0
            for _, joker in ipairs(G.jokers.cards) do
                if joker.ability.set == 'Joker' and joker.edition and joker.edition.negative then
                    count = count + 1
                end
                if count >= 3 then
                    return true
                end
            end
        end
        return false
    end
}
#

is there an additional context parameter to invoke to be able to fetch the correct methods/properties?

daring fern
dawn moat
#

This feels like a stupid question, but the vibe coding ain't working.
Is there a way to draw the pips on the cards? I'm trying to save time from having to save eight different versions of suit sets.

weary merlin
weary merlin
#

dots on cards/dice are known as pips

dawn moat
weary merlin
#

that too ig

dawn moat
#

Yeah, I didn't know there was a name for those either.

tranquil gull
#

how would i go about converting a single strintg like {C;blue}this{} into a node tree

daring fern
#

desert ore
#

any tips on how I should shade the robe? I have no idea how to go about it

river grail
#

Is the robe doing this? Or is this like, an actual robe?

desert ore
#

I don't really know what I was going for sorry lol. I just want it to maybe have a few folds. witch robes are pretty plain

#

clothes are hard to shade

fleet thorn
#

I'm trying to make a silly text mod like Balagay, but I can't seem to see what's wrong with my mod metadata. It shows up in BMM, but not in game. Any help?

{
"id": "polylatro",
"name": "PolyLatro",
"display_name": "PL",
"author": ["Lavender9999"],
"description": "Make your Polychromes even more queer!",
"prefix": "pl",
"main_file": "us_en.lua",
"priority": 0,
"badge_colour": "80608a",
"badge_text_colour": "FFFFFF",
"version": "1.0.0",
"dependencies": [],
}

wind steppe
fleet thorn
#

I assume you mean how my folder is set up? This is what I have, I looked through this chat and this is how I read to do it.

fleet thorn
#

That would do it, yeah--

wind steppe
#

Should be polylatro.lua

fleet thorn
#

even if that lua is just a replacement localization file?

wind steppe
#

yes

#

just generally dont set your main file as a localization file

fleet thorn
#

Okay, so, last question; now that my mod works, why is it showing up like this in BMM when the JSON is set up properly to show all it's info?

frosty rampart
#

i can only assume bmm is set up to read the author from a specific field in the mod index, and not the json of the mod itself

#

and therefore all local mods will just say "By: Unknown" because they aren't in the mod index

fleet thorn
#

It's weird, because my DeckSkin mods work perfectly fine... ah well, if the mod works, it works.

crystal perch
#

ok so the event queue gets flooded with events pretty much bricking the game if i have a two-faced try to copy another two-faced
i can only assume that the two-faced on the left tries to copy the ability, which involves debuffing the joker to the right, but the joker to the right is itself, so it gets super confused and floods the queue

#

here's the calc code, any help is greatly appreciated as this is a pretty detrimental bug

calculate = function(self, card, context)
        local other_joker = nil
        local debuff_joker = nil
        for i = 1, #G.jokers.cards do -- Mark Joker to copy and debuff, choose debuffed Joker
            if G.jokers.cards[i] == card then 
                if G.jokers.cards[i - 1] ~= nil then -- Ensure copy Joker exists
                    other_joker = G.jokers.cards[i - 1] 
                end
                if G.jokers.cards[i + 1] ~= nil then -- Ensure debuff Joker exists
                    debuff_joker = G.jokers.cards[i + 1] 
                    debuff_joker.ability.two_faced_chosen = true
                end
            end
        end
        if debuff_joker ~= nil and not (debuff_joker.debuff and debuff_joker.debuffed_by_blind) then -- Debuff chosen Joker if not aready debuffed
            if debuff_joker.ability.two_faced_chosen and debuff_joker:get_seal() ~= "chak_orange_seal"  then
                SMODS.debuff_card(debuff_joker, true, "two-faced")
            end
        end
        for i = 1, #G.jokers.cards do -- Undebuff previously chosen Jokers which aren't currently chosen
            if G.jokers.cards[i].ability.two_faced_chosen and G.jokers.cards[i] ~= debuff_joker then
                if not G.jokers.cards[i].debuffed_by_blind then
                    G.jokers.cards[i].ability.two_faced_chosen = false
                    SMODS.debuff_card(G.jokers.cards[i], false, "two-faced")
                end
            end
        end
        local ret = SMODS.blueprint_effect(card, other_joker, context) -- Copy
        if ret then
            ret.colour = G.C.BLACK
        end
        return ret
    end
daring fern
crystal perch
#

won't that disable other blueprint effects?

daring fern
#

Also why are you not using context.debuff_card?

crystal perch
#

because i didn't know that was a context it's not on the smods wiki calc func page

#

outdated wiki strikes again :/

crystal perch
#

yeah and context.debuff_card debuffs cards too slowly to look good, only at specific times like leaving a blind, so reordering the jokers doesn't have an immediate effect

daring fern
primal robin
#

Does lovely patches doesnt work on localization files?

daring fern
river grail
#

thinking about taking a function from jenlib for my own mod (and editing it) ..is that allowed?
i know mayhem uses jenlib, and has that as a dependancy, but i really only need one function from it for a spectral card i wanna do

primal robin
#

That sucks

#

well ok

river grail
#

the randomize one

#

where it randomizes every card in your deck

crystal perch
#

that's already in the game btw

#

or do you not mean shuffling, but randomizing the card ranks, suits, etc?

river grail
#

nono not shuffling
the card i wanna make is that is randomizes all the suits in your deck

#

jenlib has exactly that, and a bunch of event logic for how it plays out in the game

#

kinda want it to be consistent with other mods that do the same thing

crystal perch
#

check the mod's license and if it allows it then sure

#

or just ask the devs if you want to be sure

#

and always remember to credit!

river grail
#

its jenlib, so idk where to even find the license.. or the mod owner

wind steppe
river grail
#

alrigh

crystal perch
#

so after hooking and doing some code rewritting, i've come across an interesting situation where it no longer debuffs itself (intended?), will debuff other cards (intended), but won't debuff a card if it's being copied (unintended)
i'm 100% sure this is because of the if context.debuff_card then if context.blueprint then return nil but i wouldn't know how to structure it any other way

#
calculate = function(self, card, context)
        local other_joker = nil
        local debuff_joker = nil
        for i = 1, #G.jokers.cards do -- Mark Joker to copy and debuff, choose debuffed Joker
            if G.jokers.cards[i] == card then 
                if G.jokers.cards[i - 1] ~= nil then -- Ensure copy Joker exists
                    other_joker = G.jokers.cards[i - 1] 
                end
                if G.jokers.cards[i + 1] ~= nil and G.jokers.cards[i + 1] ~= card then -- Ensure debuff Joker exists and isn't itself
                    debuff_joker = G.jokers.cards[i + 1] 
                    debuff_joker.ability.two_faced_chosen = true
                end
            end
        end
        if context.debuff_card then
            if context.blueprint then
                return nil
            end
            if debuff_joker ~= nil and not (debuff_joker.debuff and debuff_joker.debuffed_by_blind) then -- Debuff chosen Joker if not aready debuffed
                if debuff_joker.ability.two_faced_chosen and debuff_joker:get_seal() ~= "chak_orange_seal"  then
                    SMODS.debuff_card(debuff_joker, true, "two-faced")
                end
            end
            for i = 1, #G.jokers.cards do -- Undebuff previously chosen Jokers which aren't currently chosen
                if G.jokers.cards[i].ability.two_faced_chosen and G.jokers.cards[i] ~= debuff_joker then
                    if not G.jokers.cards[i].debuffed_by_blind then
                        G.jokers.cards[i].ability.two_faced_chosen = false
                        SMODS.debuff_card(G.jokers.cards[i], false, "two-faced")
                    end
                end
            end
        end
        local ret = SMODS.blueprint_effect(card, other_joker, context) -- Copy
        if ret then
            ret.colour = G.C.BLACK
        end
        return ret
    end
daring fern
#

Also you would check if context.debuff_card is the card you want to debuff.

crystal perch
#

even with that change the problem persists

#

actually i did figure it out with a quick rewrite, if i move the check for the debuffed card to before the context.blueprint check rather than at the step before it gets debuffed, it seems to work as intended

#

thank you for your help

red river
#

how do i check if the player has a certain voucher?

shell timber
#

G.GAME.used_vouchers["v_whatever"]

red river
#

oh, hi. thanks!

azure ember
#

whats the best way to modify every booster pack for, say, tarot cards. because there are lots of pack variants.

cerulean rose
granite jay
#

How do you refer to a joker using SMODS.find_card?

plucky berry
#

you need to put j_ if it's a joker c_if it's a consumable etc

#

SMODS.find_card('j_egg') for example

granite jay
#

No no I mean like

#

If yo uwant to set things to that joker

#

like setting card.ability.extra.active to false

reef belfry
#

how do you force highlight cards until the end of a round when using a consumable even before entering a blind

mystic river
#

though you'll want to handle the case where you don't find the card, or find more than one of it

granite jay
#

yeah that's what I'm trying to do

slim ferry
#

SMODS.Shortcut runs any time the poker hand is calculated, so this definitely won't work how you want it to

stuck ore
#

I'm having issues loading localization info into a modded joker, technically a partner for the partner mod, and I can't seem to have it work it just reads ERROR for the name, I had made it work before without the use of a seperate lua file for the info but I was told if I want the desciption to update I needed to have a file for localizations but despite looking at other mods and trying it for myself I'm just confused

faint yacht
lament agate
#

is it or is it not possible to use dynatext for joker's name

red flower
tall wharf
#

...

#

right this is dev channel

lament agate
#

if i wanted to add a custom localization, how would i do it

obsidian spear
#

like new "language"

#

if you just mean for new text for everything in the game

#

that would be SMODS.language? no?

lament agate
#

localize("k_custom")

obsidian spear
#

you mean the dictionary from misc?

#

when making a localization file theres a bunch of stuff in misc

#

I dunno much but i know that some others that are with me on cold beans have been using it

lament agate
obsidian spear
#

also you dont need no k or j_ and what not, unless thats what your loc has

stuck ore
# faint yacht ?

Btw thanks a bunch for your examples, I ended up figuring out my localization file was named incorrectly (en_US when it should've been default) Finally I am rid of the multi-hour horror of dealing with file names

faint yacht
#

🤝

stuck ore
#

YOURE STILL AWAKE???

#

Alrighty then fair enough

faint yacht
#

😅

#

-# existence.mp4

obsidian spear
#

please oh dear god im tired

loud summit
#

hi so

#

does Game:init_game_object just set the values of G or does it create a whole new G object

#

if you dont set a var to 0 in init_game_object does it carry between runs

slim ferry
#

G has the gameobjects in it set by that afaik (and probably some other values)

#

just use G.GAME to save things to run

dusk compass
#

I need somone who can hack instagram

#

Somone with experience

#

In codding

#

Of that kind

#

You guys know such guy?

winter flower
umbral zodiac
#

dude what

winter flower
#

go ask some hacking reddit not some balatro modders 😭

slim ferry
#

😭

umbral zodiac
#

sir this is a balatro modding chat

slim ferry
#

ts cant be serious

upper quarry
#

no one doing allat 🤣😭

slim ferry
#

sir... this is modding chat... we sell balatro modding here

upper quarry
#

we are lua coders, not anonymous hackers

umbral zodiac
# dusk compass Loool

why are you laughing with us as if you didn’t just ask the most absurd question ever😭 😭 😭

#

what was the thought process here

slim ferry
#

also ignoring that vro wants to hack the entirety of instagram

dusk compass
#

We just need time

#

And the right people

slim ferry
#

brother

#

are we so fr rn

#

what do you think to even get out of this

dusk compass
#

Fame

#

And power

winter flower
#

-# edgelord here holy
you're literally going to get life in prison if you try

#

instagram is a MULTIBILLION dollar company what do you think will happen

slim ferry
#

-1000000000000 social creidt

slim ferry
#

🧠

dusk compass
#

I can do it

#

Trust me

#

I have the skills

#

I learned in the nigerian mountains

#

How to hack using only my mind

slim ferry
#

peak

winter flower
dusk compass
#

My name is Jhoseph Redwood

#

And this will be our story

#

Trust me

#

😭😭😭😭😭

#

I can’t

red flower
#

this might be gilgamesh

winter flower
#

-# you're not him bro

dusk compass
#

Jhon Pork Ahhh

slim ferry
#

ngl

gusty compass
#

what did i step into 😭

#

anyways what is the reason for this lovely (not the Lovely injector) crash report i have no idea the reason of

red flower
gusty compass
#

Apparently it was since loc_vars doesn't like to work in decks 🥀

red flower
#

yes it does

#

according to the log it only receives self it seems

#

which makes sense because the deck doesn't exist in the deck select

gusty compass
#

So it ignores the rest of loc_vars = function(self, info_queue, deck)?

#

Oh wait yea you make a point

red flower
#

yes that's what I'm seeing at least

gusty compass
#

So it would work in game, but not on the deck select?

red flower
#

it's weird that it's not documented tho

red flower
gusty compass
#

I was adding configuration to my additions earlier, happened to want to add loc_vars to show multiInc (being 2 for that deck)

#

My only real option is (deck.effect and deck.effect.config.multigain) or 2

red flower
#

yeah

#

deck and deck.effect

#

if deck never exists then you would need to use G.GAME.selected_back

gusty compass
#

Alr, also for the localisation thingy, decks don't show descriptions when I add a loc key :D

#

Dunno why 🥀

red flower
#

a key in loc_vars?

#

or you mean in the localization file

gusty compass
#

Like key = "j_GG_blahblahblah"

#

In loc_vars

#

I will see later what I can do to change this, since apparently although name works fine, text for decks in a localisation file does not pick up unlike loc_txt

loud summit
#

and if i dont does it carry between rounds

tired kestrel
#

I felt like doing this after making a joker that looks officially vectorized and thought how a joker but in that HD would look for the game:

loud summit
red flower
#

if you mean why thunk did it it makes sense for organization

loud summit
#

oh ok

#

on second thought having a array variable being potentially nil is probably a bad idea

umbral spire
#

how do i add another label

#

like how rarities

#

show the label on the joker

#

can i add another thing like that, next to the name and rarity?

vernal seal
#

Hello again with another problem:
why does the game crash when you try to load the voucher with the custom shader?
do i need to put the prefix of the mod?

vernal seal
granite jay
#

How do you make it so a joker can draw x amount of cards to deck?

umbral spire
granite jay
#

Like if you have 8 cards the joker can draw 10 extra cards to give you 18?

mystic river
#
SMODS.current_mod.calculate = function (self, context)
    --#region Retrigger Jokers that care about 3s (rank) if a 3 (suit) is played
    --TODO: Figure out why Hack sends 'Found effect table with no assigned repetitions during repetition check' message
    local map = {
        j_hack = true,
        j_odd_todd = true,
        j_fibonacci = true,
        j_cry_wee_fib = true,
    }

    if context.retrigger_joker_check then
        local jokerkey = context.other_card and context.other_card.config and context.other_card.config.center and context.other_card.config.center.key or nil
        if map[jokerkey] then
            local count = context.other_context.other_card:is_3()
            if context.other_context.other_card:get_id() == 3 then count = count - 1 end
            if count >= 1 then
                local joker = context.other_card
                return {
                    repetitions = count,
                    message = localize("k_again_ex"),
                    message_card = joker,
                }
            end
        end
    end
    --#endregion
end

why does this result in Hack sending the 'effect table with no assigned repetitions' message? at no point am i returning a table without repetitions, i'm pretty sure?

daring fern
granite jay
mystic river
#

gah, never mind, i just realized it's going to break something unrelated and i shouldn't do it like this to begin with

mystic salmon
#

guys, I genuinely don't understand what's the problem here 😭 (don't mind the contexts of second if, idk how to properly do what I want it to do)