#đŸ’»ăƒ»modding-dev

1 messages · Page 166 of 1

normal crest
#

it retriggers the jokers themselves

lucid owl
#

ohh, okay

#

hmm

normal crest
#

in that code snippet i replied to they probably meant to type context.other_card ~= card instead of ==

solar eagle
#

getting the game's current jokers is G.jokers right? or have i misremembered

lucid owl
solar eagle
#

ahhh

normal crest
lucid owl
solar eagle
#

how often is in_pool on blinds called?

opal spade
#

probably after beating the current blind + on blind reroll

#

i dont see why it would ever be called at any other times

shell lagoon
runic pecan
#

bump

solar eagle
# lucid owl `G.jokers.cards`

to access the key of a joker can i just call G.jokers.cards[1].key for example? or is there something else i gotta do

solar eagle
#

i'm attempting to make it so my boss blind only shows up if you have a certain joker

lucid owl
solar eagle
#

lemme try

runic pecan
solar eagle
#

i assume include the mod prefix?

#

so it'd be prefix_jokername

runic pecan
#

j_prefix_jokername

plush cove
#

what's the best guide to figure out how G.game works? (And all the variables associated with it)

shell lagoon
rough furnace
runic pecan
#

I guess the whole game.lua is the best guide out there about G.GAME until further notice.

#

also, bump again

solar eagle
#

how would i mark my mod to depend on talisman along with steamodded?

runic pecan
runic pecan
solar eagle
#

hmm lemme try again, i tried before

#

might have just messed it up

#

yea i guess i just messed it up before, works great now

runic pecan
#

Bump

nocturne garnet
#

negative playing cards are overpowered

plush cove
#

successfully reworked the Bunco joker system to better suit how I plan to develop my mods!

left: Bunco's Rarity system
right: my Rarity system

ionic verge
#

whats the key for the base edition, is it just e_base or something?

#

im trying to make a joker always the normal edition when spawned

spark remnant
#

is it possible to gave two copies of the game, one modded, one modded, both with different save files?

shell lagoon
#

also i made the odds 1 in 0 to see what would happen and... lua does Not care about divide by zero errors

tepid crow
#

You need a copied Balatro folder in the steamapps folder (I call mine BalatroModded) and rename the exe to the same as the folder name

#

that way your saves are completely seperate and cant accidentally touch - it of course does mean steam doesn't automatically sync your game

spark remnant
#

ty, thats perfect

quasi comet
#

im still getting this issue..This is a joker btw, and the add to deck is within the joker's field; it happens regardless of where I place the add_to_deck

tepid crow
#

anyway, question of my own:

what's a good way to make a retrigger joker that's blueprint compat not retrigger itself (easy) or blueprints of itself (hard)?

runic pecan
#

How do I apply vanilla enhancement cards with new sprites?

wintry solar
#

You mean change the sprites of vanilla enhancements?

rose dragon
#

how can i make a consumable card negative?

crisp coral
crisp coral
runic pecan
wintry solar
#

What do you mean by configurable

runic pecan
rose dragon
crisp coral
#

because it's the thunk's way and it's awful

wintry solar
wintry solar
runic pecan
crisp coral
#

what's the best way to save/load a card not in a CardArea (such as in a G.GAME variable)

dire palm
#

I want my joker to create a single random joker at the end of round. So, naturally I copied Riff-Raff's code to use as a base.
But for some reason, it creates as many jokers as there are free slots and I can't figure out how to limit it to only one Joker. Could someone help me please?

violet void
#

you might want to use SMODS.add_card instead (it includes card:add_to_deck)

violet void
dire palm
#

That did the trick. Thank you.

tepid crow
#

only checking other_card.<etc>.key (or whatev the path is) would stop retriggering foil blueprint completely

foggy carbon
#

if scoring hand contains a face card, adds the product of the lowest card in hand from each suit not included in the scoring hand to mult
Does this make sense or should I reword it?

#

The idea is, based on this hand, the joker would give +28 mult. 2x2x7, the 6 is ignored because it's the same suit as the played king

maiden phoenix
#

It somewhat makes sense after reading it 3 times with the pic

stray wing
#

If I use take_ownership, am I not able to assign "config" to an existing joker? My code looks like this

    "j_greedy_joker",
    {
        loc_txt = {
            name = "new joker",
            text = {
                "Gain 100 chips on the first hand",
                "of a round but lose 50 for subsequent",
                "hands"
            }
        },
        atlas = "Jokers",
        pos = {x = 0, y = 0},
        config = {extra = {chips = 100}},
        cost = 2,
        calculate = function(self, card, context)
            if context.joker_main then
                return {
                    chip_mod = card.ability.extra.chips,
                    message = localize {type = "variable", key = "a_chips", vars = {card.ability.extra.chips}}
                }
            end
        end
    }
)

(I know it doesn't do what the text says right now)

#

that code crashes the game, but it runs if I hard encode the 100 value in the calculate function

wintry solar
#

missing a comma

#

end of config line

stray wing
#

oh sorry, that is from me editing the code on discord

#

I have it commented out in my current code

#

let me just triple check it still crashes with comma

#

yep

#

"functions/misc_functions.lua:1827: attempt to index local 'args' (a nil value)"

wintry solar
#

spawned a new copy?

stray wing
#

what do you mean?

#

It crashes when I check the collection, but I imagine it would also crash encountering the joker in a game (I can check that quickly)

wintry solar
#

you cant use an existing save

#

the collection is because you havent given it loc vars

stray wing
#

okay, it also crashes if encountered in the shop

#

I will add loc vars in, something like this right? loc_vars = function(self, info_queue, card) return { vars = { card.ability.extra.chips, card.ability.extra.chip_gain } }

#

(plus the "end")

#

same crash

wintry solar
#

send the crash

stray wing
#

I know I'm in a very strange corner case (modding existing jokers so that I can use a set seed and have them show up where I want)

fallen pelican
fallen pelican
#

this is my attempt but it's more or less just shuffling words around

#

nah hold on... your description doesn't specify the exclude played cards' suits part

foggy carbon
stray wing
#

could maybe say "unscored suit"? So something like "... add the product of the lower ranks of each unscored suit held in hand to mult"

foggy carbon
#

hmm

fallen pelican
#

from each non-scoring suit

#

I think

foggy carbon
#

that sounds more consistent with Balatro phrasing

runic pecan
#

When I use take_ownership, do I have to re-define everything or just the variables I want to change?

stray wing
worthy stirrup
#

game seems to now just crash if i just click at the start up animation

#

im not sure if its a mod because ive not added any mods recently

stray wing
#

though there's not usually likely to be a point in only taking ownership and changing nothing*

* except for weird seeded run stuff

worthy stirrup
crisp coral
#

pov: smallest lobotomycorp asset

violet void
#

whats the quick way to check if a card has any enhancement? seals have card.seal, editions have card.edition but there isnt one for enhancements it seems

crisp coral
#

the card's enhancements is its center

violet void
crisp coral
#

ya

#

prolly

violet void
#

it doesn't

crisp coral
#

you should just check the key instead

wintry solar
#

You can do card.config.center.set ~= ‘Enhanced’

violet void
#

Works, ty

ionic timber
#

how does one get the current score in the round ? (not the blind score, even though I would like to know how to get that aswell) but what the amount the player actually scored so far in the round

crisp coral
#

ugh moveables are so ass

#

i've been trying to offset a Sprite children with a Card major to no avail

#

just having role.draw_major seems to always force the Sprite's position regardless of whether its role is Major or Minor

south folio
#

Right so I'm trying to make Played Face Cards turn into Steel Cards here

    key = 'j_Helvi',
    loc_txt = {
        name = 'Queen(?) Helvi',
        text = {
          'All played {C:attention}face cards{} become',
          '{C:attention}Steel cards{} when scored'
        },
    },
    
    atlas = 'Jokers',
    rarity = 3,
    cost = 3,
    unlocked = true,
    discovered = true,
    blueprint_compat = true,
    eternal_compat = true,
    perishable_compat = true,
    loc_vars = function(self, info_queue, card)
    end,
    pos = {x = 6, y = 0},
    calculate = function(self, card, context)
        if context.before and (context.other_card:get_id() == 11 or context.other_card:get_id() == 12 or context.other_card:get_id() == 13) then
            for _, card in (context.other_card:get_id() == 11 or context.other_card:get_id() == 12 or context.other_card:get_id() == 13)[1] do
                  card_eval_status_text(card, 'extra', nil, nil, nil, {colour = G.C.UI.TEXT_INACTIVE, message = 'STEEL :D'})
                  card:set_enhancements('m_steel')
            end
        end
    end

}```
violet void
#

you can also do context.other_card:is_face()

wind turtle
#

how do I give the player money?

crisp coral
violet void
wind turtle
#

didn't work

south folio
wind turtle
#

is there any other way? like can i edit the global variable (probably horrible but would probably work)

wintry solar
south folio
wintry solar
south folio
#

oh

#

context.individual then?

wintry solar
#

Depends what you’re trying to do

south folio
#

Kinda like Midas Mask but for Steel Cards?

crisp coral
wintry solar
south folio
#

soscoring_hand instead of other_card?

wintry solar
#

Yeah but it’s a table of cards

crisp coral
#

oh yeah howd you do that

main mica
#

soul sprite?

wintry solar
#

Would have to dig out the code, I’ll send it your way later today

crisp coral
#

swag

south folio
#

ok it didn't work

wintry solar
ionic timber
#

oh that would make sense

#

I was stuck on the fact that it was probably named "score" or something

wind turtle
violet void
wind turtle
#

yeah i should probably update smods soonish

wintry solar
#

Do it now

#

Don’t develop on old calc

#

Waste of your own time

foggy carbon
#

If I want my joker to do something if the player has a specific other joker, how would I phrase that in the description?

wintry solar
viral mesa
#

oh no. i’ve gone too deep into this i’ve made a texture pack that makes all cards look like face cards as in they have a picture and they all look like hamilton characters
 not sure if that counts as a mod but umm its cool ive also added sound effects specific to each card

#

i’m keeping this to myself. i’m the only one that wants an alexander hamilton king that sings 3 seconds of my shot when played

#

this was not worth the month it took

viral mesa
#

well you don’t deserve it

rapid trail
#

tf

#

:(

viral mesa
#

i’ll consider it

#

would i even be allowed to release it because it contains copyrighted material?

rapid trail
#

ah that's a fair

#

point

maiden river
#

is there a guide for making booster packs? I've looked at the docs but mine isn't working properly

cerulean rose
#

is it green particles that won't go away?

maiden river
#

yeah

cerulean rose
#

set skip_materialize = true

maiden river
#

thanks

#

lemme try it

#

it worked

south folio
#

Ok I figured out the function part, but it keeps giving me the messege "Steel!" Multiple times when scoring for some reason

        if context.scoring_hand then
            for k, v in ipairs(context.scoring_hand) do
                if v:is_face() then 
                    v:set_ability(G.P_CENTERS.m_steel, nil, true)
                    card_eval_status_text(card, 'extra', nil, nil, nil, {colour = G.C.DARK_EDITION, message = 'Steel!'})
                end
            end
        end
    end```
timid parrot
#

What exactly is new_calc?

grand violet
#

Hey Balapalsâ„ąïž.

I'm back.

~ Egg

runic pecan
#

Guess who just found out it's Two Pair instead of Two Pairs.

broken cliff
#

or do u mean like

#

2-3 times

#

instead of one

south folio
violet void
hardy viper
broken cliff
sullen fern
#

how do i edit the card textures

south folio
violet void
maiden river
#

okay so I got the pack working
but I can't emplace the card into my custom card area
there are probably some shenanigans I need to get up to

south folio
#

it worked!

violet void
maiden river
#

it's a consumable, technically

wintry solar
#

@crisp coral ```toml

Card:draw()

[[patches]]
[patches.pattern]
target = 'card.lua'
pattern = '''G.shared_seals[self.seal]:draw_shader('dissolve', nil, nil, nil, self.children.center)'''
position = 'at'
match_indent = true
payload = '''
if self.ability.floating_away then
self.ability.floating_away = self.ability.floating_away - 0.075
G.shared_seals[self.seal]:draw_shader('dissolve', nil, nil, nil, self.children.center, scale_mod, rotate_mod, self.T.w*-0.38 + 0.3math.cos(self.ability.floating_away), self.ability.floating_away + self.T.h-0.65)
else
if SMODS.Seals[self.seal] and SMODS.Seals[self.seal].balloon then
G.shared_seals[self.seal]:draw_shader('dissolve', nil, nil, nil, self.children.center, nil, nil, self.T.w*-0.38, self.T.h*-0.65)
else
G.shared_seals[self.seal]:draw_shader('dissolve', nil, nil, nil, self.children.center)
end
end
'''```
this is how I moved the sprite

sullen fern
violet void
maiden river
#

well it's in its own set

chilly creek
#

Can I do mods for balatro using my smartphone?

#

Or just switch jokers appearance

chilly creek
#

Oh

#

Sorry

marble flint
#

How can I get an arbitrary modded sticker from a Joker?

broken cliff
violet void
# maiden river well it's in its own set

thats cool, here's a lovely patch I used for my own set and own cardarea

[[patches]]
[patches.pattern]
target = "functions/button_callbacks.lua"
pattern = '''
elseif card.ability.set == 'Booster' then 
'''
position = "before"
payload = '''
elseif card.ability.set == 'Alignment' then 
    card:add_to_deck()
    G.cs_alignments:emplace(card)
    play_sound('card1', 0.8, 0.6)
    play_sound('generic1')
    dont_dissolve = true
    delay_fac = 0.2
'''
match_indent = true```
maiden river
rapid trail
#

hey so maybe stupid question, but I'm trying to figure out how to make a joker create a planet card when any tarot is used

#

if you respond, please piing me in the response as I am bad at checking back

violet void
broken cliff
#

when a tarot card is used

hardy viper
#

there's a context for that iirc

rapid trail
#

do you know the context?

violet void
#

context.using_consumeable

and use context.consumeable.ability.set == "Tarot"

rapid trail
#

the documentation for steamodded is great and all, just very vague and lacking a lot of things

#

tysm!

marble flint
runic pecan
#

Quick question: does a Full House contains a Two Pair?

maiden river
#

yup

runic pecan
#

Then why does spare trousers code need to check both next(context.poker_hands['Two Pair']) and next(context.poker_hands['Full House'])?

broken cliff
#

-- (context.poker_hands['Straight']) checks if the current hand is a 'Straight'.
-- The 'next()' part makes sure it goes over every option in the table, which the table is context.poker_hands.

runic pecan
#

Can I put poker hand type into info_queue?

broken cliff
#

idk what it is xd

#

context.poker_hands contains every valid hand type in a played hand

rapid trail
#

Another question now, how would I create the tarot card 😅

maiden river
#

oh there's a cat pic

#

never noticed that

marble flint
broken cliff
broken cliff
#

this is the snippet of its code, it gets the consumable from ur current ones
local card = copy_card(pseudorandom_element(G.consumeables.cards, pseudoseed('perkeo2')), nil)

                -- Vanilla function, it's (edition, immediate, silent), so this is ({edition = 'e_negative'}, immediate = true, silent = nil)
                card:set_edition('e_negative', true)
                card:add_to_deck()

-- card:emplace puts a card in a cardarea, this one is G.consumeables, but G.jokers works, and custom card areas could also work.
-- I think playing cards use "create_playing_card()" and are separate.
G.consumeables:emplace(card)
return true

broken cliff
#

bcuz full house is technically a two pair too

#

but its not maybe

maiden river
#

I want to add specific jokers to a booster pack
is there a way to do that?

cerulean rose
#

so is flush house

#

which one?

maiden river
#

it's some of my modded ones

wintry solar
#

Show the create card function of your booster

broken cliff
broken cliff
#

so it checks if its two pair or full house

#

bcuz full house contains the two pair

#

thats why

rapid trail
maiden river
# wintry solar Show the create card function of your booster

I haven't written that one yet
but I have this one

SMODS.Booster({
    key = "basic_pack",
    loc_txt = {
        name = "Basic Pack",
        group_name = "Basic Pack",
        text = {
            "Contains 5",
            "Friends Vs. Friends cards",
        }
    },
    config = {
        extra = 5,
        choose = 2
    },
    kind = "Weapon",
    create_card = function(self, card, i)
        return {
            set = "Weapon",
            skip_materialize = true,
        }
    end
})
runic pecan
wintry solar
#

so with create card you can return a card as well, so you can just create your own pool and handle it within the function

broken cliff
#

if u play a full house theres full house, three of a kind, two pair, pair

wintry solar
#

Riv it's just a thunkism, there's redundant stuff all over the palce if you look for it

broken cliff
#

the jokers usually say if the hand CONTAINS the played poker hand for it to trigger

#

the exception is check list or whatever its called

runic pecan
#

So let me ask this one more time:
Why Does Four Of A Kind NOT Contain A Two Pair???

broken cliff
#

afaik

broken cliff
topaz sun
violet void
broken cliff
#

it may be G.c.tarot or smth

sullen fern
wintry solar
broken cliff
#

u can check examples mod deck skin template in smods example mods

runic pecan
topaz sun
#

Does anyone know where the code for when cards are drawn from deck is in the game's source code?

#

I've been looking for it for a quite a while now

broken cliff
#

first letter is suit

#

second is rank

runic pecan
broken cliff
#

oh idk sadly

rapid trail
#

alright, I think I've got it. Wish me luck!

topaz sun
#

Was looking in the wrong file

foggy carbon
#

I had a joker that was changing the Blind:stay_flipped code, so I just did a ctrl+shift+f for that and looked through the results for any that looked promising

broken cliff
#

how do i get the whole mult so i could alter it myself? im making a 3x+1 joker which divides by 2 if its even and multiplied by 3 and adds 1 if its odd and runs till it gets the biggest number from the algorythm

maiden river
#

so how do you make your own pool 😭
I'm clueless

#

I guess it might be SMODS.ObjectType?

cerulean rose
wintry solar
#

if they're equally weighted just use a table

broken cliff
topaz sun
topaz sun
broken cliff
#

peak

topaz sun
#

but you can easily counter that

#

one sec

maiden river
broken cliff
#

all i need is to modify the mult, i have everything else working

foggy carbon
broken cliff
#

Dayum

runic pecan
#

So Full House check is unneeded.

broken cliff
#

While being in Full house

topaz sun
#
  if mult % 2 == 0 then
    return {
      xmult = card.ability.extra.xmult
      mult = card.ability.extra.mult
    }
  else
    return {
      mult = card.ability.extra.badxmult
    }
  end
end```
I think this would work for ya, smell
Edit: xmult is 3, mult is 1, badxmult is 0.5
broken cliff
#

although its different than what i have in mind

foggy carbon
#

nah, they had someone who actually found what mult was at the time the joker calculated, then either multiplied it by 0.5 or 3 depending (they decided +1 was too trivial)

broken cliff
#

it does it once, i run the collatz conjecture to find the biggest number in it

#

i cant see that message

rapid trail
#

My code is below. Sorry, I"m very new to lua and Balatro modding. I keep getting an error saying unexpected symbol near 'if'. It gives line 38 as the offending line, which I marked below.

SMODS.Joker {
  key = 'ethereal_j',
  loc_txt = {
    name = 'Ethereal Joker',
    text = {
      "Each played Planet Card gives",
      "a Tarot Card"
    }
  },
  config = { extra = { money = 1} },
  rarity = 1,
  atlas = 'vopjs',
  pos = {x = 1, y = 0 },
  cost = 6,
  loc_vars = function(self, info_queue, card)
    return { vars = { card.ability.extra.money} }
  end,
  if context.using_consumeable then
    if context.consumeable.ability.set == Planet then ###THIS LINE###
      return {
        local card = copy_card(pseudorandom_element('Tarot', G.consumeables, pseudoseed('ethereal_j')), nil)
        card:add_to_deck()
        G.consumeables:emplace(card)
      }
      end
    end
  end
}
#

Again, please ping me if you answer

broken cliff
#

maybe its that?

edgy reef
#

The if statement is not inside a calculate function.

#

Or a function at all

south folio
#

Ok so

#

what if I want it to have a different effect for a different card?
Like. +1 Chip for J, and +2 Chips for Q

wintry solar
#

You check what the card is

broken cliff
#

for ur purposes, J is 11

#

Q is 12

#

K is 13

#

A is 14 i think?

#

the context to check each card is individual btw

south folio
#

do I set the ranks like, in the configs?

#

not ranks

#

chips

#

amount of chips

wintry solar
#

It would be sensible to, yes

south folio
#

But do I set it up like. this?

      extra = {
        chips = 1,
        chips = 2,
        chips = 3,
        chips = 4
      }```
wintry solar
#

They’d need different names

broken cliff
foggy carbon
#

I've seen some jokers that change their appearance so I know it's possible. I'm assuming that I can just change card.pos mid-game?

wintry solar
#

You need to use card:set_sprite_pos() iirc

south folio
wintry solar
#

You can use whatever names you want in the config

broken cliff
foggy carbon
#

yeah, I've seen people use total and xmult both for the same thing

south folio
#

Oh huh

foggy carbon
#

the name of the variable is only important to the person actually writing the code

broken cliff
#

the path would be smth like this - card.ability.extra.NameOfUrThing

south folio
#

Ohhhhh

broken cliff
#

it has runner, which is based on the mechanics of checking what cards are scored

#

walkie talkie*

#

sorry, I named the jimbos wrong

south folio
#

Oh Wow

#

Yeah thanks for this I really needed that

#

Ok it just doesn't add the chips now

      extra = {
        chips_11 = 1,
        chips_12 = 2,
        chips_13 = 3,
        chips_14 = 4
      }
    },
    loc_vars = function(self,info_queue,center)
        return { vars = { center.ability.extra.chips_11, center.ability.extra.chips_12, center.ability.extra.chips_13, center.ability.extra.chips_14 } }
    end,
    calculate = function(self,card,context)
        if context.individual and context.cardarea == G.play then
            if context.other_card:get_id() == 11 or context.other_card:get_id() == 12 or context.other_card:get_id() == 13 or context.other_card:get_id() == 14 then
                return {
                    chips_11 = card.ability.extra.chips_11,
                    chips_12 = card.ability.extra.chips_12,
                    chips_13 = card.ability.extra.chips_13,
                    chips_14 = card.ability.extra.chips_14,
                    card = context.other_card
                }
            end
        end
    end,
}```
broken cliff
#

bcuz ur supposed to add them to chips = sum of those things

#

and u can also get the id and subtract 10 from it to get the index of ur chips bonus table

#

and return {
chips = card.ability.extra["chips" .. index],
card = context.other_card
}

#

the index approach might work

#

actualyl wait

#

u can js do return {
chips = card.ability.extra["chips_" .. index],
card = context.other_card
} i tihnk

#

no need to change anything

#

since the table will only return if its a face card

wintry solar
#

dude it is so hard to read your code without code blocks

broken cliff
#

eh i understand his code

#

his problem is that he did chips_11 = whatever

#

and not chips = card.ability.extra["chips_"..index] -- the "chips__"..index" is the key to get the value of the table

#

editing mult is Pain

wintry solar
#

not his, yours

broken cliff
#

oh

#

ok wtf
mult is a table that stores OTHER tables

south folio
#

I am new to just. coding in general and it crashed and I am So Lost

#

it is notepad++ yes, I know

broken cliff
#

whats the error message

south folio
wintry solar
broken cliff
#

oh yh

#

index is js the id of the card scored

#

i forgot about that

south folio
#

so like

#

wait what do I do with it

broken cliff
#

u can replace index with context.other_card:getid()

#

or introduce the index to be equal the context.other_card:getid()

south folio
#

uhhhhh

broken cliff
#

Bro im SO CONFUSED WITH HOW THE MULT WORKS

wintry solar
#

just don't use talisman ezpz

broken cliff
#

ITS A TABLE THAT STORES TABLES YET WHEN I TRY TO ITERATE THROUGH ONE

#

IT BECOMES A NUMBER

#

THEN WHEN I DONT DO THAT IT BECOMES A TABLE

rough furnace
#

is this a talisman moment

broken cliff
#

Yes

#

Yes it is

#

its fine ill figure it out

#

or die trying

south folio
#
                    chips = card.ability.extra["chips_" .. context.other_card:getid()],
                    card = context.other_card
                }```
#

im kinda stupid is this ok

south folio
#

yeah that crashed

broken cliff
#

error screen?

wintry solar
#

should be message_card = card btw

#

wait no

#

you don't need the card arg at all

broken cliff
south folio
broken cliff
#

-- Specifically returning to context.other_card is fine with multiple values in a single return value, chips/mult are different from chip_mod and mult_mod, and automatically come with a message which plays in order of return.

broken cliff
wintry solar
#

I don't care what the example mod says, you don't need the card arg

south folio
broken cliff
#

to get the id of the card u do get_id()

#
                    chips = card.ability.extra["chips_" .. context.other_card:get_id()],
                    card = context.other_card
                }```
rough furnace
wintry solar
#

yeah I will do at some stage, I've also toyed with the idea of just making all the vanilla jokers đŸ€Ł

broken cliff
#

so the mult has 3 things
a table
a signtest 1???
and a numbervalue

#

im so Confused

#

man talisman is peak

topaz sun
#

you gotta use to_number(mult) i think

#

that makes it able to be used in equations and such

broken cliff
#

well mult stores 3 things i dont think u could do that

rough furnace
#

probably disable talsiman's bignum/omeganum for testing stuff

cerulean rose
south folio
topaz sun
urban veldt
#

Eclipse, (Spectral): Destroy all cards in your full deck of a random suit.
Is this doable?

rough furnace
#

you can also stick your regular number into to_big() to compare with talisman numbers

rough furnace
#

(to_big won't exist without talisman, but you can do a to_big = to_big or function(n) return n end)

#

you only need that for comparisons, math works with talsiman numbers and real numbers

topaz sun
#

would it?

cerulean rose
#

yeah

topaz sun
#

dayum

cerulean rose
#

cus lua's number type is a float

rough furnace
wintry solar
#

lets normalise not using talisman instead

rough furnace
#

(see my message litteraly one message down)

broken cliff
cerulean rose
#

*39

rough furnace
#

I've never made it past ante like 12 and also I did make a mod to not be stuck there without talisman

wintry solar
rough furnace
#

but numbers would just be inifnity

rough furnace
#

although you can get talisman to use vanilla number for compat

#

ideally though talisman would be transparent and not matter whter it's installed or not

topaz sun
#

I think the issue is that Balatro itself was never intended to go after ante 38, apparently

rough furnace
#

but as far as I know not possible

rough furnace
#

but you can make future ante's all have infinity requirment and make inf score passable with a few simple lovely patches

topaz sun
#

Personally I just use tali for the absolute sick ass sounds it provides for emult, xchips and stuff like that. Whoever made those is a wizard

broken cliff
#

Call it smth Like Super Joker Extra Pro max

#

If u beat it, it would kill u

#

if u dont u would lose

#

Simple Solution

upper ibex
#

im trying to get it to give 4x mult when a four of clubs is scored

what part of the code did i fuck up

broken cliff
#

Error message

upper ibex
topaz sun
#

no end to the if statement with the return part

#

oh no wait

broken cliff
#

change the context to individual

wintry solar
normal crest
broken cliff
wintry solar
#

it doesnt exist

#

it breaks out before that though

broken cliff
#

talisman comprehension update: the table STORES NOTHING so i think its used for numbers above e308

normal crest
topaz sun
#

I think it's context.other_card:get_id()

wintry solar
#

thats not incorrect

broken cliff
#

so ill js ignore the values

normal crest
#

it's not?

broken cliff
normal crest
#

what does "modifiers to cards" mean

broken cliff
wintry solar
#

^

upper ibex
topaz sun
#

Do you guys know a way to make a button change color when pressed?

normal crest
# wintry solar ^

but then that means the code would be executed and their game would crash cus is_rank doesn't exist, so does it just never happen

broken cliff
#

and check if its 4

wintry solar
normal crest
#

Oh I SEE

#

My bad

wintry solar
#

so the joker's main_scoring is never in the G.play area

#

I can maybe clarify that a bit better on the wiki though

upper ibex
broken cliff
#

if context.other_card:get_id() == 4 then

#

and the individual context

upper ibex
#

so this?

broken cliff
fallen pelican
#

it's bc ur calling a function that exists in context.other_card ig

#

get_id() will be the function that returns the corresponding rank

solar eagle
#

is there anything in this boss blind that's set up wrong?

broken cliff
solar eagle
#

functions/common_events.lua:2689: attempt to compare number with boolean

broken cliff
#

what line?

solar eagle
#

2689

topaz sun
#

it's some lovely patch then

broken cliff
#

i think it has to do with in_pool?

#

since its the only one with boolean in it

#

or boss table

solar eagle
#

yea i just dont know what it would be, since my in_pool is just return true

cerulean rose
#

why do you even have an in_pool?

topaz sun
solar eagle
#

that is the case

#

well, i have my mod, steamodded, talisman (dependency), and debugplus

#

i can try removing debugplus i guess?

broken cliff
#

boss: Marks this Blind as a Boss Blind and specifies on which Antes it can appear ({ min = 1, max = 10 }). max is an artifact and not functional. Use in_pool instead for advanced conditions.

boss.showdown: Marks this Blind as a Final Boss Blind that shows up on every multiple of the winning Ante. min is ignored, use in_pool to restrict spawning.
solar eagle
#

mhm i read the smods.blind page

#

i can try removing in_pool

#

ok this is interesting

#

the problem seems to be that i was returning true, i instead need to return

#

0?

#

that wasnt it

broken cliff
#

what the fuck does it expect from me

#

talisman is Such a Headache

normal crest
#

you are missing a comma after "scaled up!"

broken cliff
#

OHHH

normal crest
#

this isn't really talisman, this is lua syntax

old bane
#

how would i load other files for jokers? i would like to be able to organize jokers into their own files so that I don't just have all of them in the mod lua file (and also so I can have different rarities of jokers that can be turned off in config)

broken cliff
#

yh my fault gang

high stag
#

Talisman still probably is such a headache

#

Just unrelated

solar eagle
broken cliff
#

oh Fuck i struck it hard

solar eagle
#

what i do is i have a folder src, then this section at the top of your main lua file

for _,v in pairs(NFS.getDirectoryItems(path)) do
    assert(SMODS.load_file('src/'..v))()
end```
works great
upper ibex
#

it is still not working.
it doesnt crash but it doesnt give Xmult when a four of clubs is scored

broken cliff
#

its bcuz i put a mult = mult

upper ibex
normal crest
#

what version of steamodded are you using @upper ibex

broken cliff
solar eagle
#

thats what i use

#

works fine

solar eagle
cerulean rose
#

update smods

normal crest
cerulean rose
#

latest is 1406a

normal crest
#

that version is months old!

solar eagle
cerulean rose
#

Xmult_mod was deprecated over a month ago

normal crest
solar eagle
#

didnt work for me

normal crest
#

are you in 1304a too

cerulean rose
#

update steammodded

solar eagle
normal crest
#

then it should work

solar eagle
#

is Xmult_mod going to be flat out removed at any point or is it just not recommended

normal crest
#

No idea if it'll be removed, but it's not even mentioned in the wiki

high stag
#

It's used in the example jokers for steammodded

#

Their Cavendish implementation uses it

solar eagle
#

mhm

old bane
solar eagle
old bane
#

ah gothca

solar eagle
normal crest
solar eagle
#

and then multiple files for each

normal crest
#

I'm just saying you're adding unnecessary work to it by using any _mod

#

do whatever you want tho I guess

high stag
solar eagle
#

does lovely have a way to dump the patched file from memory?

#

i feel like that was mentioned here but i do Not remember it

#

aha found it

broken cliff
#

ok my joker finally works

solar eagle
#

if eligible_bosses[k] > min_use then is the offending line??

broken cliff
#

oh god i think i created a monster

#

this jimbo makes ur mult skyrocket im gonna nerf him LMAO

#

if u put smth like 50 mult it will turn it into 88 mult and if u put 530 it will make it 9k mult

solar eagle
#

ok ive found the issue but i dont understand how its breaking

upper ibex
#

ok so i updated steammodded and it works but wrong

it triggers on all fours and not just four of clubs

solar eagle
#

this for loop is the problem, eligible_bosses[k] on my finisher blind results in true not 0 like the other boss blinds?

normal crest
#

in the code right above it sets eligible_bosses[k] to a number

solar eagle
#

yea im looking now

normal crest
#

are you using save states to test

solar eagle
#

no

normal crest
#

do you have debugplus

solar eagle
#

Yes

normal crest
#

run eval G.GAME.bosses_used

#

do you see yours

solar eagle
#

yeah

#

bl_TWT_final_curse: 0

sullen fern
#

is it easy to make a balatro mod

broken cliff
solar eagle
#

lua isnt too hard to pick up either

broken cliff
#

and then checking the api reference

normal crest
#

other than that i cannot see why your blind wouldn't work

solar eagle
#

it shouldnt be?

#

let me try

#

banned_keys is empty

broken cliff
normal crest
#

maybe it's a glitch in the version of steamodded u are using

solar eagle
#

actually what it could be

#

the run i was testing on i beat the blind on ante 1 to make sure it worked

#

lemme make a new one

#

yeah that was it??

normal crest
#

so you were clicking continue instead of new game

sullen fern
#

how hard is it to say
make a new consumable type

solar eagle
#

interesting bug

normal crest
#

kind of basically a save state

smoky talon
#

im trying to make a joker that adds +1 to the mult for every additional copy of that joker you have. I assume i should use a variable to check how many I have at once (im sure im doing it all wrong lol)

smoky talon
#

just copy this and replace the info with your consumable type's info

#

SMODS.ConsumableType{
key = 'Drugs', --consumable type key

collection_rows = {4,5}, --amount of cards in one page
primary_colour = G.C.PURPLE, --first color
secondary_colour = G.C.DARK_EDITION, --second color
loc_txt = {
    collection = 'Drugs', --name displayed in collection
    name = 'Drugs', --name displayed in badge
    undiscovered = {
        name = 'Hidden Drugs', --undiscovered name
        text = {'Check under', 'the couch'} --undiscovered text
    }
},
shop_rate = 2, --rate in shop out of 100

}

#

theres a text version

#

to copy

#

you also need this

SMODS.UndiscoveredSprite{
key = 'Drugs', --must be the same key as the consumabletype
atlas = 'Jokers',
pos = {x = 0, y = 0}
}

broken cliff
smoky talon
#

yep

#

and 3 would have 3 jokers with 3 mult each

#

its kinda broken lol

broken cliff
#

maybe u could do a global value

smoky talon
#

where in he code woould i puut it

sullen fern
#

i obviously need some sort of jumping off point

broken cliff
#

when the joker is added to deck u can add +1 to the global one

sullen fern
#

so how do i start making a mod

broken cliff
sullen fern
#

i have steammodded and lovely

#

(i have old-calc steamodded)

broken cliff
#

do u know lua?

sullen fern
#

maybe
?

smoky talon
#

im stilll learning lua

sullen fern
broken cliff
#

and check the example mods of steammodded

smoky talon
#

so in the smods.joker section?

broken cliff
#

the joker gets created then the global value gets created

#

then u can add this, which will trigger when u buy/get that joker
add_to_deck = function(self, card, from_debuff)
-- part where u add to that global value
end,

smoky talon
#

i have all that just need the variable

#

ill let you know if it works

sullen fern
#

im gonna hate creating sprites because i have to make a 1x and 2x version of them

broken cliff
#

thats the part of the Pain

#

the other part of the pain is dealing with talisman

smoky talon
#

i put it in here, is this how i declare it?

broken cliff
#

do G.gorb_count ig

#

OH WAIT

#

u forgot to put comma

smoky talon
#

that makes sense

#

ohh

broken cliff
#

after the declaration

smoky talon
#

got it

broken cliff
#

put a comma after 0

solar eagle
#

then export at 50% scale for 1x

high stag
#

I just set the scale to 200% after making the x1 version

smoky talon
#

still no dice

upper ibex
#

i have a problem

so i was able to get the first effect to work with a lovely patch
but i have no idea how to go about coding the second effect
does anyone have any advice

solar eagle
upper ibex
smoky talon
broken cliff
#

i think it might be that

smoky talon
#

its always been that way

wintry solar
solar eagle
#

could honestly just check if debuff.suit exists

smoky talon
#

where doe sthe bracket go?

violet void
#

at the very end

south folio
#

this was so much work for very little effect in the actual scoring

smoky talon
#

if i just do an ending one it closes the rest of the joker code beneath it

#

and a front and back doesnt fix it

broken cliff
#

at the end of the joker

smoky talon
#

that isnt the end of the joker

#

theres more code below

#

with an ending

wintry solar
#

then show the whole code

smoky talon
#

thats whats below

wintry solar
#

oh

solar eagle
#

you have a trailing comma

wintry solar
#

delete that gorb_count line

solar eagle
#

remove the comma from the last end

wintry solar
#

it can't go there

wintry solar
smoky talon
#

where do i put gorb coujnt then

solar eagle
#

lua's that generous

smoky talon
#

it needs to be before the setting blind part i think

solar eagle
#

im used to my programming languages executing me if i have a trailing comma

wintry solar
#

what is the gorb count?

rough furnace
solar eagle
#

none of the ones i learned

broken cliff
wintry solar
#

then it needs to be in add to deck

smoky talon
#

counts how many gorb jokers i have, for each gorbh joker it increases the gorb joker's mult by 1

broken cliff
#

so if thers 2 jokers of same kind then it would be 4 mult(2 per joker)

smoky talon
#

this is the joker that spawns gorb jokers

#

yep

#

i have the thing that adds to it but i need ot declaere it first

sullen fern
#

i like writing mod idea things down in my notes app

violet void
broken cliff
#

1 joker 1 mult
2 joker 4 mult(2 per joker)
3 joker 9 mult(3 per joker)

violet void
#

and something else probably

solar eagle
broken cliff
smoky talon
#

not of itself but of another joker

#

but yes it is possible ive tested it with jimbos

rough furnace
runic pecan
solar eagle
#

i dont use objc nearly as much as swift though because objc is Ass

sullen fern
broken cliff
#

Jimbo-inator

smoky talon
#

if i dont declare it it gives this when setting bling which makes sense

#

i just need to find where to declare the count for the first time

broken cliff
#

maybe declare it at the start of ur mod?

sullen fern
violet void
#

couldnt you put it in card.ability

old bane
#

would i be able to get the last played hand at context.end_of_round

broken cliff
#

u can check how many played hands there were

broken cliff
#

and if only 1 hand remains then do the ability

smoky talon
#

it works but the count isnt incrementing for each additional one and the joker just says xnil

smoky talon
#

prob bc this is what i have for setting the xmult to gorbcount, it prob doesnt work lol

broken cliff
#

or js declared it

smoky talon
#

i delcared it and it stays at 1 even when adding multiple m,ore

#

i put that at the top like u said

sullen fern
#

2.5?

smoky talon
#

so either the gorb count isnt incrementing or the xmult isnt tied to it

#

whats that debug command that lets me check a variable's count again?

broken cliff
broken cliff
smoky talon
broken cliff
#

no as in print(G.gorb_count) in the joker

smoky talon
#

ah

#

gorb count is going up

#

just not linked top mult

#

which is what i predicted

#

so the linking code needs fixing

rough furnace
broken cliff
smoky talon
#

yep that works fine, just need to fix the mult in the gorb joker

#

i just need to find out how to tie the gorb joker xmult to the gorb_counter variable

#

i assumed Xmult = G.gorb_count would work but it didnt

broken cliff
#

shouldnt it just be mult

#

since ur adding +1 mult

#

not x mult

smoky talon
#

ill try that

#

i think xmult means that when scored it would be x3 instead of +3 instead of being tied to incrementing it

#

but i can try it

#

ok i kinda fixed it

#

i changed the scoring code to pull from gorb count instead fo xmult but the only issue is that the card still says xnil mult

#

WAIT
IDEA

#

nevermind my idea dont work

#

rip

long sun
#

hihi, what does this portion of Stella Mortis do?

if Incantation then
  quota = planet_to_destroy:getEvalQty()
end```
broken cliff
#

{X:mult,C:white} X#1# {} is actually confusing line of strings

smoky talon
#

i think i figured it out

#

i was missing a line

normal crest
broken cliff
#

huh

#

mult isnt a color tho

#

is it a placeholder of sorts

#

for red?

rough furnace
#

it is

frosty dock
#

same way chips is for blue

rough furnace
#

and attention for orangish

smoky talon
#

wait therye not doing anything

#

they just say x2

#

they dont change the score at all

broken cliff
#

ok and what does X#1# do
does #1 pull from config.extra.mult?

frosty dock
#

it pulls from loc_vars

broken cliff
#

Oh

rough furnace
#

side note if I return a loc_vars like { vars = { test = 1 } } and do #test# does that work?

smoky talon
#

i fixed it

#

finally

#

thanks so much

broken cliff
#

i dont know what stella mortis is

long sun
#

it's an Exotic joker from Cryptid

#

i'm looking at its code to see how to destroy a random Tarot card

normal crest
long sun
#

ah icic :D

#

thanks!!

smoky talon
#

wait i have anothe rproblem now lo;

long sun
#

i thought it meant Incantation, the Spectral, but that didn't make any sense — your explanation feels obvious now =w=

smoky talon
#

the description isnt updating with the card

#

i assume it onluy activates when the game starts and doesnt update

#

how do i fix that?

frosty dock
rough furnace
#

I don't have any use for it but it may be neat

broken cliff
#

finally, free at last

#

now i have x25 properly showing

frosty dock
# rough furnace I don't have any use for it but it may be neat

https://github.com/Steamodded/smods/pull/330 there's this rejected PR that did that along with default loc_vars using those string keys. I think I said it'd be best to stick to vanilla conventions to not make things more confusing

GitHub

Adds a default loc_vars function and allows for returned args from loc_vars to use not just number keys but also string keys. Alters the localization function directly so the string key change can ...

#

i guess it's debatable if that should also generally disallow string keys

normal crest
#

I know that vanilla uses the colours key from vars for whatever the {V:1} thing means

frosty dock
#

yeah that's a special case

long sun
#

hmm, so hovering over one of my jokers in the collection crashed the game

rough furnace
#

those ones should let you pass strings for custom colouyrs though, right?

long sun
#

i know why, but i've no idea how to fix it

long sun
#

it was this line:
return { vars = { count_planets(), card.ability.extra.out_of_odds, card.ability.extra.x_mult } }

#

it tried to count the number of planets when i was on the title screen

#

aha wait no i can fix this. maybe.

#

i've seen some or 0s around some people's code, and now i know why :}

smoky talon
#

i fixed it

long sun
#

hmm, no, still bugged. it tried to index consumeables which was nil

#

but my count_planets() function checks if it's nil first:
if G.consumeables.cards then

#

...ah wait, nevermind. it counts indexing as the .cards bit right?

normal crest
#

Remove the .cards from that if

long sun
#

hokai

rough furnace
#

if you need to index something that doesn't exist the standard behaviour is G and G.consumables and G.consumeables.cards instead of G.consumeables.cards (although you can proably skip the G part for this one as it should always be defined in balatro)]

long sun
#

there we go, cheers :D

normal crest
#

Love seeing well written descriptions

long sun
#

mm?

#

(are you talking about Luke?)

normal crest
#

Yeah

long sun
#

awesome, thanks ^^

#

oh also Candle works now :D!!

cyan dune
#

Hi, apologies for this likely easy to solve issue, but I'm starting to lose my mind a little;
Updating my own deck skin series to work with the new DeckSkin API, but try as I might I cannot get the cards to show up in-game. I've been following the Cardsauce Experimental Skins formatting, but in messing around with the key and atlas variables (switching which one references FoLK and which one points to the deck) I've only gotten a crash, the original cards showing up, or, for this current iteration, the 4, 3, and 2 of Hearts. Would anyone be able to point out the area I'm going wrong in?

rough furnace
#

you will need your prefix on the atlas keys

cyan dune
#

Ahhhh. I... never set one. That would explain a lot.

rough furnace
#

it's just for the reference not the defijitoon

south folio
#

is there a context for it to count things in the Full Deck?

#

like cloud 9

frosty dock
#

how exactly is that an in-game action that happens?

south folio
#

you know what that's a fair question

normal crest
#

iirc cloud 9 counts them on the update function

frosty dock
#

it does but that's inefficient and not really needed

#

in the case of cloud 9, calc_dollar_bonus and loc_vars would suffice

#

or more generally, before any calculation that uses the value and in loc_vars

red osprey
#

I need help regarding custom palettes: I'm trying to add an alternate high contrast option to the default suits and the existing collabs (green clubs and blue diamonds). This is my current code, and while the option appears, the atlas are not applied (the cards use the default low contrast atlas). The atlas work fine if I just override the High Contrast Colors option, by using the cards_2 key and prefix_option.key = false. Any ideas on what is wrong?

SMODS.Atlas{ key = 'cards_2Alt', path = '8BitDeckAlt_opt2.png', px = 71, py = 95 }
SMODS.Atlas{ key = 'icons_2Alt', path = 'ui_assetsAlt_opt2.png', px = 71, py = 95 }

SMODS.DeckSkin:take_ownership('default_Clubs', {
    palettes = {
        {
            key = 'lc',
            ranks = {'Ace', 'King', 'Queen', 'Jack', '10', '9', '8', '7', '6', '5', '4', '3', '2'},
            display_ranks = {'King', 'Queen', 'Jack'},
            atlas = 'cards_1',
            pos_style = 'deck'
        },
        {
            key = 'hc',
            ranks = {'Ace', 'King', 'Queen', 'Jack', '10', '9', '8', '7', '6', '5', '4', '3', '2'},
            display_ranks = {'King', 'Queen', 'Jack'},
            atlas = 'cards_2',
            pos_style = 'deck'
        },
        {
            key = 'hc_alt',
            loc_txt = 'High Contrast Alternate',
            ranks = {'Ace', 'King', 'Queen', 'Jack', '10', '9', '8', '7', '6', '5', '4', '3', '2'},
            display_ranks = {'King', 'Queen', 'Jack'},
            atlas = 'althico_cards_2Alt',
            pos_style = 'deck',
            suit_icon = {
                atlas = 'althico_icons_2Alt',
                pos = 1,
            },
        },
    }
})
-- Repeated code for Diamonds
livid tapir
#

gyuys pleasehelp

#

im trying to add a collectible type, but smth is def wrong

worthy stirrup
#

Do vouchers have a shader associated with them?

wintry solar
#

yes

livid tapir
worthy stirrup
#

damn, i was gonna try to make it have the negative shader

wintry solar
#

you can change what it uses

worthy stirrup
#

nice

south folio
#

Might be overthinking this but how do I Count (in this case) 8's I have in the full deck?

    loc_vars = function(self, info_queue, card)
        return { vars = { card.ability.extra.mult_gain, card.ability.extra.mult } }
    end,
    calculate = function(self, card, context)
        if context.cardarea and context.cardarea == G.jokers then
            card.ability.extra.mult = card.ability.extra.mult + card.ability.extra.mult_gain
            card_eval_status_text(card, 'extra', nil, nil, nil, {colour = G.C.RED, message = localize('k_upgrade_ex')})
        end

        if context.joker_main then
            local mult_to_add = card.ability.extra.mult
            return {
                mult = card.ability.extra.mult
            }
        end```
normal crest
#

Loop thru G.playing_cards which is your full deck

livid tapir
long sun
#

these are all rare btw

#

subtle synergy between Canio and Triboulet

frosty dock
#

chicot's soul is lowkey better than chicot

livid tapir
#

i think i realized why the error is happening

#

id guess the colours

#

it just doesnt tell me how youre supposed to do them

#

in the wiki

#

ajhhhhhh i got it

#

its supposed to be a hex code

cerulean rose
#

when using take_ownership, how to reference the default behavior of the object you're overriding?

frosty dock
livid tapir
#

💀

worthy stirrup
#

Do vouchers also use the 71x95 per voucher like how jokers do

cerulean rose
#

yes

worthy stirrup
#

okay thanks

red osprey
# red osprey I need help regarding custom palettes: I'm trying to add an alternate high contr...

Found the solution: I was suppoed to use the add_palette function, not redefine the object manually. Here is the working code:

SMODS.Atlas{ key = 'cards_2_alt', path = '8BitDeckAlt_opt2.png', px = 71, py = 95 }
SMODS.Atlas{ key = 'ui_2_alt', path = 'ui_assetsAlt_opt2.png', px = 18, py = 18 }

SMODS.DeckSkin:take_ownership('default_Clubs', {}):add_palette{
    key = 'hc_alt',
    loc_txt = 'High Contrast Alternate',
    ranks = {'Ace', 'King', 'Queen', 'Jack', '10', '9', '8', '7', '6', '5', '4', '3', '2'},
    display_ranks = {'King', 'Queen', 'Jack'},
    atlas = 'althico_cards_2_alt',
    pos_style = 'deck',
    suit_icon = {
        atlas = 'althico_icons_2_alt',
        pos = 1,
    },
}
livid tapir
#

I GOT IT WORKING LETS GO

#

i havent come up with a mechanic so just take this pluh

#

Now its time to make a booster

#

yippee!!!!

sullen fern
#

pluh!

cerulean rose
livid tapir
sullen fern
#

all of the alabell cards i have planned

#

which i should get to work on

worthy stirrup
#

is there a way to make it so theres only a more chance of a negative without upping the other chances of holos and that stuff

cerulean rose
#

check cryptid wormhole deck

worthy stirrup
#

okay

#

okay, i found it calls for cry_negative_rate = 20, now i gotta find where cry_negative_rate is made

#

okay i found these and i dont understand at all

if self.effect.config.cry_negative_rate then
                G.GAME.modifiers.cry_negative_rate = self.effect.config.cry_negative_rate

SMODS.Edition:take_ownership("negative", {
            get_weight = function(self)
                return self.weight * (G.GAME.modifiers.cry_negative_rate or 1)
            end,
        }, true)
urban veldt
#

Haha, is there a way to check if Wheel of Fortune fails?

livid tapir
#

do boosters use 71x95 like jokers and vouchers

timid parrot
livid tapir
livid tapir
frosty dock
#

the sprites are scaled up by x1.3 or so in-game

livid tapir
#

makes sense

#

thx!

normal crest
#

1.27

frosty dock
#

ty

sullen fern
worthy stirrup
vocal verge
vocal verge
urban veldt
#

Oooh, perfect

#

Huh

#

Damn I actually was gonna make the same effect

vocal verge
#

do it anyways so it's not bundled with the rest?

urban veldt
#

Oh, yeah, but like

#

huh

#

Didn't expect that

maiden river
#

is there a card area specific to booster packs

cerulean rose
#

G.pack_cards

sullen fern
#

i think i'll have to create both the alabell card and the seal at the same time

maiden river
sullen fern
#

so i should create the seal first then the alabell card

#

which is how the seal example mod does it

#

but i also have to create the consumable type

#

there’s a lot i have to do
..

smoky talon
#

how do i make a custom joker rarity?

topaz sun
#

Here's an example from my mod:

    key = "spc",
    loc_txt = {
        name = localize('k_buf_spc')
    },
    badge_colour = HEX('ee8f8d'),
    pools = {["Joker"] = false},
    get_weight = function(self, weight, object_type)
        return weight
    end,
}```

but in my case, the rarity doesn't show up in game. You gotta edit the `pools` part and add a `rate`. Check out the wiki above
sullen fern
#

okay, time to make the cards, and the seal, and the consumables.

topaz sun
#

Does anyone know how to force an UI update on these buttons? I'm trying (and failing miserably) to make the "Auto" button change colors dynamically as it's pressed

smoky talon
#

so the rarity is there just not in the shop?

#

thats what i want

#

i just want to spawn them in

#

through a new skip tag

wintry solar
smoky talon
sullen fern
#

now that i have my metadata set up...... its time to code

topaz sun
smoky talon
#

ah

topaz sun
smoky talon
#

still no

#

apostraphes around it?

topaz sun
#

Oh yea, with quotation marks or apostrophes

#

i forgor

smoky talon
#

now it says error

#

better

topaz sun
#

what does the error say?

smoky talon
#

the jkoker rarity is just ERROR

topaz sun
#

But it's there?

smoky talon
#

yeash

topaz sun
#

That's probably bc you dont have a localization for the rarity's name

#

or did you just use like a string?

#

Try using name = "ultrameganice"

smoky talon
topaz sun
#

see if it shows up

topaz sun
smoky talon
#

k

#

that fixed it

#

thx

topaz sun
#

also you can change the HEX to whatever you want the badge color to be

smoky talon
#

i like the one you have lol

#

but understood

topaz sun
#

lol

worthy stirrup
#

how do i make a function thats ran when the voucher is bought

#

or when a specific voucher is bought

worthy stirrup
#

thanks

cerulean rose
sullen fern
#

now how do i actually start making the mod once i'm done with the metadata

#

sorry if this sounds like a stupid question i just don't really understand that much about actually creating a mod

cerulean rose
weak gate
#

If there was an example sticker mod I would be able to make a sticker 👀 '

worthy stirrup
#

just to check, am i doing this right

#

note, i did already make an atlas, its just not included

livid tapir
#

im trying to make a booster
id just like to know how to make it only include consumables of a specific consumable type

#

any advice cuz the wiki isnt very helpful so far

maiden river
livid tapir
#

ok

maiden river
#
SMODS.Booster({
    key = "basic_pack",
    loc_txt = {
        name = "Basic Pack",
        group_name = "Basic Pack",
        text = {
            "Contains 5",
            "Friends Vs. Friends cards",
        }
    },
    config = {
        extra = 5,
        choose = 2
    },
    kind = "Weapon",
    create_card = function(self, card, i)
        return {
            set = "fvb_cards",
            skip_materialize = true,
        }
    end
})
#

like so

livid tapir
#

thanks!

maiden river
#

also you should also put skip_materialize or your cards will be haunted by green particles

livid tapir
#

LOL