#💻・modding-dev

1 messages · Page 143 of 1

ionic verge
#

fair nuff

#

nothing happens

tender gale
#

everything works currently except for the money decrease variable

#

It shows up as nil in the card description and afaik doesn't reduce the money gained

frosty dock
ionic verge
#

should be newest

#

lemme check

#

i for sure got it after old calc was replaced

#

unless there was an important update within the last 1.5 weeks i dont think its a problem

foggy carbon
#

okay, I know about table.insert(info_queue, but how do I, like, make the thing that's in the queue just a block of text rather than something else's definition?

frosty dock
#

you can put a description in the Other set and just put something like { set = 'Other', key = 'whatever' } into info_queue

ionic verge
#

so should be pretty new

tender gale
#

is there a smods example joker for ice cream or popcorn or something like thay

ionic verge
#

damn

frosty dock
#

I added what I'm using here like 2 or 3 days ago

ionic verge
#

mmm

#

ok ill redownload

#

ok updated

foggy carbon
#

you gotta download using the code button on github

ionic verge
#

and semi good news
its working
but only 1 card is getting destroyed

#

from 3 copies of the guy

foggy carbon
ionic verge
hardy viper
#

(the same)

hardy viper
ionic verge
hardy viper
#

they'll destroy the same thing because the destruction is done after calculation

ionic verge
#

how do i fix that

#

or work around it

#

or whatever

hardy viper
#

add a will_destroy flag to the card and check that before setting highest

#
if context.cardarea == G.hand and context.destroy_card then
  local highest = nil
  for _,v in ipairs(G.hand.cards) do
    if (not highest or v:get_id() > highest:get_id()) and not v.will_destroy then highest = v end
  end
  if context.destroy_card == highest then highest.will_destroy = true return { remove = true } end
end
#

like so

hardy viper
#

huuh

ionic verge
#

copied your code exactly

hardy viper
#

oh wait

#

i see the issue lol

#

uhh what's the most elegant way to solve that

ionic verge
#

i just need one that works

hardy viper
#
if context.cardarea == G.hand and context.destroy_card and not card.ability.extra.has_destroyed_this_hand then
  local highest = nil
  for _,v in ipairs(G.hand.cards) do
    if (not highest or v:get_id() > highest:get_id()) and not v.will_destroy then highest = v end
  end
  if context.destroy_card == highest then highest.will_destroy = true card.ability.extra.has_destroyed_this_hand = true return { remove = true } end
elseif context.joker_main then card.ability.extra.has_destroyed_this_hand = false
end
#

try that

ionic verge
#

when i play a hand

hardy viper
#

oh yeah

#

extra is not automatically created uh

#
if context.cardarea == G.hand and context.destroy_card and not card.ability.has_destroyed_this_hand then
  local highest = nil
  for _,v in ipairs(G.hand.cards) do
    if (not highest or v:get_id() > highest:get_id()) and not v.will_destroy then highest = v end
  end
  if context.destroy_card == highest then highest.will_destroy = true card.ability.has_destroyed_this_hand = true return { remove = true } end
elseif context.joker_main then card.ability.has_destroyed_this_hand = false
end
ionic verge
#

just remove the 'extra's?

hardy viper
#

yea

ionic verge
#

ok it works
beside blueprint/brainstorm

#

im fine with that

proven tide
frosty dock
#

huh

#

doesn't trance support custom fonts

hardy viper
#

no you have to edit the love2d assembly wdym

#

us balatro modders always have ida open on our second monitor!

frosty dock
proven tide
#

Video's broken, hang on a sec. (Worked on a test server.)

gaunt thistle
#

lovely enough indeed

frosty dock
#

no separate tool needed amirite

gaunt thistle
#

it's the moral choice

hardy viper
#

can you support patching the c++ code and recompiling love2d at runtime?

gaunt thistle
#

no

hardy viper
#

it'd be very easy of course..

gaunt thistle
#

c++ is sinful

#

it would be easy

#

c++ is sin and I cannot touch

hardy viper
#

so true

frosty dock
#

c++ uses postfix increment so it evaluates to the same thing as c

#

c++ is a total lie

#

all it does is increment c by 1 and doesn't tell you

gaunt thistle
#

when discord is shut down this is how we'll communicate

frosty dock
#

no we'll use debugplus

crisp coral
#

TRUE

hardy viper
#

communicating by mail

lucid owl
#

what does juice_up do?

crisp coral
#

hop on tk debug console

gaunt thistle
#

when discord and debugplus are shut down this is how we'll communicate

hardy viper
#

or worse steamodded discussions

gaunt thistle
#

imagine not using imgui for a modding tool

proven tide
gaunt thistle
#

smh my head

gaunt thistle
lucid owl
hardy viper
#

is this real...

proven tide
#

Tried Smods.sound, but "ambientFire" works differently.

lucid owl
gaunt thistle
#

no you're not

lucid owl
#

well thank you

hardy viper
proven tide
ionic verge
gaunt thistle
gaunt thistle
#

ah, the @rough furnace method

#

honorable

hardy viper
#

i feel it

ionic verge
#

pushes poker deck off table

gaunt thistle
#

hang on hang on hang on here buddy

#

balatro doesn't have p*ker c*rds, it has playing cards

ionic verge
#

why is cards censored

gaunt thistle
#

because they were p*ker c*ards

weary jungle
#

why is it not recommended to use mp3 files for sounds?

ionic verge
#

i think audio quality

weary jungle
#

how do i make a lovely file with no patches as a placeholder

plain apex
#

is there a way to loop the music while you are in the pack and then turn the music back off once you make your selection?

SMODS.Booster({
    key = 'LTMBooster1',
    atlas = 'Jokers',
    pos = { x = 3, y = 8 },
    loc_txt = {
        name = 'LTM Pack',
        text = {
            'Choose {C:attention}#1#{} of up to',
            '{C:attention}#2#{} {C:purple}LTM{} cards to',
            'be used immediately'
        }
    },
    config = { extra = 3, choose = 1 },
    weight = 1,
    cost = 4,
    group_key = 'LTMConsumableType',
    draw_hand = true,
    unlocked = true,
    discovered = true,
    create_card = function(self, card)
        return create_card("LTMConsumableType", G.pack_cards, nil, nil, true, true, nil, "fn_LTMConsumableType")
    end,
    ease_background_colour = function(self)
        ease_colour(G.C.DYN_UI.MAIN, G.C.SET.LTMConsumableType)
        ease_background_colour({ new_colour = G.C.SET.LTMConsumableType, special_colour = G.C.BLACK, contrast = 2 })
        play_sound("fn_pack")
    end,
    loc_vars = function(self, info_queue, card)
        return { vars = { card.config.center.config.choose, card.ability.extra } }
    end,
})
gaunt thistle
#

you can just define a patch that targets something that doesn't exist

weary jungle
#

because im gonna have patches, but not right not

gaunt thistle
elder vapor
#

no end to close the if context.discard then

weary jungle
weary jungle
#

i cannot load balatro

whole jungle
#

Anyone aware of how to add a new suit to the game without adding it to every deck?

#

The wiki gives a guide to adding suits, which works, but every deck also gets the new suit as well.

cerulean rose
whole jungle
#

Ah, I see, I did not understand that when I saw it initially

#

Thank you

hardy viper
proper stratus
#

dont threaten me i have all the mechanics planned out already

#

(this isnt a joke i have a google doc named balatro sex update)

wintry brook
#

bumping this, atm in my mod you can discard & play cards while the transformation animation plays which is weird

lethal mural
#

is there any way to make an added card guaranteed to have an enhancement

lethal mural
#

where do i put that

stiff locust
#

around the spot where you add the seal

#

value:set_ability(G.P_CENTERS[SMODS.poll_enhancement({guaranteed = true, type_key = 'randomnumbergenerator'})], true, false)
replace value with whatever you use to reference the added card
the type_key field is used for the seed to randomly generate an enhancement

lethal mural
#

so like this?

stiff locust
#

yeah that should work

#

also you can do the same thing for the seal

#

to get a random seal

lethal mural
#

and edition?

stiff locust
#

yeah and edition

lethal mural
#

does edition include negative

stiff locust
#

it can if you want it to

#

you can specify what editions it chooses from

#

and toggle if negative is available

lethal mural
#

yeah i want it to

stiff locust
#

value:set_seal(SMODS.poll_seal({guaranteed = true, type_key = 'randomnumbergenerator'}), true, false)
for seal

#

card:set_edition(poll_edition("randomseed", nil, true, true, {"e_foil", "e_holo","e_polychrome"}))
this edition poll does foil/holo/polychrome and has no negative
i cant remember if its the first or second true that toggles no_neg, but the last argument is an optional argument containing a table with every edition you wanna choose from

lethal mural
#

it didnt add an enhancement to the card huh

stiff locust
#

well why not

lethal mural
#

is G.C.SECONDARY_SET.Enhanced the problem

stiff locust
#

what

#

yeah just make a playing card with no enhancement

#

that'll probably do it

lethal mural
#

do i replace that with nil

#

the G.C.SECONDARY part

stiff locust
#

i don't know

#

never added a playing card before

lethal mural
#

lets see

#

oh hey it worked

#

it deposited a stone card

#

though if its supposed to give "3 Jacks" i probably should remove stone from the pool

#

because yeah its TECHNICALLY still a jack underneath but like

stiff locust
#

i don't know how to do that
when my poll enhancement makes a stone card I just
reroll it until it stops being a stone card

#
while value.config.center_key == "m_stone" do
                            value:set_ability(G.P_CENTERS[SMODS.poll_enhancement({guaranteed = true, type_key = 'randomseed'})], true, false)
                    end

if you wanna do my botched method here you go

#

the indents are off because discord but yk how it works

lethal mural
#

oki

lethal mural
#

like would polychrome be still rare

stiff locust
#

yeah it uses the vanilla weights

lethal mural
#

ok cool

stiff locust
#

you can specify your own weights if you want to

lethal mural
#

ok its still not

#

working

#

it either adds only the edition and seal or only the enhancement

#

wait i have an idea

#

it seems poll_enhancement has an options list like poll_edition

#

i just need to figure out what the names of the enhancements are

vocal verge
#

m_bonus
m_mult
m_gold
m_steel
m_lucky

#

iirc

lethal mural
#

ok ill try that

#

holy hell it worked

vocal verge
#

banger

random sleet
#

oh you know it's good when the error screen is this blue

lethal mural
#

i figured out how to make 3 of them as well damnnn we are on a roll

#

epic for i = 0, 2, 1 do moment

cerulean rose
# lethal mural

if you want to check for enhancements you should use SMODS.has_enhancement

#

although in your case you should probably use SMODS.has_no_rank so it will also catch modded enhancements that remove a card's rank (like ortalab's ore cards)

lethal mural
#

oh i did it like this

#

but i guess that would exclude modded enhancements

cerulean rose
#

if you use a repeat…until loop it should work

lethal mural
#

i uh.. don't know how i'd go about that
i only just figured out how to even add cards not that long ago ,,

wintry brook
#

does lovely have a problem playing too many sounds at once? sometimes my custom sounds arent playing, and sometimes while i have a custom sound playing cards i select dont make any noise

lucid owl
#

how would one destroy a joker? like how jokers such as popcorn are destroyed

cerulean rose
#

copy the code lul

lucid owl
#

yknow what fair

cerulean rose
#

@mellow sable we need a ctrl-v emoji

#

in the cryptid discord

mellow sable
#

lol

#

I'm tempted

#

if you crop it out quickly I can add it right now

cerulean rose
mellow sable
#

👍

lethal mural
#

How do I make it so a joker does not appear in the shop

cerulean rose
#

in_pool

lethal mural
#

so what like in_pool = false?

#

oh wait

#

nvm i think i got it

hardy viper
#

98%

#

it's okay dw

#

but do check the release notes next time

proper stratus
#

yo fellas, quick question

#

this code creates two jokers, i only want it to make one

#

i stole this from riff raff and cant figure out how to make it be just one

cerulean rose
#

change for loop bounds

proper stratus
#

oh?

wintry brook
#

jokers to create needs to be 1 but only if there is space

dusk shoal
#

I TOLD YOU IT WAS THE LOOP

proper stratus
#

anyway

proper stratus
wintry brook
#

tbh you could get rid of the foor loop and just make it check if theres space

proper stratus
#

oh true

#

and i should be able to just check with an if statement right?

wintry brook
#

yup

proper stratus
#

would that just be 'if G.GAME.Joker_buffer < 1 then'

#

how do you check if there's space?

#

like what are the peramaters on the if statement

zenith ridge
#

(Yes I read the FAQ.)

Baby modder with a dumb question, what extension should I be using? Do I just use the LUA one?

(Thank you.)

cerulean rose
#

#G.jokers.cards < #G.jokers.card_limit

proper stratus
#

i love being bad and having to use you guys as a crutch

random sleet
#

no its G.jokers.config.card_limit

#

and you should still respect G.GAME.joker_buffer if you're using an event to spawn the cards, since that's the amount of "reserved" space in the jokers slots

wintry brook
proper stratus
#

yeah, we're making a joker when a thing is discarded

#

still makes two

wintry brook
#

show code

proper stratus
cerulean rose
#

context needs to be more specific

wintry brook
#

context.discard might be happening twice

proper stratus
#

right

cerulean rose
#

what happens if you discard multiple cards?

#

at once

proper stratus
#

does it for all of them

#

two per card discarded

wintry brook
#

i thought the calculate function was in the loc_vars for a sec you gotta clean up that indenting

random sleet
#

i think you want context.pre_discard

proper stratus
#

OK LOOK

dusk shoal
#

you should've seen the like

#

spreadsheet for the mod

#

no capitalization

#

no punctalization

proper stratus
#

THIS ENTIRE PROCESS IS JUST EDUCATED GUESSING OK

dusk shoal
#

it was a mad house

proper stratus
#

IM NOT CODING

#

IM CRYING

dusk shoal
#

youre uneducated guessing

random sleet
#

context.discard is like context.individual for each discarded card, and it happens with context.repetition as well

proper stratus
#

right

ionic verge
#

will this work or do i need to add a .name or something to those contexts?

wintry brook
random sleet
#

these are keys not names

cerulean rose
#

context.card.config.center.key

ionic verge
#

danke

cerulean rose
#

yes, don't check by names

#

it's not standard for modded jokers

ionic verge
#

and those are the keys ive put in right?

cerulean rose
#

yes

ionic verge
#

cool

lethal mural
#

um i tried to make it add a joker and instead its acting like riff-raff and adds 2 random commons

whole jungle
#

lol, that name

cerulean rose
#

what context are you using

lethal mural
#

the one for the beginning of round

ionic verge
#

does anyone know what's with this crash?

#

oh and ideas man wants your thoughts on the joker itself one sec

whole jungle
#

I don't think card is in using_consumeable, it's consumeable

ionic verge
#

ah shit youre right

long sun
# ionic verge

Decent econ — would be just fine in the base game (maybe a little weak) but has very strong synergy with Reverie from my pack

#

(the one that makes Heiro / Temp)

#

Maybe up it to $6, at least?

proper stratus
#

..but it got stuck here when i discarded 5 cards...

wintry brook
#

you need to add return true to the event

cerulean rose
ionic verge
#

oh yeah

#

good point huh

#

i dont need the 'the' in the key though do it?

cerulean rose
#

i mean in the description

ionic verge
#

mhm

#

well its still bugged

proper stratus
#

it works now

#

this is so annoying, there are so many things that i simply dont know of that balatro adds to itself

#

like all the G.whatevers

random sleet
#

welcome aboard

proper stratus
#

ah

#

i see

#

also like, again

#

i've made two sigils, but i havent been coding

#

what im doing isnt coding

#

its stealing and educated guessing

#

then begging people here to help

random sleet
#

welcome aboard

tight thistle
#

hello! im trying to make this joker work and it almost does, but i have a couple issues with it

the joker is supposed to have the effect
+15 Mult, -3 Mult per face card scored

however, the mult reduction doesnt work if the hand contains only one of each face card, and the description of the joker is also not static like i would like it to be

#

can anyone see the issue here? im stumped

proper stratus
#

like- ill be getting mauled by a bear, and i try looking for sticks and stones and whatever to help with this bear, and after hours of trying to deal with this bear i go to a bear expert and she tells me that if i stand on my hands and whistle the bear runs away.
thats what this feels like

proper stratus
#

this is wonderful

cerulean rose
#

appears in meme packs

gaunt thistle
#

doot

random sleet
#

hi lovelyman

proper stratus
#

welp, that's 2/95

lethal mural
#

ok so i managed to make it create 1 joker but it

#

creates a random common?

#

instead of the joker i set it to be?

#

also yeah code is based on the popsicle stick code from paperback lmao (at least this part)

wintry brook
cerulean rose
#

you didn't set it to be a specific joker what the heck are you talking about?

lethal mural
#

i didnt?

cerulean rose
lethal mural
#

huh hh

#

damn i might be stupid then

cerulean rose
#

no im the idiot

lethal mural
#

o

cerulean rose
#

maybe the wrong amount of nils?

wintry brook
#

isnt the key on the right the random key

cerulean rose
#

you should use SMODS.add_card tho

lethal mural
#

how do i convert it to smods.add_card

tight thistle
#

and just told me what im doing wrong

placid frigate
#

for a challenge if I want all jokers restricted do I need to manualy type in restrictions = { banned_cards = {

#

and then all jokers ids?

lethal mural
wintry brook
#

yea it needs a seed key to randomize with, its not actually setting the joker

cerulean rose
tight thistle
cerulean rose
placid frigate
tight thistle
placid frigate
#

and then add my joker's ID to jokers = { {id =

cerulean rose
#

wdym?

cerulean rose
#

check the code for other scaling jokers

placid frigate
# cerulean rose wdym?

basically I want to make a challenge where you try to beat the game with 1 modded Joker and not have access to another ones

wintry brook
placid frigate
#

awesome thanks

cerulean rose
#

also if other mods add face card ranks

tight thistle
cerulean rose
#

card.ability.extra.mult = card.ability.extra.mult - card.ability.extra.mult_minus

lethal mural
tight thistle
#

sorry, a friend was trying to help me and we did a lot of back and forth with editing the code so some of it might have gotten lost between us

lethal mural
#

even with the j_ added it did that

cerulean rose
#

u also have a name conflict

placid frigate
#

does the key need to be the same as my Joker?

lethal mural
cerulean rose
#

local card conflicts with calculate's parameter card

lethal mural
#

o

#

ok lets see if that fixes it

cerulean rose
placid frigate
#

on the wiki?

cerulean rose
#

ye

lethal mural
#

STILL CRASHING

#

oh

#

wait

#

forgot to change a couple

cerulean rose
#

use SMODS.add_card, not SMODS.create_card

#

it handles all of the initialization and placement

#

also if specifying a key directly then set and cardarea are optional

lethal mural
#

oh my GOD still with the center nil value

wintry brook
#

j_modprefix_jokername

lethal mural
#

OH

#

I FORGOT THE PREFIX

#

nope still crashing

cerulean rose
#

also don't set joker buffer to 0 after

#

just decrease it by 1

lethal mural
#

OH

#

ok nvm restarting it now it suddenly works

#

odd

cerulean rose
#

yeah remember to restart your game when changing stuff

lethal mural
#

no like

cerulean rose
#

start a new run when changing your config

lethal mural
#

i did lo

#

i mustve just not saved it i guess

#

now its working

cerulean rose
#

💀

lethal mural
#

that took WAY longer than it shouldve but at least this joker is now completed

#

jackpot gives 3 jacks, then the jacks are not there anymore so it becomes a normal pot

#

the funny

#

i have only one sprited joker left to implement and then the initial 10 will be done

tight thistle
wintry brook
#
            if context.other_card:get_id() == 11 or context.other_card:get_id() == 12 or context.other_card:get_id() == 13 then
                new_minus = 3 + card.ability.extra.minus_mult
            end
        end```
you make a variable called scored_card for tracking all the scored cards but when checking if the card is a face you use  context.other_card
#

i also think you should do this loop in context.before otherwise it might run multiple times

zenith ridge
#

Where are the descriptions for the jokers stored?

wintry brook
#

localization

zenith ridge
#

Thank you. I don't know why I didn't think to check that one.

ionic verge
#

is there a way for a joker to fetch the sell value of another joker?

cerulean rose
#

yup

#

check swashbuckler

ionic verge
#

mhm

#

also cant i just fetch its cost by doing [joker].cost?

random sleet
#

maybe

#

check swashbuckler

tight thistle
wintry brook
#

i think the whole calculate function could just be this

if context.joker_main then
    card.ability.extra.mult = 15
    for k, v in ipairs(context.scoring_hand) do
        if v:is_face() then
            card.ability.extra.mult = card.ability.extra.mult - card.ability.extra.minus_mult
        end
    end

    return {
        mult_mod = card.ability.extra.mult,
        message = localize { type = 'variable', key = 'a_mult', vars = { card.ability.extra.mult } }
    }
    
end
#

set it to 15, loop through the scoring hand, remove minus_mult from the mult every time theres a face, then return the mult

placid frigate
#

how do I get a deck to be just hearts cards

cerulean rose
#

the return should just be return { mult = card.ability.extra.mult }

placid frigate
#

in a challenge

cerulean rose
wintry brook
placid frigate
cerulean rose
#

also cryptid already has single-suit decks

#

look at the game's source code

#

extract balatro.exe as a zip

weary jungle
#

how do i play sounds

wintry brook
#

play_sound("modprefix_soundkey")

ionic verge
#

how would i get a joker to increase its sell value? im not sure how to do it from egg's code

wintry brook
weary jungle
#

how do i stop the background music

weary jungle
#

this is such a dumb idea 😭

weary jungle
tight thistle
weary jungle
#

is there a function to stop the bacground music?

cerulean rose
#

if u wanna replace the background music check out jimball from cryptid

weary jungle
#

how do i know when a sound stops?

zenith ridge
hardy viper
weary jungle
#

how do i get an accurate time then

#

to time the sound

leaden wren
#

is pseudorandom the same when called in the same step? like, two times in the same if statement chain

weary jungle
#

i dont think so

#

it it needs to be the same, just store the random in a variable before hand

leaden wren
#

yep, that's what i assumed

weary jungle
#

why is this saying assertation failed

ionic verge
#

trying to get a joker gain half the sell value of every other joker at end of round (like a combo of egg and swashbuckler), but it crashes when thats supposed to calculate, any thoughts?

#

highlighted is line 781

leaden wren
#

...huh.

weary jungle
leaden wren
#

instead of a period?

ionic verge
#

yes

leaden wren
#

noted

ionic verge
#

copypasted from egg code

leaden wren
#

ah

cerulean rose
leaden wren
#

noted

#

need to remember to stick to that

wintry solar
ionic verge
#

yep, that worked!

cerulean rose
#

also is it supposed to ignore all jokers of its type

weary jungle
ionic verge
#

also: testing environment bc funny

ionic verge
cerulean rose
#

ok, just wanted to make sure that's intended

#

can still scale quadratically with egg

#

two of them would make it scale exponentially

ionic verge
#

oh

#

mb math was wrong

#

im fine with it scaling with egg and gift

leaden wren
#

oh wait
is there no context for each ante?
shit

cerulean rose
#

hm?

leaden wren
#

i want to have an effect reset on each ante
but i ctrl f'ed basegame jokers to find any, nothing
and there's none on the joker calculation page

cerulean rose
#

campfire

leaden wren
#

different terminology

cerulean rose
#

literally only affects crimson heart lol

leaden wren
#

oh yeah, what's the common way to make a sound only play as a thing is happening
e.g. an animation

#

it seems like events?

cerulean rose
leaden wren
#

okay it is events
now to learn how those work

cerulean rose
ionic verge
#

presuming my mod's prefix is deal and comed is the key of the joker in question, this is the right way to check if its not that joker right?

leaden wren
ionic verge
#

cus as of right now i think comedy gold is scaling off of itself

leaden wren
#

thankfully outside of like one bug this joker is (kinda?) working and isn't crashing at all
unlike before
so yay!

ionic verge
#

thanks

weary jungle
#

how do i wait for a specified amount of time?

leaden wren
#

okay so functions are just a structured way to tell the game to process these at the same time when it's able instead of immediately

#

ic

weary jungle
#

is it delay?

cerulean rose
#

yeah

#

although be aware delay is scaled by game speed

weary jungle
#

how do i make it not scaled

cerulean rose
#

idk

wintry brook
#

You can probably multiply the delay by the game speed

#

But seems weird

ionic verge
leaden wren
#

damn case sensitive values keep fucking me up...

tight thistle
#

it should always say "+15 Mult"

leaden wren
#

that's just what you're defining in loc_txt, no

#

it's pointing to a variable that's changing

#

redefine it to point to one that isn't

sick sparrow
#

the shaders are doing the funny with faced stone cards

tight thistle
leaden wren
#

(fwiw at that point you could just write the number in the description itself, but regardless)

tight thistle
#

true! but this works too

#

shit, thats it then! this is my first fully functional joker

#

feels good

cerulean rose
leaden wren
#

hmm, having trouble understanding why this isn't working...
it's SUPPOSED to

  • hit joker eval phase
  • do the event (it is)
  • change the value (it is)
  • play the sound (it is)
  • return the message (it isn't, i'm guessing i have to do it with a different function instead of trying to return it here)
  • return Xmult AFTER all of that (it's not giving any xmult at all, no matter what)
#

okay
first issue gone

#

i think, anyway

cerulean rose
#

use SMODS.calculate_effect instead

#

reversed parameter order, and for bettercalc

leaden wren
#

no wiki entries
Man.....

cerulean rose
#

yeah bettercalc still isn't well documented

#

also return xmult instead of Xmult_mod

leaden wren
#

just did yep

sturdy compass
sick sparrow
leaden wren
#

(he did not return true)

sick sparrow
leaden wren
#

nah it was a separate thing

#

an event happened every frame

#

it also played a sound!

#

it was very funny.

sick sparrow
#

you need to context.after to do that

random sleet
# hardy viper

mr. lovely could i ask that in the release notes the expanded patch targets section mentions explicitly that --dump-all is useful for getting the target field for cross-mod patching? maybe save other people some condescending remarks and such

#

@gaunt thistle bulbaSip

gaunt thistle
#

I figured that

Every encountered buffer can be dumped, not just the ones that have been patched. Alongside each is a text file which contains the internal name of the buffer - use this name in the target field of patches.
would be enough but it's a good request

#

let me write it up real quick

random sleet
#

yeah its just

#

having the information in different sections

#

sorry im just bad at reading ig ;;

sturdy compass
#

Oh shit 0.7 came out? Happy days yaaaaaa

sturdy compass
#

Now to figure out how to patch into Steamodded. That sounds like a tomorrow problem tho lol

leaden wren
#

is the only way to have a delay really just to make an empty event?

#

wacky

random sleet
#

i think there's literally a delay function that does exactly that for you

leaden wren
#

damnit I looked for it and everything

#

even in the smod repo

sturdy compass
#

I believe you can also do delay(time) in the function order lol

leaden wren
#

is it just. delay(

#

yeah

#

okay

#

rip

#

lmao

random sleet
#

i think its just like a love2d engine thing

sturdy compass
#

yeah lol

gaunt thistle
#

I've been trying to do a better job at it with this release

#

anyhow take a peek and lmk if it's a bit better

leaden wren
#

not to mention maintaining documentation is a very, like

#

"oh i know all of these things so i would never think to write down X"

#

the documentation i write is faaaairly different (unreal modding stuff) but it's mostly the same

gaunt thistle
#

it can be difficult to get yourself out of the "I made this so I know everything" and into mindset of a normal user

sturdy compass
#

Making sure people understand how Unreal stuff works is a piece of work in it of itself lol

gaunt thistle
#

I find it's even harder to write good developer documentation though

#

installation guides are easy

#

ish

leaden wren
#

thankfully in my case it's a lot more step by step
so it's hard to miss specific things

gaunt thistle
#

just painful to write

leaden wren
#

nada

#

this kinda thing

#

guilty gear strive modding stuff, basically

gaunt thistle
#

oh wow, this is great

#

it takes talent to write good docs

#

so nice work

#

I've interacted with unreal engine modding a little bit for work

sturdy compass
#

Ooooo Strive modding is sick. I respect that background

gaunt thistle
#

it's really impressive stuff

leaden wren
gaunt thistle
#

ah yeah balatro mods

rough furnace
sturdy compass
#

Neon White mentioned danceman

random sleet
#

yeah i just kept like flipping back and forth between what info i could find on 0.7 but somehow didnt find that it was just like two down on the release notes so

foggy carbon
#

is there a way to know, within loc_vars, where the function is called? I have an idea to push something to info_queue that is a large block of text, and it might be better for the user experience if it only pops up within the collection page and not actual gameplay

gaunt thistle
gaunt thistle
#

I added an additional explanation for that section. eventually this stuff should be moved over to a wiki, but I don't have the energy to do technical writing

rough furnace
gaunt thistle
#

great work mr. smods

leaden wren
#

using it has been completely pleasant

#

and i just host it on a github page

gaunt thistle
#

we use gitbook at work and I've really enjoyed it

#

but mdbook is also a really good option

rough furnace
#

Making a repo for the smods wiki was real nice

gaunt thistle
#

I pretty much just want something I can hook a repo up to and bada boom bada bing it works

random sleet
#

yeah i saw; that should at least be enough to get people on track if that feature's what they're looking for
(i think i just skimmed the --dump-all section because it just said about debugging and im like "well thats not what im trying to do right now i dont even know where to start?")

gaunt thistle
rough furnace
random sleet
#

sorry to be a bother ;;"

gaunt thistle
#

never being a bother

#

I appreciate the feedback

#

lovely docs right now are basically non existent so anything helps

leaden wren
#

text block incoming

leaden wren
#
  calculate = function(self, card, context)
    if context.joker_main then

      if pseudorandom('greenz') < G.GAME.probabilities.normal / card.ability.extra.odds then
        G.E_MANAGER:add_event(Event({
          func = function()
            card.ability.extra.XMult = card.ability.extra.XMult * 2
            play_sound('myo_greenzwin')
            SMODS.calculate_effect {
              message = 'Double!',
              card = card
            }
            card = card
            sendDebugMessage("greenzwin", "myodebug")
            return true
          end
        }))
        else
        G.E_MANAGER:add_event(Event({
          func = function()
            card.ability.extra.XMult = card.ability.extra.XMult / 2
            play_sound('myo_greenzlose')
            SMODS.calculate_effect {
              message = 'Nothing!',
              card = card
            }
            card = card
            sendDebugMessage("greenzlose", "myodebug")
            return true
          end
        }))

      end

      delay(4)
      return {
        xmult = card.ability.extra.XMult
      }
    end

    if context.end_of_round and context.individual and not context.blueprint then
      if G.GAME.blind.boss then
        card.ability.extra.XMult = 1
        card = card
        return {
          message = localize('k_reset'),
          colour = G.C.RED
        }
      end
    end
end
}
#

okay so
i need help with timing

leaden wren
#

the 4s delay in there is for it to test
it seems that if i use calculate function at all it only happens when the delay is done
...which is bad, since i want it to be visible before the XMult appears

#

but i have no idea how to "reorder" these things in the event queue, or something

#

i've heard tell of the context.after
is that the solution?

rough furnace
#

You probably need to dispatc events for what you want to do manually instead of retuning

leaden wren
#

rephrase?
i'm basically banging my head against lua until i learn it here
you're saying i should add another event with a calculate effect to do xmult?

#

instead of leaving it up to the return value

rough furnace
#

Yeah

#

I don't know what the function to do so is called though

leaden wren
#

okay word
that shouuuld fix both things

rough furnace
wintry solar
leaden wren
#

okay i think i get it

#

event to do A and B
->
event with delay = 2 or whatever that has the xmult part in it
don't return anything

#

i'm guessing that separating it into two events will also fix the xmult order problem
hopefully!

wintry solar
#

That’s much more complicated than it needs to be

leaden wren
#

right now the message happens later no matter what and the xmult is always taking the value from before the joker actually plays

wintry solar
#

Do you need the 2 second delay?

leaden wren
#

not literally two seconds, but if there's no delay the two messages happen at the same time (double/nothing & xmult) so it's a bit annoying

wintry solar
#

Gimme a minute to type it up, am on mobile 😭

leaden wren
#

valid!
i don't need actual code, just a lay of the land

sturdy compass
#

Eremel you are a saint dude lol

leaden wren
#

the worst part is making these knowing i want to do so much worse

sturdy compass
#

The horrors

leaden wren
#

ergo, "yeah let's manually redo the entire deck array to topdeck hearts only"

leaden wren
violet void
leaden wren
#

it'd be a Rare for sure
it just fits really well thematically

tender gale
#

Pls, I need help, I'm trying to make a food joker that gives money. Currently the giving money works but I want it to reduce given money by 1 per round, how do I do that?

wintry solar
#
if context.joker_main then
  if pseudorandom(‘keyhere’) < 'do you check here’ then
    — change mult here
    SMODS.calculate_effect({ message = ‘text’, sound = ‘sound key’}, card)
  else
    — change mult here
    SMODS.calculate_effect({ message = ‘text’, sound = ‘sound key’}, card)
  end
  return {
    Xmult = mult here pls
  }
end```
random sleet
#

unironically reorganizing the deck isn't actually that hard if you know what you're doing

long sun
leaden wren
#

and the delay is handled by... calculate effect i assume?

wintry solar
#

It’s in the documentation…

random sleet
#

balatro modders cant read

wintry solar
#

But yes calculate effect will handle all the timings for you

leaden wren
sturdy compass
leaden wren
sturdy compass
#

Cuz smods has wiki

leaden wren
#

*that screenshot is me searching "calculate_effect" in smods

sturdy compass
#

Ah

leaden wren
sturdy compass
#

I never knew you could search like that in github wtf

#

I need to use that lol

leaden wren
#

it's been indispensable

random sleet
#

oh i just use npp locally to search the smods folder lul

leaden wren
#

valid

violet void
rough furnace
#

Ctrl f works for finding on the current page alrradh

#

Especially when in code

wintry solar
violet void
#

Isn't that searching for the whole repo though

wintry solar
#

98%

leaden wren
foggy carbon
# tender gale Pls, I need help, I'm trying to make a food joker that gives money. Currently th...

Add this into the joker's code

calculate = function(self, card, context)
  if context.end_of_round and not context.blueprint and context.cardarea == G.jokers then
    card.ability.extra.money = card.ability.extra.money - card.ability.extra.money_decrease
    if card.ability.extra.money <= 0 then
      G.E_MANAGER:add_event(Event({
        func = function()
        play_sound('tarot1')
        card.T.r = -0.2
        card:juice_up(0.3, 0.4)
        card.states.drag.is = true
        card.children.center.pinch.x = true
        G.E_MANAGER:add_event(Event({trigger = 'after', delay = 0.3, blockable = false,
      func = function()
        G.jokers:remove_card(card)
            card:remove()
            card = nil
            return true
      end
        })) 
        return true
      end
    })) 
    return {
      message = localize('k_eaten_ex'),
      colour = G.C.RED,
      card = card
    }
  else
    return {
      message = '-$1',
      colour = G.C.GOLD,
      card = card
    }
    end
  end
end```

Because the end of round happens before the money is given, you'll probably want to set `card.ability.extra.money` at one higher than you want the first payout to be.
tender gale
#

thanks!

wintry brook
leaden wren
sturdy compass
violet void
leaden wren
#

ANYWAY
calculate_effect was my savior
i think this finally works?

sturdy compass
leaden wren
#

my boy is finally alive
now for card art!

rough furnace
#

Someone forgot a {C:inactive}

gaunt thistle
sturdy compass
violet void
wintry brook
leaden wren
# gaunt thistle I'm an artist I can make you art

i have three thoughts about this message

  • why is the developer of lovely offering me art
  • i'm doing my own already, don't worry lol
  • i can't tell if this is serious or some MS Paint tomfoolery is about to be thrown at me
sturdy compass
tender gale
gaunt thistle
#

I gochu homie

leaden wren
#

oh of course of course

sturdy compass
#

Banger

leaden wren
#

i've always wanted to seriously Do pixel art so this is a good opportunity

rough furnace
leaden wren
#

message preview plugin coming in clutch

sturdy compass
#

Woaw so talented

foggy carbon
gaunt thistle
leaden wren
#

i assume X:mult doesn't support spaces?

leaden wren
#

frog coded...

tender gale
foggy carbon
#

I updated the original message

wintry solar
wintry brook
#

ive scowered most of the relevant source files but still just cant find where they actually hide the card ui, shit is black magic

gaunt thistle
sturdy compass
#

Ikr?

leaden wren
#

i was too vulgar

sturdy compass
#

Don’t look now muuyo, ethan lovely is stealing your oc

leaden wren
sturdy compass
#

I have become god, destroyer of checkered deck (or any deck really)

rough furnace
#

Debuff <suit> blind

leaden wren
sturdy compass
#

Surely it’ll just get Jerma to play Balatro then clueful

tender gale
#

idk why something about it just doesn't want to work

sturdy compass
tender gale
#

every time I've tested it it doesn't trigger the reduction

leaden wren
#

two jokers !!DONE!!
now to sleep and then either hurt myself sorting arrays or do something simple in the morning

sturdy compass
#

I’m excited to finally finish the implementation of one of my earliest Jokers in the morning since I can patch Steamodded thru Lovely now yaaaaaa

wintry brook
#

i just dont know what id pass through args

zenith ridge
#

I'm sure this has been asked before but what source file has the actual functional joker effects? Trying to reference one.

faint yacht
#

Vanilla? card.lua.

wintry solar
zenith ridge
gaunt thistle
#

you're probs one of the first people to use the expanded patch target system

wintry brook
wintry solar
#

I had a patch that needed to target smods but I don’t remember what it was now 🤣

cerulean rose
foggy carbon
#

didn't make any jokers today but I did convert the remaining three jokers to the new format, and gave them bestiary entries

wintry brook
zenith ridge
#

I'm struggling to figure out how to make a retrigger effect that activates on more than one rank of card, in the style of Hack.

violet void
#

Would you guys say this is basically that hieroglyph voucher
-# Although I guess it "freezes" the ante and has no downsides

wintry brook
#

so the ante goes up by 1 after 2 boss blinds?

violet void
#

Only once, yes

wintry brook
#

its worded as if the ante increases an additional time after 2 boss blinds

#

+3 ante after 2 bosses

violet void
#

hmmm

#

would an "instead" fix it

wintry brook
#

maybe Ante doesnt increase for the next boss blind would work

faint yacht
#

"Prevents Ante from going up after beating a Boss Blind once. self-destructs."

wintry brook
#

that sounds better

violet void
#

Also is rare too much

#

its probably niche

wintry brook
#

rare feels like too much, uncommon feels like too little

#

but probably leaning more towards uncommon

#

since it is a joker slot being taken up

violet void
#

It takes a slot for a short time though

wintry brook
#

its kinda hard to take it late game since you probably have your jokers filled at that point

#

which i think balances it like heiroglyph

violet void
#

During late game it would prob be useless since its use would be to help scaling other jokers

#

Better

long sun
#

why doesn't the Xmult happen when i play an Ace of Spades?

if context.individual and context.cardarea == G.play and context.other_card:get_id() == 14 and context.other_card:is_suit("Spades") then
      return {
        message = localize { type = 'variable', key = 'a_xmult', vars = { card.ability.extra.xmult } },
        Xmult_mod = card.ability.extra.xmult,
        colour = G.C.RED,
        card = card
      }
    end```
violet void
#

x_mult_mod perchance

long sun
#

no, this works with my other jokers

long sun
#
SMODS.Joker {
  key = 'eyeofprovidence',
  loc_txt = {
    name = 'Eye of Providence',
    text = {
     "Each played",
     "{C:attention}Ace of Spades{} gives",
     "{C:white,X:mult}X#1#{} Mult when scored{}"
    }
  },
  config = { extra = { xmult = 1.5 } },
  rarity = 3,
  atlas = 'Phanta',
  pos = { x = 1, y = 5 },
  cost = 8,
  loc_vars = function(self, info_queue, card)
    return { vars = { card.ability.extra.xmult } }
  end,
  blueprint_compat = true,
  calculate = function(self, card, context)
    if context.individual and context.cardarea == G.play and context.other_card:get_id() == 14 and context.other_card:is_suit("Spades") then
      return {
        message = localize { type = 'variable', key = 'a_xmult', vars = { card.ability.extra.xmult } },
        Xmult_mod = card.ability.extra.xmult,
        colour = G.C.RED,
        card = card
      }
    end
  end
}```
violet void
#

Mm I dont see anything wrong, try doing some prints

#

Altho this is for example Bloodstone and it uses x_mult

wintry brook
#

you dont need to return the message, and im pretty sure its 'x_mult'

long sun
#

weird

#

hmm

#

maybe Xmult_mod is for individual joker activations?

#

ah yeah, bingo

#

cheers!

violet void
#

Its probably for joker_main activation

wintry solar
#

Just use better calc and don’t worry about all this specific key crap

long sun
#

fewer dependencies is better imo

wintry solar
#

You’re just developing on an old smods version, it’s not a separate mod

long sun
#

ah

runic pecan
#

Is "Played cards that did not score will be destroyed." doable? Part of my memories keeps telling me that context.destroying_card only iters through scored cards but I'm not entirely sure about that.

long sun
#

i'm positive you can get unscored cards, and pass that info into an event that destroys them

#

that's a very op ability :D

#

even Trading card, which only allows 1 destruction per round, is great at deck fixing

runic pecan
long sun
#

it feels like a Rare either way

#

i like both options!

zenith ridge
#

How do I get my joker to trigger on specific cards without crashing Balatro immidiately? Everything else is going swimmingly.

#

context.other_card:get_id() == 9

Did not do the trick.

long sun
#

can i see the rest of your code?

zenith ridge
long sun
#

that's okay!

#

i don't mind it being "bad" by anyone's standards, i care about it working :>

long sun
#

destroying up to five cards per round is already really good

zenith ridge
#

I was watching a tutorial on YouTube by "artmuncher" and it was helpful, but it's kind of limited.

zenith ridge
faint yacht
#

It'd be best to just send it here, otherwise, the potential help may be limited.

zenith ridge
#

I don't even know how to do the codeblock thing in Discord. Does it work if I just copy paste it?

faint yacht
#

```lua
code

zenith ridge
#
    key = 'Jokers',
    path = 'Jokers.png',
    px = 71,
    py = 95,
}

SMODS.Joker{
    key = 'joker2',
    loc_txt = {
        name = 'Placeholder',
        text = {
            'Retrigger',
            'each played',
            '{C:attention}6{} or {C:attention}9{}',
        }
    },
    atlas = 'Jokers',
    pos = {x = 0, y = 0},
    config = { 
        extra = {
        
        }
    }   ,

    calculate = function(self,card,context)
        if 
            context.other_card:get_id() == 6 or
            context.other_card:get_id() == 9 then
                return{
                    message = localize('k_again_ex'),
                    repetitions = 1,
                    card = self
                }
        end

    end,

}

Okay, I finally got it.

faint yacht
long sun
#

ya that :D

#

sorry, was getting food :>

#

for your text:

text = {
            'Retrigger',
            'each played',
            '{C:attention}6{} or {C:attention}9{}',
        }```
#

i'd change it to:

text = {
            'Retrigger each played {C:attention}6{} and {C:attention}9{}'
        }```
zenith ridge
#

Yeah, that would look a lot better. That's an artifact of following Hack a little too closely.

long sun
#

all good :D

minor magnet
zenith ridge
zenith ridge
minor magnet
runic pecan
#

Is it OK to use wordings other than "destroyed" to mean a card will be destroyed?

zenith ridge
minor magnet
#

it seems understandable

#

maybe add a footnote saying (Archived cards are destroyed)

#

or something of the sort

tight thistle
#

my first fully functional joker!

runic pecan
minor magnet
#

LOL

minor magnet
tight thistle
#

yeah! im gonna make a lot more limbus-related cards

minor magnet
#

so cool ill surely play the mod when you release it

tight thistle
#

yay! :>

zenith ridge
#

Well, it's not crashing anymore, but it's not retriggering either.

#

It's just, inert.

minor magnet
#

what's the context for when a joker is sold?

#

like not the specific joker, thats context.selling_self

#

i mean like a joker in general

#

context.selling_card is for any type of card, i want to restrict it to only jokers

long sun
#

if context.selling_card and context.card.config.center.set == "Joker" then

minor magnet
#

perfect

zenith ridge
#
    key = 'Jokers',
    path = 'Jokers.png',
    px = 71,
    py = 95,
}

SMODS.Joker{
    key = 'joker2',
    loc_txt = {
        name = 'Nice',
        text = {
            'Retrigger each played {C:attention}6{} and {C:attention}9{}',
        }
    },
    atlas = 'Jokers',
    pos = {x = 0, y = 0},
    rarity = 2,
    cost = 6,
    blueprint_compat = true,

    loc_vars = {self.ability.extra+1},

    calculate = function(self,card,context)
        if context.individul and (
            context.other_card:get_id() == 6 or
            context.other_card:get_id() == 9) then
                return{
                    message = localize('k_again_ex'),
                    repetitions = self.ability.extra,
                    card = self
                }
        end

    end,

}

attempt to index global 'self' [a nil value]

minor magnet
faint yacht
#

card = card

minor magnet
faint yacht
#

self.ability.extra > card.ability.extra.repetitions

config = { extra = { repetitions = 1 } } too.

violet void
frosty dock
#

but you don't have vars in your description anyway

zenith ridge
#

Thanks. I'll try that tomorrow.

dreamy thunder
#

how would i get these all to be able to trigger at the same time like the lucky card? right now it wont go past the first one

faint yacht
#

...define a blank table and "add" effects to the table that you return after all of that?

zenith ridge
frosty dock
# dreamy thunder how?

local effect = {}
if condition1 then effect.x_mult = card.ability.extra.xmult end
...
...
return effect

dreamy thunder
#

thanks

#

i'll try

violet void
runic pecan
minor magnet
#

im torn too

#

on one hand it can be really strong

#

on the other it does occupy a joker slot, which a voucher does not

#

maybe rare is better?

violet void
#

It also costs 3 dollars less

long sun
#

Rare. maybe Legendary.

minor magnet
#

legendary is way too much

long sun
#

no but the ability to effectively halve the blind's requirements is insane

#

it's like a Heiroglyph, but with no downsides (other than the slot taken) and also a -1 rounds required to win

violet void
#

I dont think its a -1 rounds required to win, you still need to beat 8 antes

minor magnet
#

what? it just works like hieroglyph, i dont see where you've got the -1 round from

runic pecan
#

For some reason discarded face cards did not get removed by this joker.
Can anyone help?

minor magnet
#

crash occurs after the joker gets destroyed by dagger

candid epoch
tender gale
#

I actually did it

#

He works

runic pecan
#

How do I get black background in {X:}?

minor magnet
#

{X:black} i think

#

remember to also {C:white}

#

or your text will not be readable

#

so it would be like {X:black,C:white}

#

is this balanced as is?

#

it does make infinite money

#

but its also a malus because getting rid of it is extremely hard

#

it also gives utility to dagger to kill it

tender gale
#

should be like once per round or something

minor magnet
#

well you do make one dollar at a time

#

and you lose the ability to sell jokers for slots

tender gale
#

well maybe have a cap on the number of times it can trigger

#

like 50 or something

minor magnet
#

that would go against the point of it being unkillable

#

maybe after 50 times sold the sell value goes to zero

tender gale
#

well ok, is this mod supposed to be vanilla balanced?

minor magnet
#

mostly yea

#

losing the ability to sell jokers to free up space to make exactly one dollar at a time is strong but not really game breaking i think

#

at a certain point you deserve everything you get if you have the patience to sell a joker 100 times

tender gale
#

You have to balance an effect like that between being too good or unusably bad

#

which is why these effects only appear in mods

minor magnet
#

originally it had 0 cost and sell value and x1.25 mult

#

would that be better?

#

actually this with campfire would go silly

tender gale
#

Yeah, I forgot about campfire

#

In its current state this Joker feels like a cryptid joker

minor magnet
#

it does

#

eh if it doesnt fit ill submit it for cryptid

zealous glen
violet void
#

It's the Joker itself from what I gather

#

took me a second too lol

dreamy thunder
#

but what does the joker do

#

oh

#

it feels a bit unbalanced

cunning quartz
#

Hey, does anyone know of a way to place Enhancement text after bonus chips text? say I have an enhancement that doubles the total chips a card gives and that card has Hiker's 'extra chips'

+2 is base chips
+7 is my enhancement
+5 is hiker

long sun
#

how can i choose a random Tarot, and get both its name and ID?

#

(in case modded Tarots are in the game)

zealous glen
zealous glen
violet void
zealous glen
#

I thought Consequences was a type of Joker

#

But I didn’t realize it was the Joker itself

royal ridge
#

anyone know what generally breaks older patches in lovely 0.7.0

hardy viper
#

well

#

not just patterns and regex

storm kraken
#

how would i make a voucher do something at the end of the round

faint yacht
#

Gotta patch or hook... or wait until Voucher calculations are implemented. Waiting for that too.

storm kraken
#

😭

weary jungle
#

how do i wait for like 3 seconds

zealous glen
#

Beg aure to do it

#

Wait for what

weary jungle
#

like wait for 5 seconds

zealous glen
#

But wait for what

frosty dock
#

actually you should beg

weary jungle
#

i want to space out some statements

frosty dock
#

then I have a reason to procrastinate for longer because I'm making you wait

weary jungle
#

so they happen one after another

hardy viper
weary jungle
#

which one is more acurate

zealous glen
#

You can use delay(3) or add a delay built into the Event

#

Neither

frosty dock
#

note: delay only works if you use events for what you'll do after

hardy viper
zealous glen
#

That’s why I asked

#

For animation timing you need to use Events

weary jungle
#

how do i keep this in sync with the music...

zealous glen
#

I don’t know if you can

weary jungle
#

custom music that plays for like 1 min

zealous glen
#

You can try with delays

storm kraken
zealous glen
#

But this isn’t New Super Mario Bros.

solar eagle
#

is there somewhere i can look for example planet/tarot cards? the documentation is extremely lacking on that :(

#

and my searches have so far brought nothing

zealous glen
#

@frosty dock three people begging

zealous glen
#

Or Bunco

solar eagle
#

ooh right hold on

zealous glen
#

Or Paperback

#

Idk if those have been implemented yet

solar eagle
#

i was looking at the cryptid src but it doesnt do things exactly the same way

#

lemme see

weary jungle
solar eagle
#

i assume set would then be "planet" "tarot" or "spectral"? or capitalized

#

or somethin else

weary jungle
#

im not sure about that

solar eagle
#

lemme experiment then

weary jungle
#

this is for if you have a consumableType

solar eagle
#

my goal is to create two new planet cards for the two new hands i've added, one new tarot card, and one new spectral

#

lemme poke hold on

#

thank yall

weary jungle
#

try set = 'Tarot', 'Planet' or 'Spectral'

solar eagle
#

will do

weary jungle
#

pick one

#

sont put all tree

solar eagle
#

yep

#

im not new to programming i just have very little to go off for this

weary jungle
#

i want to make a card speak every like 5 seconds and end after 1 min so i need some sort of timing or delay

hardy viper
#
config = {
   lasttime = 0
},
update = function(self, card, dt)
 if (love.timer.getTime() - 5) > card.ability.lasttime then
   card.ability.lasttime = love.timer.getTime()
   --every 5 seconds
end
weary jungle
#

this helps alot

#

this gros mitchel will be so dramatic

#

oh

#

i think itd be fine

solar eagle
weary jungle
#

yes

solar eagle
#

perfect ty

weary jungle
#

or en_us

#

you see the vision right

#

this isnt a good way of doing this though'

weary jungle
whole jungle
#

I don't think you can run that loop without lagging

#

You're hijacking the thread to wait

solar eagle
#

guess u gotta learn to multithread if balatro even supports that

weary jungle
#

i just want so pause until some time 😢

whole jungle
#

Hm... why do you want to pause?