
SMODS.Joker{ --Specter
    key = "specter",
    config = {
        extra = {
            chipval = 0
        }
    },
    loc_txt = {
        ['name'] = 'Specter',
        ['text'] = {
            [1] = 'This joker gains {C:blue}+100{} Chips',
            [2] = 'for every {C:spectral}Spectral{} card used.',
            [3] = '{C:inactive}[Currently: #1# Chips]{}'
        },
        ['unlock'] = {
            [1] = 'Unlocked by default.'
        }
    },
    pos = {
        x = 9,
        y = 5
    },
    display_size = {
        w = 71 * 1, 
        h = 95 * 1
    },
    cost = 5,
    rarity = 2,
    blueprint_compat = true,
    eternal_compat = true,
    perishable_compat = true,
    unlocked = true,
    discovered = true,
    atlas = 'CustomJokers',
    pools = { ["kamenrider_kamenrider_jokers"] = true },
    
    loc_vars = function(self, info_queue, card)
        
        return {vars = {card.ability.extra.chipval}}
    end,
    
    calculate = function(self, card, context)
        if context.cardarea == G.jokers and context.joker_main  then
            return {
                chips = card.ability.extra.chipval
            }
        end
        if context.using_consumeable  then
            if context.consumeable and context.consumeable.ability.set == 'Spectral' then
                return {
                    func = function()
                        card.ability.extra.chipval = (card.ability.extra.chipval) + 100
                        return true
                    end
                }
            end
        end
    end
}