diff --git a/ArtBox.json b/ArtBox.json index 18cbd29..cd8fae0 100644 --- a/ArtBox.json +++ b/ArtBox.json @@ -8,8 +8,8 @@ "main_file": "ArtBox.lua", "priority": 0, "badge_colour": "14b3ad", - "version": "0.5.0", + "version": "0.7.0", "dependencies": [ - "Steamodded (>=1.0.0~BETA-0808a)" + "Steamodded (>=1.0.0~BETA-0827c)" ] } \ No newline at end of file diff --git a/ArtBox.lua b/ArtBox.lua index 7e3041a..fc9b11f 100644 --- a/ArtBox.lua +++ b/ArtBox.lua @@ -19,14 +19,14 @@ Game.main_menu = function(change_context) if ArtBox_config.menu then -- adds a Blend to the main menu local newcard = Card( - G.title_top.T.x, - G.title_top.T.y, - G.CARD_W, - G.CARD_H, - G.P_CARDS.empty, - G.P_CENTERS['c_artb_art_blend'], - { bypass_discovery_center = true } - ) + G.title_top.T.x, + G.title_top.T.y, + G.CARD_W, + G.CARD_H, + G.P_CARDS.empty, + G.P_CENTERS['c_artb_art_blend'], + { bypass_discovery_center = true } + ) -- recenter the title G.title_top.T.w = G.title_top.T.w * 1.7675 @@ -37,13 +37,13 @@ Game.main_menu = function(change_context) newcard.T.w = newcard.T.w * 1.1 * 1.2 newcard.T.h = newcard.T.h * 1.1 * 1.2 newcard.no_ui = true - newcard.states.visible = false + newcard.states.visible = false -- make the title screen use different background colors G.SPLASH_BACK:define_draw_steps({ { shader = 'splash', send = { - { name = 'time', ref_table = G.TIMERS, ref_value = 'REAL_SHADER' }, + { name = 'time', ref_table = G.TIMERS, ref_value = 'REAL_SHADER' }, { name = 'vort_speed', val = 0.4 }, { name = 'colour_1', ref_table = ArtBox.C, ref_value = 'ARTB_PRIMARY' }, { name = 'colour_2', ref_table = ArtBox.C, ref_value = 'ARTB_SECONDARY' }, @@ -51,22 +51,22 @@ Game.main_menu = function(change_context) } }) -- materialize blend card - G.E_MANAGER:add_event(Event({ - trigger = "after", - delay = 0, - blockable = false, - blocking = false, - func = function() - if change_context == "splash" then - newcard.states.visible = true - newcard:start_materialize({ G.C.WHITE, ArtBox.C.ARTB_SECONDARY }, true, 2.5) - else - newcard.states.visible = true - newcard:start_materialize({ G.C.WHITE, ArtBox.C.ARTB_SECONDARY }, nil, 1.2) - end - return true - end, - })) + G.E_MANAGER:add_event(Event({ + trigger = "after", + delay = 0, + blockable = false, + blocking = false, + func = function() + if change_context == "splash" then + newcard.states.visible = true + newcard:start_materialize({ G.C.WHITE, ArtBox.C.ARTB_SECONDARY }, true, 2.5) + else + newcard.states.visible = true + newcard:start_materialize({ G.C.WHITE, ArtBox.C.ARTB_SECONDARY }, nil, 1.2) + end + return true + end, + })) end return ret @@ -96,6 +96,13 @@ SMODS.Atlas { py = 95 } +SMODS.Atlas { + key = "collectable_atlas_2", + path = "collectable_2.png", + px = 71, + py = 95 +} + SMODS.Atlas { key = "spectral_atlas", path = "spectrals.png", @@ -153,7 +160,7 @@ ArtBox.config_tab = function() n = G.UIT.ROOT, config = { align = "m", r = 0.1, padding = 0.1, colour = G.C.BLACK, minw = 8, minh = 6 }, nodes = { - { n = G.UIT.R, config = { align = "cl", padding = 0, minh = 0.1 }, nodes = {} }, + { n = G.UIT.R, config = { align = "cl", padding = 0, minh = 0.1 }, nodes = {} }, -- Collectible Shine Toggle { @@ -198,6 +205,28 @@ ArtBox.config_tab = function() }, } }, + + -- Null Hand Toggle + { + n = G.UIT.R, + config = { align = "cl", padding = 0 }, + nodes = { + { + n = G.UIT.C, + config = { align = "cl", padding = 0.05 }, + nodes = { + create_toggle { col = true, label = "", scale = 1, w = 0, shadow = true, ref_table = ArtBox_config, ref_value = "null_hand" }, + } + }, + { + n = G.UIT.C, + config = { align = "c", padding = 0 }, + nodes = { + { n = G.UIT.T, config = { text = localize('artb_null_hand_toggle'), scale = 0.45, colour = G.C.UI.TEXT_LIGHT } }, + } + }, + } + }, } } end @@ -223,7 +252,7 @@ SMODS.ConsumableType({ text = { 'Find this card in an unseeded', 'run to find out what it does' } } }, - collection_rows = { 4, 4, 4 }, + collection_rows = { 2, 3 }, shop_rate = 0, default = 'c_artb_joker_collectable' }) @@ -242,6 +271,11 @@ ArtBox.Collectables = { ['gb_fortune'] = { atlas = 'artb_collectable_atlas', pos = { x = 0, y = 8 }, soul_pos = { x = 0, y = 9 } }, ['gb_infinite'] = { atlas = 'artb_collectable_atlas', pos = { x = 1, y = 8 }, soul_pos = { x = 1, y = 9 } }, + ['aij_smiley'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 6, y = 0 }, soul_pos = { x = 6, y = 1 } }, + ['aij_melted'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 7, y = 0 }, soul_pos = { x = 7, y = 1 } }, + + ['akyrs_carmine'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 5, y = 4 }, soul_pos = { x = 5, y = 5 } }, + --Enhancements ['m_bonus'] = { atlas = 'artb_collectable_atlas', pos = { x = 1, y = 0 }, soul_pos = { x = 1, y = 1 } }, ['m_mult'] = { atlas = 'artb_collectable_atlas', pos = { x = 4, y = 0 }, soul_pos = { x = 4, y = 1 } }, @@ -255,6 +289,7 @@ ArtBox.Collectables = { ['m_artb_wood'] = { atlas = 'artb_collectable_atlas', pos = { x = 9, y = 2 }, soul_pos = { x = 9, y = 3 } }, ['m_artb_stained'] = { atlas = 'artb_collectable_atlas', pos = { x = 8, y = 2 }, soul_pos = { x = 8, y = 3 } }, ['m_artb_marble'] = { atlas = 'artb_collectable_atlas', pos = { x = 1, y = 6 }, soul_pos = { x = 1, y = 7 } }, + ['m_artb_clay'] = { atlas = 'artb_collectable_atlas', pos = { x = 5, y = 12 }, soul_pos = { x = 5, y = 13 } }, ['m_paperback_bandaged'] = { atlas = 'artb_collectable_atlas', pos = { x = 5, y = 4 }, soul_pos = { x = 5, y = 5 } }, ['m_paperback_soaked'] = { atlas = 'artb_collectable_atlas', pos = { x = 6, y = 4 }, soul_pos = { x = 6, y = 5 } }, @@ -272,14 +307,40 @@ ArtBox.Collectables = { ['m_gb_wooden'] = { atlas = 'artb_collectable_atlas', pos = { x = 7, y = 6 }, soul_pos = { x = 7, y = 7 } }, ['m_gb_honey'] = { atlas = 'artb_collectable_atlas', pos = { x = 8, y = 6 }, soul_pos = { x = 8, y = 7 } }, - ['m_ortalab_recycled'] = { atlas = 'artb_collectable_atlas', pos = { x = 7, y = 8 }, soul_pos = { x = 7, y = 9 }}, - ['m_ortalab_rusty'] = { atlas = 'artb_collectable_atlas', pos = { x = 8, y = 8 }, soul_pos = { x = 8, y = 9 }}, - ['m_ortalab_index'] = { atlas = 'artb_collectable_atlas', pos = { x = 9, y = 8 }, soul_pos = { x = 9, y = 9 }}, - ['m_ortalab_post'] = { atlas = 'artb_collectable_atlas', pos = { x = 0, y = 10 }, soul_pos = { x = 0, y = 11 }}, - ['m_ortalab_bent'] = { atlas = 'artb_collectable_atlas', pos = { x = 1, y = 10 }, soul_pos = { x = 1, y = 11 }}, - ['m_ortalab_sand'] = { atlas = 'artb_collectable_atlas', pos = { x = 2, y = 10 }, soul_pos = { x = 2, y = 11 }}, - ['m_ortalab_iou'] = { atlas = 'artb_collectable_atlas', pos = { x = 3, y = 10 }, soul_pos = { x = 3, y = 11 }}, - ['m_ortalab_ore'] = { atlas = 'artb_collectable_atlas', pos = { x = 4, y = 10 }, soul_pos = { x = 4, y = 11 }}, + ['m_ortalab_recycled'] = { atlas = 'artb_collectable_atlas', pos = { x = 7, y = 8 }, soul_pos = { x = 7, y = 9 } }, + ['m_ortalab_rusty'] = { atlas = 'artb_collectable_atlas', pos = { x = 8, y = 8 }, soul_pos = { x = 8, y = 9 } }, + ['m_ortalab_index'] = { atlas = 'artb_collectable_atlas', pos = { x = 9, y = 8 }, soul_pos = { x = 9, y = 9 } }, + ['m_ortalab_post'] = { atlas = 'artb_collectable_atlas', pos = { x = 0, y = 10 }, soul_pos = { x = 0, y = 11 } }, + ['m_ortalab_bent'] = { atlas = 'artb_collectable_atlas', pos = { x = 1, y = 10 }, soul_pos = { x = 1, y = 11 } }, + ['m_ortalab_sand'] = { atlas = 'artb_collectable_atlas', pos = { x = 2, y = 10 }, soul_pos = { x = 2, y = 11 } }, + ['m_ortalab_iou'] = { atlas = 'artb_collectable_atlas', pos = { x = 3, y = 10 }, soul_pos = { x = 3, y = 11 } }, + ['m_ortalab_ore'] = { atlas = 'artb_collectable_atlas', pos = { x = 4, y = 10 }, soul_pos = { x = 4, y = 11 } }, + + ['m_bunc_cracker'] = { atlas = 'artb_collectable_atlas', pos = { x = 9, y = 10 }, soul_pos = { x = 9, y = 11 } }, + ['m_bunc_copper'] = { atlas = 'artb_collectable_atlas', pos = { x = 0, y = 12 }, soul_pos = { x = 0, y = 13 } }, + + ['m_aij_fervent'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 0, y = 0 }, soul_pos = { x = 0, y = 1 } }, + ['m_aij_charged'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 1, y = 0 }, soul_pos = { x = 1, y = 1 } }, + ['m_aij_ice'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 2, y = 0 }, soul_pos = { x = 2, y = 1 } }, + ['m_aij_wood'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 3, y = 0 }, soul_pos = { x = 3, y = 1 } }, + ['m_aij_canvas'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 4, y = 0 }, soul_pos = { x = 4, y = 1 } }, + ['m_aij_simulated'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 5, y = 0 }, soul_pos = { x = 5, y = 1 } }, + + ['m_buf_porcelain'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 2, y = 2 }, soul_pos = { x = 2, y = 3 } }, + ['m_buf_porcelain_g'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 3, y = 2 }, soul_pos = { x = 3, y = 3 } }, + + ['m_akyrs_scoreless'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 4, y = 2 }, soul_pos = { x = 4, y = 3 } }, + ['m_akyrs_brick_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 5, y = 2 }, soul_pos = { x = 5, y = 3 } }, + ['m_akyrs_ash_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 6, y = 2 }, soul_pos = { x = 6, y = 3 } }, + ['m_akyrs_hatena'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 7, y = 2 }, soul_pos = { x = 7, y = 3 } }, + ['m_akyrs_item_box'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 8, y = 2 }, soul_pos = { x = 8, y = 3 } }, + ['m_akyrs_insolate_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 9, y = 2 }, soul_pos = { x = 9, y = 3 } }, + ['m_akyrs_canopy_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 0, y = 4 }, soul_pos = { x = 0, y = 5 } }, + ['m_akyrs_thai_tea_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 1, y = 4 }, soul_pos = { x = 1, y = 5 } }, + ['m_akyrs_matcha_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 2, y = 4 }, soul_pos = { x = 2, y = 5 } }, + ['m_akyrs_earl_grey_tea_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 3, y = 4 }, soul_pos = { x = 3, y = 5 } }, + ['m_akyrs_zap_card'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 4, y = 4 }, soul_pos = { x = 4, y = 5 } }, + --Editions ['e_polychrome'] = { atlas = 'artb_collectable_atlas', pos = { x = 3, y = 2 }, soul_pos = { x = 3, y = 3 }, shader = 'polychrome', }, ['e_foil'] = { atlas = 'artb_collectable_atlas', pos = { x = 6, y = 2 }, soul_pos = { x = 3, y = 3 }, shader = 'foil', }, @@ -290,6 +351,19 @@ ArtBox.Collectables = { ['e_ortalab_fluorescent'] = { atlas = 'artb_collectable_atlas', pos = { x = 6, y = 10 }, soul_pos = { x = 6, y = 11 }, shader = 'ortalab_fluorescent', }, ['e_ortalab_anaglyphic'] = { atlas = 'artb_collectable_atlas', pos = { x = 7, y = 10 }, soul_pos = { x = 7, y = 11 }, shader = 'ortalab_anaglyphic', }, ['e_ortalab_overexposed'] = { atlas = 'artb_collectable_atlas', pos = { x = 8, y = 10 }, soul_pos = { x = 8, y = 11 }, shader = 'ortalab_overexposed', }, + + ['e_bunc_glitter'] = { atlas = 'artb_collectable_atlas', pos = { x = 2, y = 12 }, soul_pos = { x = 2, y = 13 }, shader = 'bunc_glitter', }, + ['e_bunc_fluorescent'] = { atlas = 'artb_collectable_atlas', pos = { x = 3, y = 12 }, soul_pos = { x = 3, y = 13 }, shader = 'bunc_fluorescent', }, + + ['e_aij_glimmer'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 8, y = 0 }, soul_pos = { x = 8, y = 1 }, shader = 'aij_glimmer', }, + ['e_aij_silver'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 9, y = 0 }, soul_pos = { x = 9, y = 1 }, shader = 'aij_silver', }, + ['e_aij_stellar'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 0, y = 2 }, soul_pos = { x = 0, y = 3 }, shader = 'aij_stellar', }, + ['e_aij_aureate'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 1, y = 2 }, soul_pos = { x = 1, y = 3 }, shader = 'aij_aureate', }, + + ['e_akyrs_texelated'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 6, y = 4 }, soul_pos = { x = 6, y = 5 }, shader = 'akyrs_texelated', }, + ['e_akyrs_noire'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 7, y = 4 }, soul_pos = { x = 7, y = 5 }, shader = 'akyrs_noire', }, + ['e_akyrs_sliced'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 8, y = 4 }, soul_pos = { x = 8, y = 5 } }, + ['e_akyrs_burnt'] = { atlas = 'artb_collectable_atlas_2', pos = { x = 9, y = 4 }, soul_pos = { x = 9, y = 5 } }, } function ArtBox.add_collectible(key, args) @@ -300,7 +374,6 @@ function ArtBox.add_collectible(key, args) sendWarnMessage('A Collectable type ' .. key .. ' could not properly be loaded', 'ArtBox') end end - function ArtBox.create_collectable(key) local collectable = SMODS.add_card({ key = 'c_artb_mod_collectable' }) @@ -322,7 +395,8 @@ function ArtBox.create_collectable(key) collectable.children.center.atlas = G.ASSET_ATLAS[ref_values.atlas] collectable.children.center:set_sprite_pos(ref_values.pos) - collectable.children.floating_sprite = Sprite(collectable.T.x, collectable.T.y, collectable.T.w, collectable.T.h, G.ASSET_ATLAS[ref_values.atlas], ref_values.soul_pos) + collectable.children.floating_sprite = Sprite(collectable.T.x, collectable.T.y, collectable.T.w, collectable.T.h, + G.ASSET_ATLAS[ref_values.atlas], ref_values.soul_pos) collectable.children.floating_sprite.role.draw_major = collectable collectable.children.floating_sprite.states.hover.can = false collectable.children.floating_sprite.states.click.can = false @@ -334,25 +408,30 @@ function ArtBox.create_collectable(key) end SMODS.DrawStep { - key = 'collectable_shaders', - order = 61, - func = function(self, layer) - if self.ability.set == 'collectable' then - if self.config.center.key == 'c_artb_mod_collectable' and self.ability.extra.shader then - local scale_mod = 0.07 + 0.02 * math.sin(1.8 * G.TIMERS.REAL) + 0.00 * math.sin((G.TIMERS.REAL - math.floor(G.TIMERS.REAL)) * math.pi * 14) * (1 - (G.TIMERS.REAL - math.floor(G.TIMERS.REAL))) ^ 3 - local rotate_mod = 0.05 * math.sin(1.219 * G.TIMERS.REAL) + 0.00 * math.sin((G.TIMERS.REAL) * math.pi * 5) * (1 - (G.TIMERS.REAL - math.floor(G.TIMERS.REAL))) ^ 2 - - self.children.floating_sprite:draw_shader(self.ability.extra.shader, nil, self.ARGS.send_to_shader, nil, self.children.center, scale_mod, rotate_mod) - if self.ability.extra.shader == 'negative' then - self.children.floating_sprite:draw_shader('negative_shine', nil, self.ARGS.send_to_shader, nil, self.children.center, scale_mod, rotate_mod) + key = 'collectable_shaders', + order = 61, + func = function(self, layer) + if self.ability.set == 'collectable' then + if self.config.center.key == 'c_artb_mod_collectable' and self.ability.extra.shader then + local scale_mod = 0.07 + 0.02 * math.sin(1.8 * G.TIMERS.REAL) + + 0.00 * math.sin((G.TIMERS.REAL - math.floor(G.TIMERS.REAL)) * math.pi * 14) * + (1 - (G.TIMERS.REAL - math.floor(G.TIMERS.REAL))) ^ 3 + local rotate_mod = 0.05 * math.sin(1.219 * G.TIMERS.REAL) + + 0.00 * math.sin((G.TIMERS.REAL) * math.pi * 5) * (1 - (G.TIMERS.REAL - math.floor(G.TIMERS.REAL))) ^ 2 + + self.children.floating_sprite:draw_shader(self.ability.extra.shader, nil, self.ARGS.send_to_shader, nil, + self.children.center, scale_mod, rotate_mod) + if self.ability.extra.shader == 'negative' then + self.children.floating_sprite:draw_shader('negative_shine', nil, self.ARGS.send_to_shader, nil, + self.children.center, scale_mod, rotate_mod) + end + end + if self:should_draw_base_shader() and ArtBox_config.collectable_shine then + self.children.center:draw_shader('voucher', nil, self.ARGS.send_to_shader) + end end - end - if self:should_draw_base_shader() and ArtBox_config.collectable_shine then - self.children.center:draw_shader('voucher', nil, self.ARGS.send_to_shader) - end - end - end, - conditions = { vortex = false, facing = 'front' }, + end, + conditions = { vortex = false, facing = 'front' }, } --#endregion @@ -370,7 +449,7 @@ SMODS.ConsumableType({ text = { 'Find this card in an unseeded', 'run to find out what it does' } } }, - collection_rows = { 4, 4, 4 }, + collection_rows = { 5, 5 }, shop_rate = 0, default = 'c_artb_art_paper' }) @@ -406,4 +485,4 @@ local path = SMODS.current_mod.path .. 'other/' for _, v in pairs(NFS.getDirectoryItems(path)) do assert(SMODS.load_file('other/' .. v))() end ---#endregion \ No newline at end of file +--#endregion diff --git a/artsandcrafts/art_art_block.lua b/artsandcrafts/art_art_block.lua index 507b741..7c915ea 100644 --- a/artsandcrafts/art_art_block.lua +++ b/artsandcrafts/art_art_block.lua @@ -8,7 +8,7 @@ SMODS.Consumable ({ cost = 4, unlocked = true, discovered = true, - config = {mod_conv = "m_artb_stained", max_highlighted = 2}, + config = {mod_conv = "m_artb_stained", max_highlighted = 1}, effect = 'Enhance', loc_vars = function(self, info_queue) info_queue[#info_queue + 1] = G.P_CENTERS[self.config.mod_conv] diff --git a/artsandcrafts/art_mystery_box.lua b/artsandcrafts/art_mystery_box.lua new file mode 100644 index 0000000..db27bc7 --- /dev/null +++ b/artsandcrafts/art_mystery_box.lua @@ -0,0 +1,53 @@ +SMODS.Consumable({ + object_type = "Consumable", + atlas = 'arts_atlas', + key = 'art_mystery_box', + set = 'art', + name = 'Mystery Box', + pos = { x = 2, y = 2 }, + cost = 4, + unlocked = true, + discovered = true, + + use = function(self, card, area) + + while #G.consumeables.cards + G.GAME.consumeable_buffer < G.consumeables.config.card_limit do + G.GAME.consumeable_buffer = G.GAME.consumeable_buffer + 1 + local random_roll = pseudorandom("box") + + if random_roll<0.05 then + G.E_MANAGER:add_event(Event({ + func = function() + ArtBox.create_collectable(poll_edition('mystery', nil, true, true)) + G.GAME.consumeable_buffer = 0 + return true + end + })) + elseif random_roll<0.3 then + G.E_MANAGER:add_event(Event({ + func = function() + local valid_keys = {} + for _, seal_center in pairs(G.P_CENTER_POOLS["Seal"]) do + valid_keys[#valid_keys + 1] = seal_center.key + end + ArtBox.create_collectable(pseudorandom_element(valid_keys, pseudoseed("mystery"))) + G.GAME.consumeable_buffer = 0 + return true + end + })) + else + G.E_MANAGER:add_event(Event({ + func = function() + ArtBox.create_collectable(SMODS.poll_enhancement({guaranteed = true, key = 'mystery'})) + G.GAME.consumeable_buffer = 0 + return true + end + })) + end + end + end, + + can_use = function(self, card, area) + return true + end +}) diff --git a/artsandcrafts/art_pottery.lua b/artsandcrafts/art_pottery.lua new file mode 100644 index 0000000..b08df30 --- /dev/null +++ b/artsandcrafts/art_pottery.lua @@ -0,0 +1,18 @@ +SMODS.Consumable ({ + object_type = "Consumable", + atlas = 'arts_atlas', + key = 'art_pottery', + set = 'art', + pos = { x = 3, y = 2 }, + cost = 4, + unlocked = true, + discovered = true, + config = {mod_conv = "m_artb_clay", max_highlighted = 2}, + effect = 'Enhance', + loc_vars = function(self, info_queue) + info_queue[#info_queue + 1] = G.P_CENTERS[self.config.mod_conv] + + return { vars = { self.config.max_highlighted } } + end, + +}) \ No newline at end of file diff --git a/artsandcrafts/art_still_life.lua b/artsandcrafts/art_still_life.lua new file mode 100644 index 0000000..0bd5eef --- /dev/null +++ b/artsandcrafts/art_still_life.lua @@ -0,0 +1,43 @@ +SMODS.Consumable ({ + object_type = "Consumable", + atlas = 'arts_atlas', + key = 'art_still_life', + set = 'art', + name = 'Still Life', + config = { + mod_conv = "c_artb_gros_michel_collectable", + }, + pos = { x = 1, y = 2 }, + cost = 4, + unlocked = true, + discovered = true, + can_use = function(self, card) + return true + end, + loc_vars = function(self, info_queue, card) + info_queue[#info_queue + 1] = G.P_CENTERS[self.config.mod_conv] + return { + vars = { + G.GAME.probabilities.normal + } + } + end, + + use = function(self, card, area) + if #G.consumeables.cards + G.GAME.consumeable_buffer < G.consumeables.config.card_limit or next(SMODS.find_card('c_artb_gros_michel_collectable', count_debuffed)) then + G.E_MANAGER:add_event(Event({trigger = 'after', delay = 0.4, func = function() + if pseudorandom("still_life") < 0.05 then + local new_card = create_card("collectable", G.consumables, nil, nil, nil, nil, 'c_artb_cavendish_collectable') + new_card:add_to_deck() + G.consumeables:emplace(new_card) + else + local new_card = create_card("collectable", G.consumables, nil, nil, nil, nil, 'c_artb_gros_michel_collectable') + new_card:add_to_deck() + G.consumeables:emplace(new_card) + end + return true end })) + end + end + + +}) \ No newline at end of file diff --git a/assets/1x/artsandcrafts.png b/assets/1x/artsandcrafts.png index bd86d86..d854069 100644 Binary files a/assets/1x/artsandcrafts.png and b/assets/1x/artsandcrafts.png differ diff --git a/assets/1x/collabs/inscryption_face_cards_hc.png b/assets/1x/collabs/inscryption_face_cards_hc.png new file mode 100644 index 0000000..0124f60 Binary files /dev/null and b/assets/1x/collabs/inscryption_face_cards_hc.png differ diff --git a/assets/1x/collabs/inscryption_face_cards_lc.png b/assets/1x/collabs/inscryption_face_cards_lc.png new file mode 100644 index 0000000..b5d6635 Binary files /dev/null and b/assets/1x/collabs/inscryption_face_cards_lc.png differ diff --git a/assets/1x/collectable.png b/assets/1x/collectable.png index ec57024..12b36fa 100644 Binary files a/assets/1x/collectable.png and b/assets/1x/collectable.png differ diff --git a/assets/1x/collectable_2.png b/assets/1x/collectable_2.png new file mode 100644 index 0000000..0553dfd Binary files /dev/null and b/assets/1x/collectable_2.png differ diff --git a/assets/1x/enhancers.png b/assets/1x/enhancers.png index 9e69a6b..c9c02b6 100644 Binary files a/assets/1x/enhancers.png and b/assets/1x/enhancers.png differ diff --git a/assets/1x/jokers.png b/assets/1x/jokers.png index f5a2945..8593752 100644 Binary files a/assets/1x/jokers.png and b/assets/1x/jokers.png differ diff --git a/assets/2x/artsandcrafts.png b/assets/2x/artsandcrafts.png index 91db2e0..bba714a 100644 Binary files a/assets/2x/artsandcrafts.png and b/assets/2x/artsandcrafts.png differ diff --git a/assets/2x/collabs/inscryption_face_cards_hc.png b/assets/2x/collabs/inscryption_face_cards_hc.png new file mode 100644 index 0000000..acdb191 Binary files /dev/null and b/assets/2x/collabs/inscryption_face_cards_hc.png differ diff --git a/assets/2x/collabs/inscryption_face_cards_lc.png b/assets/2x/collabs/inscryption_face_cards_lc.png new file mode 100644 index 0000000..a220b74 Binary files /dev/null and b/assets/2x/collabs/inscryption_face_cards_lc.png differ diff --git a/assets/2x/collectable.png b/assets/2x/collectable.png index 67b96a7..fb575f4 100644 Binary files a/assets/2x/collectable.png and b/assets/2x/collectable.png differ diff --git a/assets/2x/collectable_2.png b/assets/2x/collectable_2.png new file mode 100644 index 0000000..81f0a50 Binary files /dev/null and b/assets/2x/collectable_2.png differ diff --git a/assets/2x/enhancers.png b/assets/2x/enhancers.png index 14dd862..01d6186 100644 Binary files a/assets/2x/enhancers.png and b/assets/2x/enhancers.png differ diff --git a/assets/2x/jokers.png b/assets/2x/jokers.png index fb98197..286113c 100644 Binary files a/assets/2x/jokers.png and b/assets/2x/jokers.png differ diff --git a/collectable/cavendish_collectable.lua b/collectable/cavendish_collectable.lua new file mode 100644 index 0000000..f5f017a --- /dev/null +++ b/collectable/cavendish_collectable.lua @@ -0,0 +1,59 @@ +SMODS.Consumable({ + key = 'cavendish_collectable', + set = 'collectable', + atlas = 'collectable_atlas', + pos = {x=4, y=12}, + soul_pos = {x=4, y=13}, + discovered = true, + config = { + extra = { + xmult = 2, + xmult_add = 1, + } + }, + keep_on_use = function(self, card) + return false + end, + cost = 2, + can_use = function(self, card) + return false + end, + + loc_vars = function(self, info_queue, card) + return { vars = { card.ability.extra.xmult, card.ability.extra.xmult_add } } + end, + + add_to_deck = function(self, card, from_debuff) + if next(SMODS.find_card('c_artb_cavendish_collectable', count_debuffed)) then + G.E_MANAGER:add_event(Event({ + func = function() + play_sound('coin1') + card:start_dissolve() + G.consumeables:remove_card(card) + return true end + })) + else + First=true + end + + end, + + remove_from_deck = function(self, card, from_debuff) + for i = 1, #G.consumeables.cards do + local _card = G.consumeables.cards[i] + if _card.config.center.key == 'c_artb_cavendish_collectable' then + _card.ability.extra.xmult = _card.ability.extra.xmult + card.ability.extra.xmult_add + card_eval_status_text(_card, 'extra', nil, nil, nil, + { message = localize { type = 'variable', key = 'a_xmult', vars = { _card.ability.extra.xmult } } }) + end + end + end, + + calculate = function(self, card, context) + if context.joker_main then + return { + x_mult = card.ability.extra.xmult + } + end + end +}) \ No newline at end of file diff --git a/collectable/gros_michel_collectable.lua b/collectable/gros_michel_collectable.lua new file mode 100644 index 0000000..993419b --- /dev/null +++ b/collectable/gros_michel_collectable.lua @@ -0,0 +1,59 @@ +SMODS.Consumable({ + key = 'gros_michel_collectable', + set = 'collectable', + atlas = 'collectable_atlas', + pos = {x=3, y=12}, + soul_pos = {x=3, y=13}, + discovered = true, + config = { + extra = { + mult = 4, + mult_add = 4, + } + }, + keep_on_use = function(self, card) + return false + end, + cost = 2, + can_use = function(self, card) + return false + end, + + loc_vars = function(self, info_queue, card) + return { vars = { card.ability.extra.mult, card.ability.extra.mult_add } } + end, + + add_to_deck = function(self, card, from_debuff) + if next(SMODS.find_card('c_artb_gros_michel_collectable', count_debuffed)) then + G.E_MANAGER:add_event(Event({ + func = function() + play_sound('coin1') + card:start_dissolve() + G.consumeables:remove_card(card) + return true end + })) + else + First=true + end + + end, + + remove_from_deck = function(self, card, from_debuff) + for i = 1, #G.consumeables.cards do + local _card = G.consumeables.cards[i] + if _card.config.center.key == 'c_artb_gros_michel_collectable' then + _card.ability.extra.mult = _card.ability.extra.mult + card.ability.extra.mult_add + card_eval_status_text(_card, 'extra', nil, nil, nil, + { message = localize { type = 'variable', key = 'a_mult', vars = { card.ability.extra.mult_add } } }) + end + end + end, + + calculate = function(self, card, context) + if context.joker_main then + return { + mult = card.ability.extra.mult, + } + end + end +}) \ No newline at end of file diff --git a/config.lua b/config.lua index 550175d..b147e83 100644 --- a/config.lua +++ b/config.lua @@ -1,4 +1,5 @@ return { collectable_shine = false, - menu = true + menu = true, + null_hand = true } \ No newline at end of file diff --git a/jokers/card_binder.lua b/jokers/card_binder.lua new file mode 100644 index 0000000..e28d1d8 --- /dev/null +++ b/jokers/card_binder.lua @@ -0,0 +1,67 @@ +SMODS.Joker { + key = "card_binder", + config = { + extra = { + bonus_hs=4, + active=false, + } + }, + rarity = 1, + pos = { x = 1, y = 6}, + atlas = 'joker_atlas', + cost = 4, + unlocked = true, + discovered = true, + blueprint_compat = false, + eternal_compat = true, + perishable_compat = true, + + loc_vars = function(self, info_queue, card) + return { + vars = { + card.ability.extra.bonus_hs, + } + } + end, + + add_to_deck = function(self, card, from_debuff) + if not G.GAME.blind.in_blind and card.ability.extra.active==false then + card.ability.extra.active=true + G.hand:change_size(card.ability.extra.bonus_hs) + card:juice_up() + end + end, + + remove_from_deck = function(self, card, from_debuff) + if card.ability.extra.active==true then + card.ability.extra.active=false + G.hand:change_size(-card.ability.extra.bonus_hs) + card:juice_up() + end + end, + + calculate = function(self, card, context) + if context.setting_blind and card.ability.extra.active==true and not context.blueprint then + card.ability.extra.active=false + G.hand:change_size(-card.ability.extra.bonus_hs) + card:juice_up() + end + + if context.end_of_round and card.ability.extra.active==false and context.game_over == false and context.main_eval and not context.blueprint then + card.ability.extra.active=true + G.hand:change_size(card.ability.extra.bonus_hs) + card:juice_up() + end + end, + + draw = function(self, card, layer) + if (layer == 'card' or layer == 'both') then + if card.ability.extra.active==true then + card.children.center:set_sprite_pos({ x = 2, y = 6}) + else + card.children.center:set_sprite_pos({ x = 1, y = 6}) + end + + end + end + } \ No newline at end of file diff --git a/jokers/energy_drink.lua b/jokers/energy_drink.lua index d47f8f7..e68fd64 100644 --- a/jokers/energy_drink.lua +++ b/jokers/energy_drink.lua @@ -13,7 +13,7 @@ SMODS.Joker { unlocked = true, discovered = true, blueprint_compat = true, - eternal_compat = true, + eternal_compat = false, perishable_compat = false, loc_vars = function(self, info_queue, card) diff --git a/jokers/heist.lua b/jokers/heist.lua new file mode 100644 index 0000000..94a1730 --- /dev/null +++ b/jokers/heist.lua @@ -0,0 +1,46 @@ +SMODS.Joker { + key = "heist", + unlocked = true, + discovered = true, + atlas = 'joker_atlas', + blueprint_compat = true, + rarity = 3, + cost = 8, + pos = { x = 4, y = 5 }, + config = { + extra = { + } + }, + + loc_vars = function(self, info_queue, card) + return { + vars = { + card.sell_cost*3 + } + } + end, + calculate = function(self, card, context) + if context.joker_main then + return { + mult = card.sell_cost*3 + } + end + + if context.setting_blind then + if not context.blueprint and G.jokers.cards[#G.jokers.cards] ~= card then + for v, joker in ipairs(G.jokers.cards) do + if joker == card then + card.ability.extra_value= card.ability.extra_value + G.jokers.cards[v + 1].sell_cost + card:set_cost() + + G.jokers.cards[v + 1].ability.extra_value = G.jokers.cards[v + 1].ability.extra_value - G.jokers.cards[v + 1].sell_cost + G.jokers.cards[v + 1]:set_cost() + + SMODS.calculate_effect({ extra = { message = localize('artb_stolen'), colour = G.C.MONEY } }, G.jokers.cards[v + 1]) + SMODS.calculate_effect({ extra = { message = localize('k_val_up'), colour = G.C.MONEY } }, card) + end + end + end + end + end +} diff --git a/jokers/lego_joker.lua b/jokers/lego_joker.lua index 1386e9e..84f35c2 100644 --- a/jokers/lego_joker.lua +++ b/jokers/lego_joker.lua @@ -14,7 +14,7 @@ SMODS.Joker { info_queue[#info_queue + 1] = G.P_SEALS['artb_brick'] end, - add_to_deck = function(self, card, from_debuff) + add_to_deck = function(self, card) if #G.consumeables.cards + G.GAME.consumeable_buffer < G.consumeables.config.card_limit then G.GAME.consumeable_buffer = G.GAME.consumeable_buffer + 1 G.E_MANAGER:add_event(Event({ diff --git a/jokers/null_pointer.lua b/jokers/null_pointer.lua new file mode 100644 index 0000000..15e751a --- /dev/null +++ b/jokers/null_pointer.lua @@ -0,0 +1,64 @@ +SMODS.Joker { + key = "null_pointer", + rarity = 1, + pos = { x = 6, y = 5 }, + soul_pos = { x = 7, y = 5 }, + atlas = 'joker_atlas', + cost = 6, + unlocked = true, + discovered = true, + blueprint_compat = false, + eternal_compat = false, + perishable_compat = false, + + loc_vars = function(self, info_queue, card) + end, + + add_to_deck = function(self, card) + local rankless_keys = { + 'm_stone' + } + + for k, v in pairs(G.P_CENTERS) do + if v.no_rank then + rankless_keys[#rankless_keys + 1] = k + end + end + + while #G.consumeables.cards + G.GAME.consumeable_buffer < G.consumeables.config.card_limit do + G.GAME.consumeable_buffer = G.GAME.consumeable_buffer + 1 + G.E_MANAGER:add_event(Event({ + func = function() + ArtBox.create_collectable(pseudorandom_element(rankless_keys, 'nullptr')) + G.GAME.consumeable_buffer = 0 + return true; + end + })) + end + end, + + calculate = function(self, card, context) + if context.selling_self then + local rankless_keys = { + 'm_stone' + } + + for k, v in pairs(G.P_CENTERS) do + if v.no_rank then + rankless_keys[#rankless_keys + 1] = k + end + end + + while #G.consumeables.cards + G.GAME.consumeable_buffer < G.consumeables.config.card_limit do + G.GAME.consumeable_buffer = G.GAME.consumeable_buffer + 1 + G.E_MANAGER:add_event(Event({ + func = function() + ArtBox.create_collectable(pseudorandom_element(rankless_keys, 'nullptr')) + G.GAME.consumeable_buffer = 0 + return true; + end + })) + end + end + end +} diff --git a/jokers/paint_bucket.lua b/jokers/paint_bucket.lua new file mode 100644 index 0000000..30ef1e0 --- /dev/null +++ b/jokers/paint_bucket.lua @@ -0,0 +1,81 @@ +SMODS.Joker { + key = "paint_bucket", + config = { + extra = { + uses=5, + } + }, + rarity = 1, + pos = { x = 5, y = 5}, + atlas = 'joker_atlas', + cost = 5, + unlocked = true, + discovered = true, + blueprint_compat = false, + eternal_compat = false, + perishable_compat = false, + + loc_vars = function(self, info_queue, card) + return { + vars = { + card.ability.extra.uses, + } + } + end, + + pools = { + Food = true + }, + + calculate = function(self, card, context) + if context.before and context.main_eval and not context.blueprint then + local rank = context.scoring_hand[1]:get_id() + local new_enhancement = SMODS.poll_enhancement({guaranteed = true, key = 'bucket'}) + + for _, scored_card in ipairs(context.scoring_hand) do + if scored_card:get_id() == rank then + scored_card:set_ability(new_enhancement, nil, true) + G.E_MANAGER:add_event(Event({ + func = function() + scored_card:juice_up() + return true + end + })) + end + end + + card.ability.extra.uses=card.ability.extra.uses-1 + if card.ability.extra.uses <= 0 then + G.E_MANAGER:add_event(Event({ + trigger = 'after', + delay = 0.7, + 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 + card:start_dissolve() + card = nil + return true + end + })) + if pseudorandom("bucket") < 0.05 then + return { + message = localize('k_drank_ex') + } + else + return { + message = localize('artb_empty') + } + end + + else + return { + message = localize('artb_fill'), + colour = G.C.CHIPS + } + end + end + end + } \ No newline at end of file diff --git a/jokers/paint_chips.lua b/jokers/paint_chips.lua new file mode 100644 index 0000000..150ae82 --- /dev/null +++ b/jokers/paint_chips.lua @@ -0,0 +1,36 @@ +SMODS.Joker { + key = "paint_chips", + config = { + extra = { + xmult=0.5, + xchips=2 + } + }, + rarity = 1, + pos = { x = 3, y = 5}, + atlas = 'joker_atlas', + cost = 5, + unlocked = true, + discovered = true, + blueprint_compat = true, + eternal_compat = true, + perishable_compat = true, + + loc_vars = function(self, info_queue, card) + return { + vars = { + card.ability.extra.xmult, + card.ability.extra.xchips, + } + } + end, + + calculate = function(self, card, context) + if context.joker_main then + return { + x_mult = card.ability.extra.xmult, + x_chips = card.ability.extra.xchips, + } + end + end + } \ No newline at end of file diff --git a/jokers/sparkledog.lua b/jokers/sparkledog.lua new file mode 100644 index 0000000..c147ef1 --- /dev/null +++ b/jokers/sparkledog.lua @@ -0,0 +1,69 @@ +SMODS.Joker { + key = "sparkledog", + config = { + extra = { + chips_added=12 + } + }, + rarity = 1, + pos = { x = 0, y = 6}, + atlas = 'joker_atlas', + cost = 5, + unlocked = true, + discovered = true, + blueprint_compat = true, + eternal_compat = true, + perishable_compat = true, + + loc_vars = function(self, info_queue, card) + local unique_modifiers = ArtBox.unique_modifiers_in_deck() + + return { + vars = { + card.ability.extra.chips_added, + unique_modifiers * card.ability.extra.chips_added + } + } + end, + + calculate = function(self, card, context) + if context.joker_main then + return { + chips = ArtBox.unique_modifiers_in_deck() * card.ability.extra.chips_added + } + end + end + } + + ArtBox.unique_modifiers_in_deck = function() + local modifiers = {} + + if G.playing_cards then + for _, v in pairs(G.playing_cards) do + for k, _ in pairs(SMODS.get_enhancements(v)) do + ArtBox.add_modifier_to_list(modifiers, k) + end + + if v.seal then + ArtBox.add_modifier_to_list(modifiers, v.seal) + end + + if v.edition then + ArtBox.add_modifier_to_list(modifiers, v.edition.key) + end + + end + end + + return #modifiers or 0 + end + + ArtBox.add_modifier_to_list = function(tbl, value) + for _, v in pairs(tbl) do + if v == value then + return + end + end + table.insert(tbl, value) + end + diff --git a/jokers/stained_glass.lua b/jokers/stained_glass.lua new file mode 100644 index 0000000..6c1c617 --- /dev/null +++ b/jokers/stained_glass.lua @@ -0,0 +1,65 @@ +SMODS.Joker { + key = "stained_glass", + config = { + mod_conv = "m_glass", + }, + rarity = 2, + pos = { x = 6, y = 2}, + atlas = 'joker_atlas', + cost = 6, + unlocked = true, + discovered = true, + blueprint_compat = true, + eternal_compat = true, + perishable_compat = false, + + loc_vars = function(self, info_queue, card) + info_queue[#info_queue + 1] = G.P_CENTERS[self.config.mod_conv] + info_queue[#info_queue + 1] = G.P_TAGS.tag_artb_creative + end, + + calculate = function(self, card, context) + + if context.individual and context.cardarea == G.play then + if context.other_card.config.center.key == 'm_glass' and #G.consumeables.cards + G.GAME.consumeable_buffer < G.consumeables.config.card_limit then + G.GAME.consumeable_buffer=G.GAME.consumeable_buffer+1 + G.E_MANAGER:add_event(Event({ + func = function() + SMODS.add_card { + set = 'art', + key_append = 'stained' + } + G.GAME.consumeable_buffer = 0 + return true + end + })) + SMODS.calculate_effect({extra = { message = localize('artb_plus_art')}}, card) + end + end + + if context.cards_destroyed then + for k, val in ipairs(context.glass_shattered) do + if val.config.center.key == 'm_glass' then + local tag = Tag("tag_artb_creative") + add_tag(tag) + return { + message = localize('artb_plus_tag') + } + end + end + end + + if context.remove_playing_cards then + for k, val in ipairs(context.removed) do + if val.config.center.key == 'm_glass' then + local tag = Tag("tag_artb_creative") + add_tag(tag) + return { + message = localize('artb_plus_tag') + } + end + end + end + + end +} \ No newline at end of file diff --git a/localization/en-us.lua b/localization/en-us.lua index cd4d3b7..8aff224 100644 --- a/localization/en-us.lua +++ b/localization/en-us.lua @@ -11,16 +11,28 @@ return { artb_plus_tag = "+1 Tag", artb_wood = "Wood!", artb_wild = "Wild", - artb_hungry = "Hungry", - artb_fed = "Fed", - artb_starved = "Starved :(", - artb_menu = "Enable Custom Menu", + artb_hungry="Hungry", + artb_fed="Fed", + artb_starved="Starved :(", + artb_protoplanet="Protoplanet", + artb_stolen="Stolen!", + artb_null_hand_toggle = "Toggle Null Hand", + artb_menu = "Toggle Custom Menu", + artb_fill= "Fill!", + artb_empty= "Empty", + artb_fired= "Fired!" }, labels = { artb_ouroboros_seal = "Ouroboros Seal", artb_brick_seal = "Brick Seal", artb_button_seal = "Button Seal", }, + poker_hand_descriptions={ + ["artb_null"] = {'5 Rankless Cards'}, + }, + poker_hands={ + ["artb_null"] = "Null", + }, }, descriptions = { Joker = { @@ -68,11 +80,11 @@ return { "{C:clubs}Club{} suit give", "{C:mult}+#2#{} Mult when scored", }, - { - "Played cards with", - "{C:spades}Spade{} suit give", - "{C:chips}+#1#{} Chips when scored", - } } + { + "Played cards with", + "{C:spades}Spade{} suit give", + "{C:chips}+#1#{} Chips when scored", + } } }, j_artb_clawmachine = { @@ -157,11 +169,11 @@ return { "in the same hand,", "destroy all {C:attention}9{}s", }, - { - "Scored {C:attention}7{}s give {C:mult}+#2#{} Mult for", - "each {C:attention}9{} destroyed by this card", - "{C:inactive}(Currently: {C:mult}+#1#{} {C:inactive}Mult)" - } } + { + "Scored {C:attention}7{}s give {C:mult}+#2#{} Mult for", + "each {C:attention}9{} destroyed by this card", + "{C:inactive}(Currently: {C:mult}+#1#{} {C:inactive}Mult)" + } } }, j_artb_collector = { @@ -172,12 +184,12 @@ return { "to a {C:attention}Joker{} or {C:attention}Consumable{}", "to the right", }, - { - "Gives {X:mult,C:white}X#1#{} Mult times", - "total {C:attention}sell value{} of all owned", - "{C:attention}Jokers{} and {C:attention}Consumables{}", - "{C:inactive}(Currently: {X:mult,C:white}X#2#{} {C:inactive}Mult)" - } } + { + "Gives {X:mult,C:white}X#1#{} Mult times", + "total {C:attention}sell value{} of all owned", + "{C:attention}Jokers{} and {C:attention}Consumables{}", + "{C:inactive}(Currently: {X:mult,C:white}X#2#{} {C:inactive}Mult)" + } } }, j_artb_origami = { @@ -218,11 +230,11 @@ return { "has one {C:attention}stacks{} them", "{C:inactive}(Up to {C:attention}3{} {C:inactive}Seals stacked){}", }, - { - "Adds a {C:attention}Brick Seal Collectable{}", - "when this Joker is obtained", - "{C:inactive}(Must have room){}" - } } + { + "Adds a {C:attention}Brick Seal Collectable{}", + "when this Joker is obtained", + "{C:inactive}(Must have room){}" + } } }, j_artb_ascii = { @@ -231,7 +243,7 @@ return { "Each card in hand gives", "{C:mult}+#1#{} Mult for its and every", "unique rank to the left" - } } + }} }, j_artb_gold_plating = { @@ -245,7 +257,77 @@ return { "to give its {C:attention}sell value{}", "to a Joker to the right" }} - } + }, + + j_artb_stained_glass = { + name = 'Stained Glass', + text = {{ + "{C:attention}Glass Cards{} create an", + "{C:attention}Art card{} when scored, and a", + "{C:attention}Creative Tag{} when shattered" + }} + }, + + j_artb_paint_chips = { + name = 'Paint Chips', + text = {{ + "{X:chips,C:white}X#2#{} Chips", + "{X:mult,C:white}X#1#{} Mult", + }} + }, + + j_artb_heist = { + name = 'Heist', + text = {{ + "When {C:attention}Blind{} is selected,", + "steals {C:attention}sell value{} of", + "the Joker to the right" + }, + { + "gives Mult equal to three", + "times this Jokers {C:attention}sell value{}", + "{C:inactive}(Currently: {C:mult}+#1#{} {C:inactive}Mult)" + }} + }, + + j_artb_null_pointer = { + name = 'Null Pointer', + text = {{ + "Fills all empty consumable", + "slots with random rankless", + "{C:attention}Collectable enhancements{}", + "when {C:attention}obtained{} or {C:attention}sold{}" + }} + }, + + j_artb_card_binder = { + name = 'Card Binder', + text = {{ + "{C:attention}+#1#{} hand size when", + "not in a {C:attention}Blind{}" + }} + }, + + j_artb_paint_bucket = { + name = 'Paint Bucket', + text = {{ + "For the next {C:attention}#1#{} hands", + "give one random {C:attention}Enhancement{}", + "to all scored cards with same", + "{C:attention}Rank{} as first scoring card" + }} + }, + + j_artb_sparkledog = { + name = 'Sparkledog', + text = {{ + "{C:chips}#1#{} Chips for each", + "unique {C:attention}enhancement{}, {C:attention}seal{}", + "and {C:attention}edition{} in {C:attention}full deck{}", + "{C:inactive}(Currently: {C:chips}#2#{} {C:inactive}Chips)" + }} + }, + }, @@ -287,6 +369,27 @@ return { "{C:attention}1{} selected playing card", } }, + c_artb_gros_michel_collectable = { + name = 'Gros Michel Collectable', + text = { + "{C:mult}+#1#{} Mult", + "If you already have", + "a {C:attention}Gros Michel Collectable{}", + "destroys this and gives", + "the other one {C:mult}+#2#{} Mult" + } + }, + c_artb_cavendish_collectable = { + name = 'Cavendish Collectable', + text = { + "{X:mult,C:white}X#1#{} Mult", + "If you already have", + "a {C:attention}Cavendish Collectable{}", + "destroys this and gives", + "the other one {X:mult,C:white}X#2#{} Mult" + } + }, + }, Tag = { tag_artb_creative = { @@ -394,7 +497,7 @@ return { 'playing card and', 'creates Collectables of its', '{C:attention}Edition{}, {C:attention}Seal{} and {C:attention}Enhancement{}', - '{C:inactive}(Must have room)' + '{C:inactive}(Must have room){}' } }, @@ -415,6 +518,45 @@ return { "{C:attention}Marble Card{}", } }, + + c_artb_art_mystery_box = { + name = 'Mystery Box', + text = { + "Fills all empty consumable", + "slots with random", + "{C:attention}Modifier Collectables{}", + } + }, + + c_artb_art_still_life = { + name = 'Still Life', + text = { + "creates a", + "{C:attention}Gros Michel Collectable{}", + "{C:inactive}(Must have room, or another{}", + "{C:inactive}Gros Michel Collectable already){}" + } + }, + + c_artb_art_pottery = { + name = 'Pottery', + text = { + "Enchances {C:attention}#1#{}", + "selected cards to", + "{C:attention}Clay Cards{}", + } + }, + }, + Planet={ + c_artb_vesta={ + name="Vesta", + text={ + "{S:0.8}({S:0.8,V:1}lvl.#1#{S:0.8}){} Level up", + "{C:attention}Null", + "{C:mult}+3{} Mult and", + "{C:chips}+40{} chips", + }, + }, }, Spectral = { c_artb_infinity = { @@ -460,11 +602,22 @@ return { name = 'Marble Card', text = { "No rank or suit,", - "Gives {X:chips,C:white}X2{} Chips", "after being played {C:attention}4{} times", + "Gives {X:chips,C:white}X2{} Chips and is", + "considered a {C:attention}face{} card", "{C:inactive}(#2#/4){}" } }, + + m_artb_clay = { + name = 'Clay Card', + text = { + "{C:mult}+#1#{} permanent Mult when drawn,", + "first time this card is held in hand", + "when score {C:attention}catches fire{} loses abilities", + "and {C:attention}doubles{} permanent Mult", + } + }, }, Voucher = { v_artb_booster_stack = { diff --git a/lovely/collectable.toml b/lovely/collectable.toml index 7e1e78b..18ad300 100644 --- a/lovely/collectable.toml +++ b/lovely/collectable.toml @@ -13,7 +13,7 @@ if card.ability.consumeable then ''' position = "after" payload = ''' - if card.config.center.key == 'c_artb_joker_collectable' or card.config.center.key == 'c_artb_limited_edition_collectable' then + if card.config.center.key == 'c_artb_joker_collectable' or card.config.center.key == 'c_artb_limited_edition_collectable' or card.config.center.key == 'c_artb_gros_michel_collectable' or card.config.center.key == 'c_artb_cavendish_collectable' then return { n=G.UIT.ROOT, config = {padding = 0, colour = G.C.CLEAR}, nodes={ {n=G.UIT.C, config={padding = 0.15, align = 'cl'}, nodes={ diff --git a/other/friends.lua b/other/friends.lua new file mode 100644 index 0000000..992a661 --- /dev/null +++ b/other/friends.lua @@ -0,0 +1,35 @@ +SMODS.Atlas { + key = "inscryption_LC", + path = "collabs/inscryption_face_cards_lc.png", + px = 71, + py = 95 +} + +SMODS.Atlas { + key = "inscryption_HC", + path = "collabs/inscryption_face_cards_hc.png", + px = 71, + py = 95 +} + +SMODS.DeckSkin { + key = 'inscryption', + suit = 'Spades', + loc_txt = "Inscryption", + palettes = { + { + key = 'Low Contrast Colours', + ranks = {'Jack', 'Queen', 'King'}, + display_ranks = {'King', 'Queen', 'Jack'}, + pos_style = 'collab', + atlas = 'artb_inscryption_LC' + }, + { + key = 'High Contrast Colours', + ranks = {'Jack', 'Queen', 'King'}, + display_ranks = {'King', 'Queen', 'Jack'}, + pos_style = 'collab', + atlas = 'artb_inscryption_HC', + } + } +} \ No newline at end of file diff --git a/other/hands.lua b/other/hands.lua new file mode 100644 index 0000000..3f9608a --- /dev/null +++ b/other/hands.lua @@ -0,0 +1,53 @@ +SMODS.PokerHand { + key = 'null', + visible = false, + chips = 130, + mult = 13, + l_chips = 40, + l_mult = 3, + example = { + { "S_A", true, enhancement = "m_stone" }, + { "S_A", true, enhancement = "m_stone" }, + { "S_A", true, enhancement = "m_artb_marble" }, + { "S_A", true, enhancement = "m_artb_stained" }, + { "S_A", true, enhancement = "m_artb_marble" }, + }, + evaluate = function(parts, hand) + if ArtBox_config.null_hand then + local _scoring = {} + for _, card in ipairs(hand) do + if SMODS.has_no_rank(card) then + _scoring[#_scoring + 1] = card + end + end + if #_scoring >= 5 then return { _scoring } end + end + end +} + +SMODS.Consumable { + set = "Planet", + key = "vesta", + pos = { x = 1, y = 0 }, + discovered = true, + config = { + hand_type = "artb_null", + softlock = true + }, + atlas = "spectral_atlas", + loc_vars = function(self, info_queue, center) + return { + vars = { + G.GAME.hands["artb_null"].level, + localize("artb_null"), + G.GAME.hands["artb_null"].l_mult, + G.GAME.hands["artb_null"].l_chips, + colours = { (to_big(G.GAME.hands["artb_null"].level) == to_big(1) and G.C.UI.TEXT_DARK or G.C.HAND_LEVELS[math.min(7, G.GAME.hands["artb_null"].level)]) } + } + } + end, + set_card_type_badge = function(self, card, badges) + badges[#badges + 1] = create_badge(localize('artb_protoplanet'), get_type_colour(card.config.center, card), + nil, 1.2) + end +} diff --git a/upgrades/clay.lua b/upgrades/clay.lua new file mode 100644 index 0000000..a293035 --- /dev/null +++ b/upgrades/clay.lua @@ -0,0 +1,72 @@ +SMODS.Enhancement({ + key = "clay", + atlas = "enhancers_atlas", + pos = { x = 0, y = 2 }, + discovered = true, + config = { + extra = { + mult = 1, + fired = false + } + }, + + loc_vars = function(self, info_queue, card) + return { + vars = { + card.ability.extra.mult, + } + } + end, + + calculate = function(self, card, context) + if context.hand_drawn then + for _, playing_card in ipairs(context.hand_drawn) do + if playing_card == card and card.ability.extra.fired == false then + card.ability.perma_mult = card.ability.perma_mult + card.ability.extra.mult + return { + extra = { message = localize('k_upgrade_ex'), colour = G.C.MULT }, + card = card + } + end + end + end + + if context.other_drawn then + for _, playing_card in ipairs(context.other_drawn) do + if playing_card == card and card.ability.extra.fired == false then + card.ability.perma_mult = card.ability.perma_mult + card.ability.extra.mult + return { + extra = { message = localize('k_upgrade_ex'), colour = G.C.MULT }, + card = card + } + end + end + end + + if context.final_scoring_step and card.ability.extra.fired == false and context.cardarea == G.hand and to_big(G.GAME.blind.chips) <= to_big(hand_chips) * to_big(mult) then + card.ability.perma_mult = card.ability.perma_mult * 2 + G.E_MANAGER:add_event(Event({ + trigger = 'before', + func = function() + card.ability.extra.fired = true + return true; + end + })) + return { + sound = 'tarot1', + message = localize('artb_fired'), + colour = G.C.MULT + } + end + end, + + draw = function(self, card, layer) + if (layer == 'card' or layer == 'both') then + if card.ability.extra.fired then + card.children.center:set_sprite_pos({ x = 1, y = 2 }) + else + card.children.center:set_sprite_pos({ x = 0, y = 2 }) + end + end + end +}) diff --git a/upgrades/marble.lua b/upgrades/marble.lua index f93f8a3..ff3566e 100644 --- a/upgrades/marble.lua +++ b/upgrades/marble.lua @@ -31,7 +31,7 @@ SMODS.Enhancement({ card.ability.extra.progress = card.ability.extra.progress + 1 card:juice_up() - if card.ability.extra.progress == 4 then + if card.ability.extra.progress >= 4 then card.ability.x_chips = 2 end return true @@ -42,7 +42,24 @@ SMODS.Enhancement({ draw = function(self, card, layer) if (layer == 'card' or layer == 'both') then - card.children.center:set_sprite_pos({ x = card.ability.extra.progress, y = 1 }) + if card.ability.extra.progress < 4 then + card.children.center:set_sprite_pos({ x = card.ability.extra.progress, y = 1 }) + else + card.children.center:set_sprite_pos({ x = 4, y = 1 }) + end + end end }) + +local card_isfaceref = Card.is_face + +function Card:is_face(from_boss) + if self.debuff and not from_boss then return end + + if self.config.center == G.P_CENTERS.m_artb_marble and self.ability.extra.progress >= 4 then + return true + end + + return card_isfaceref(self, from_boss) +end diff --git a/upgrades/wood.lua b/upgrades/wood.lua index 5aeeacb..87c6c7f 100644 --- a/upgrades/wood.lua +++ b/upgrades/wood.lua @@ -5,7 +5,7 @@ SMODS.Enhancement({ discovered = true, config = { extra = { - chips=2 + chips=3 } },