From e767c7651b82d22ff924988f32e3729f80c258aa Mon Sep 17 00:00:00 2001 From: Emik Date: Mon, 7 Apr 2025 13:43:06 +0200 Subject: [PATCH] Buff obsidian deck, nerf Betmma, improve localization --- manifest.json | 2 +- src/back.lua | 28 ++++++++++++++++++++++++++-- src/joker.lua | 5 +++-- src/misprintize.lua | 4 ++-- src/slugcat.lua | 12 +++++++----- src/spectral.lua | 9 +++++---- src/tarot.lua | 6 ++++-- src/token.lua | 9 +++++---- src/voucher.lua | 5 +---- 9 files changed, 54 insertions(+), 26 deletions(-) diff --git a/manifest.json b/manifest.json index 82e3456..a67766d 100644 --- a/manifest.json +++ b/manifest.json @@ -17,5 +17,5 @@ "conflicts": [ "Jen" ], - "version": "1.0.5" + "version": "1.0.6" } \ No newline at end of file diff --git a/src/back.lua b/src/back.lua index bc46567..9452967 100644 --- a/src/back.lua +++ b/src/back.lua @@ -21,6 +21,13 @@ SMODS.Back { Cryptid and "an {C:spectral,E:1}Empowered Tag" or "create a {C:dark_edition}Negative {C:spectral,E:1}Soul", }, }, + loc_vars = function(_, info_queue, _) + if info_queue then + info_queue[#info_queue + 1] = Cryptid and G.P_CENTERS.c_cry_empowered or G.P_CENTERS.c_soul + end + + return {vars = {}} + end, apply = function(_) G.GAME.win_ante = Cryptid and G.GAME.win_ante * (G.GAME.win_ante + 1) / 2 or G.GAME.win_ante * 2 - 1 G.GAME.nitro = true @@ -120,12 +127,27 @@ SMODS.Back { loc_txt = { name = "Obsidian Deck", text = { - "{C:attention}Hidden{} cards {C:inactive}(ex. {C:spectral}The Soul{C:inactive})", + "{C:attention}Hidden{} cards {C:inactive}(ex. {C:spectral}Black Hole{C:inactive})", "can {C:attention}appear normally{}", + "Start run with {C:tarot}Omen Globe", }, }, + loc_vars = function(_, info_queue, _) + if info_queue then + info_queue[#info_queue + 1] = G.P_CENTERS.v_omen_globe + end + + return {vars = {}} + end, apply = function(_) G.GAME.obsidian = true + G.GAME.used_vouchers.v_omen_globe = true + G.GAME.starting_voucher_count = (G.GAME.starting_voucher_count or 0) + 1 + + Jane.q(function() + Card.apply_to_run(nil, G.P_CENTERS.v_omen_globe) + return true + end) end, } @@ -242,15 +264,17 @@ SMODS.Back { }, apply = function(_) apply_orrery() + G.GAME.used_vouchers.v_omen_globe = true + G.GAME.starting_voucher_count = (G.GAME.starting_voucher_count or 0) + 1 G.E_MANAGER:add_event(Event({ func = function() local wee = create_card("Joker", G.jokers, nil, nil, nil, nil, "j_wee", "weeck") G.jokers:emplace(wee) add_rain_world_joker() - G.GAME.mysterious = true G.GAME.tortoise = true G.GAME.obsidian = true + G.GAME.mysterious = true save_run() return true end, diff --git a/src/joker.lua b/src/joker.lua index bfe96ff..77a44f3 100644 --- a/src/joker.lua +++ b/src/joker.lua @@ -381,7 +381,8 @@ SMODS.Joker { blueprint_compat = true, cost = Cryptid and 8 or 20, rarity = Cryptid and 3 or 4, - loc_vars = function(_, _, card) + loc_vars = function(_, info_queue, card) + info_queue[#info_queue + 1] = G.P_CENTERS.m_steel local ability = card.ability.extra or {} local milestone = ability.milestone local progress = ability.progress @@ -497,7 +498,7 @@ SMODS.Joker { "{C:inactive}(Currently {X:dark_edition,C:chips}" .. operator .. "#2#{C:inactive})", }, }, - config = {big_num_scaler = true, extra = {tet = Cryptid and 0.1 or 0.5}}, + config = {big_num_scaler = true, extra = {tet = Cryptid and 0.1 or 0.25}}, pos = {x = 0, y = 0}, soul_pos = {x = 1, y = 0}, blueprint_compat = true, diff --git a/src/misprintize.lua b/src/misprintize.lua index a8c70f3..c95267f 100644 --- a/src/misprintize.lua +++ b/src/misprintize.lua @@ -2,7 +2,7 @@ -- https://github.com/MathIsFun0/Cryptid/blob/main/lib/misprintize.lua local base_values = {} -local big_num_whitelist = { +local big_num_allowlist = { j_egg = true, j_wee = true, j_flash = true, @@ -101,7 +101,7 @@ local function is_card_big(joker) return false end - return big_num_whitelist[center.key or "Nope!"] + return big_num_allowlist[center.key or "Nope!"] end local function log_random(seed, min, max) diff --git a/src/slugcat.lua b/src/slugcat.lua index 3b2742f..9ee63ac 100644 --- a/src/slugcat.lua +++ b/src/slugcat.lua @@ -123,11 +123,12 @@ SMODS.Joker { soul_pos = {x = 1, y = 0}, cost = Cryptid and 20 or 8, rarity = Cryptid and 4 or 3, - loc_vars = function(_, _, card) + loc_vars = function(_, info_queue, card) local function rounds(amount) return " round" .. ((math.abs(amount) > 1 or math.abs(amount) == 0) and "s" or "") end + info_queue[#info_queue + 1] = Cryptid and G.P_CENTERS.c_cry_empowered or G.P_CENTERS.c_soul local rounds_left = card.ability.extra.rounds_left local sold = rounds_left - hunter[3] @@ -420,8 +421,7 @@ function Card:draw(layer) if cen and self.facing == "front" and self.config and - (self.added_to_deck or - (self.area and self.area == G.hand)) and not + (self.added_to_deck or (self.area and self.area == G.hand)) and not self.edition and (self.area == G.consumeables or cen.set ~= "Booster") and next(SMODS.find_card("j_jane_rivulet")) then @@ -444,7 +444,7 @@ SMODS.Joker { "{C:inactive,s:1.25}#9#{C:attention,s:1.25}#10#{C:inactive,s:1.25}#11#{C:inactive}#12#", } or { "{C:spectral}Ankh {}will {C:attention}not destroy Jokers", - "{C:jane_RGB}#2#{}#3#{C:dark_edition}#4#{}#5#", + "{C:jane_RGB}#2#{}#3#{C:dark_edition}#4#{C:spectral}#5#", "{C:inactive,s:1.25}#6#{C:attention,s:1.25}#7#{C:inactive,s:1.25}#8#{C:inactive}#9#", }, }, @@ -454,7 +454,9 @@ SMODS.Joker { cost = 20, rarity = 4, blueprint_compat = true, - loc_vars = function(_, _, card) + loc_vars = function(_, info_queue, card) + info_queue[#info_queue + 1] = G.P_CENTERS.c_ankh + info_queue[#info_queue + 1] = Cryptid and G.P_CENTERS.c_cry_gateway or G.P_CENTERS.c_soul local extra = card.ability.extra local karma = extra.karma local max_karma = extra.max_karma diff --git a/src/spectral.lua b/src/spectral.lua index 77f8ea5..a185fb6 100644 --- a/src/spectral.lua +++ b/src/spectral.lua @@ -220,7 +220,7 @@ SMODS.Consumable { name = "Conjure", text = { "Creates {C:attention}#1#", - "{C:spectral}Spectral{} cards", + "{C:spectral}Spectral {}cards", "{C:inactive}(Must have room)", }, }, @@ -278,8 +278,9 @@ SMODS.Consumable { G.jokers.cards[i].extra_cost = 0 G.jokers.cards[i].cost = 0 G.jokers.cards[i].sell_cost = 0 - G.jokers.cards[i].sell_cost_label = G.jokers.cards[i].facing == "back" and "?" or G.jokers.cards[i] - .sell_cost + + G.jokers.cards[i].sell_cost_label = G.jokers.cards[i].facing == "back" and "?" or + G.jokers.cards[i].sell_cost end end, bulk_use = function(_, card, _, _, number) @@ -315,7 +316,7 @@ SMODS.Consumable { loc_txt = { name = "Rift", text = { - "{C:attention}Reset{} your deck to a", + "{C:attention}Reset {}your deck to a", "{C:attention}standard 52-card deck", }, }, diff --git a/src/tarot.lua b/src/tarot.lua index 3d87605..3e36b99 100644 --- a/src/tarot.lua +++ b/src/tarot.lua @@ -37,8 +37,10 @@ SMODS.Consumable { "{C:inactive,E:1}#1#{}", }, }, - loc_vars = function(_, _, _) - return {vars = {blurbs[math.random(#blurbs)]}} + loc_vars = function(_, info_queue, card) + info_queue[#info_queue + 1] = G.P_CENTERS.j_joker + card.blurb = card.blurb or pseudorandom_element(blurbs, pseudoseed("jokerinatarotblurbs")) + return {vars = {card.blurb}} end, pos = {x = 0, y = 1}, cost = 4, diff --git a/src/token.lua b/src/token.lua index 5b3d223..d9f3e5c 100644 --- a/src/token.lua +++ b/src/token.lua @@ -86,11 +86,12 @@ for _, v in pairs({ atlas = "janetokens", loc_txt = { name = v[2] .. " Token", - text = { - "Use to create a", - "{C:attention}" .. v[2] .. " Tag", - }, + text = {"Use to create a", "{C:attention}" .. v[2] .. " Tag"}, }, + loc_vars = function(_, info_queue, _) + info_queue[#info_queue + 1] = G.P_TAGS[v[1]] + return {vars = {v[2]}} + end, pos = {x = v[3], y = v[4]}, cost = v[5], can_stack = true, diff --git a/src/voucher.lua b/src/voucher.lua index 7d4753a..72a6cdc 100644 --- a/src/voucher.lua +++ b/src/voucher.lua @@ -10,10 +10,7 @@ SMODS.Voucher { atlas = "janetokenvoucher", loc_txt = { name = "Token Voucher", - text = { - "{C:attention}Tokens {}can appear", - "in the shop", - }, + text = {"{C:attention}Tokens {}can appear", "in the shop"}, }, pos = {x = 0, y = 0}, cost = 15,