Skip to content
MrYamiTsu edited this page Jan 31, 2026 · 21 revisions

Wiki

Giga Data – Dev Guide

giga_data provides a set of helper fields used by certain components in the mod. These fields allow Jokers, enhancements, and seals to interact with Giga-specific functionnality.

Below is a simple breakdown of each field and how to use it in your mod.


is_upgraded

Boolean

Indicates whether the card (seal, enhancement, or any item using giga_data) has been upgraded.

Implementation :

SMODS.Enhancement{
    key = 'your_custom_enhancement'
    giga_data = {
        is_upgraded = true/false
    }
    ...

Usage :

if card.config.center_key and G.P_CENTERS[card.config.center_key].giga_data and
   G.P_CENTERS[card.config.center_key].giga_data.is_upgraded then
    --for enhancement
end
if card:get_seal() and G.P_SEALS[card:get_seal()].giga_data and
   G.P_SEALS[card:get_seal()].giga_data.is_upgraded then
    --for seal
end

Notes : Your code should always check if giga_data exists before using it.


enh_upgrade

String

Stores the key for the enhancement’s upgrade.

Implementation :

SMODS.Enhancement{
    key = 'your_custom_enhancement'
    giga_data = {
        enh_upgrade = 'key_of_what_it_can_be_upgraded'
    }
    ...

Usage :

...:set_ability(G.P_CENTERS[selected_card.config.center_key].giga_data.enh_upgrade)

seal_upgrade

String

Stores the key for the seal’s upgrade.

Implementation :

SMODS.Enhancement{
    key = 'your_custom_seal'
    giga_data = {
        seal_upgrade = 'key_of_what_it_can_be_upgraded'
    }
    ...

Usage :

...:set_seal(G.P_SEALS[selected_card:get_seal()].giga_data.seal_upgrade, true)

Note : When using it, you should set the second argument to true and place the block of code in an Event. Doing this makes animation smooth.


r_food

Boolean

Field to add some consumable to the voucher-like food pool

Implementation :

SMODS.Consumable{
    key = 'your_custom_consumable',
    set = 'Giga_Food',
    giga_data = {
        r_food = true/false
    },
    ...

Usage :

local consumable = Giga.POOLS.r_food['your_value']
SMODS.add_card({key = consumable})

uncopiable

Boolean

Field that make a consumable uncopiable

Implementation :

SMODS.Consumable{
    key = 'your_custom_consumable',
    giga_data = {
        uncopiable = true/false
    },
    ...

Note : You should always use this field when using r_food field


merge_materials

Table of String

Field that register every materials you need to create a Joker.

Implementation :

SMODS.Joker{
    key = 'your_custom_joker',
    giga_data = {
        merge_materials = {
            'the_1st_joker_key',
            'the_2nd_joker_key'
            ...
        }
    },
    ...

Note : This field is commonly use to create Mega-Legendary Jokers


astral_variant

String

Field that register the Astral variant of a Planet.

Implementation :

SMODS.Consumable{
    key = 'your_custom_planet',
    set = 'Planet',
    giga_data = {
        astral_variant = 'your_astral_planet_key'
    },
    ...

Note : This field should alway refer to an Astral Planet