Add doubled deck-sleeve combos, I regret nothing
This commit is contained in:
parent
ff09fc2722
commit
abf64c33d6
8 changed files with 673 additions and 433 deletions
|
|
@ -17,5 +17,5 @@
|
||||||
"conflicts": [
|
"conflicts": [
|
||||||
"Jen"
|
"Jen"
|
||||||
],
|
],
|
||||||
"version": "1.2.1"
|
"version": "1.3.0"
|
||||||
}
|
}
|
||||||
579
src/back.lua
579
src/back.lua
|
|
@ -6,18 +6,85 @@ SMODS.Atlas {
|
||||||
}
|
}
|
||||||
|
|
||||||
local function back(x)
|
local function back(x)
|
||||||
|
local key = x.key
|
||||||
|
local apply = x.apply
|
||||||
|
local calculate = x.calculate
|
||||||
|
|
||||||
|
x.apply = function(...)
|
||||||
|
if apply and G.GAME.selected_sleeve ~= "sleeve_jane_" .. key then
|
||||||
|
return apply(...)
|
||||||
|
end
|
||||||
|
|
||||||
|
Jane.q(function()
|
||||||
|
save_run()
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
|
||||||
|
x.calculate = function(...)
|
||||||
|
if calculate and G.GAME.selected_sleeve ~= "sleeve_jane_" .. key then
|
||||||
|
return calculate(...)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
SMODS.Back(x)
|
SMODS.Back(x)
|
||||||
local text = x.loc_txt.text
|
local text = x.loc_txt.text
|
||||||
local name = x.loc_txt.name:gsub("Deck$", "Sleeve")
|
local name = x.loc_txt.name:gsub("Deck$", "Sleeve")
|
||||||
|
|
||||||
|
if not CardSleeves then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
G.localization.descriptions.Sleeve = G.localization.descriptions.Sleeve or {}
|
||||||
|
G.localization.descriptions.Sleeve["sleeve_jane_" .. key .. "_alt"] = x.alt_loc_txt
|
||||||
|
|
||||||
CardSleeves.Sleeve {
|
CardSleeves.Sleeve {
|
||||||
key = x.key,
|
key = key,
|
||||||
pos = x.pos,
|
pos = x.pos,
|
||||||
apply = x.apply,
|
|
||||||
atlas = "janedecks",
|
atlas = "janedecks",
|
||||||
loc_vars = x.loc_vars,
|
|
||||||
trigger_effect = x.trigger_effect,
|
|
||||||
loc_txt = {name = name, text = text},
|
loc_txt = {name = name, text = text},
|
||||||
|
apply = function(self, ...)
|
||||||
|
-- Game becomes genuinely unplayable if this is allowed.
|
||||||
|
-- if self.get_current_deck_key() == "b_jane_omega" and G.GAME.selected_sleeve == "sleeve_jane_omega" then
|
||||||
|
-- if apply then
|
||||||
|
-- apply(self, ...)
|
||||||
|
-- end
|
||||||
|
-- if x.alt_apply then
|
||||||
|
-- x.alt_apply(self, ...)
|
||||||
|
-- end
|
||||||
|
-- return
|
||||||
|
-- end
|
||||||
|
local a = (self.get_current_deck_key() == "b_jane_" .. key and x.alt_apply or apply)
|
||||||
|
|
||||||
|
if a then
|
||||||
|
a(self, ...)
|
||||||
|
end
|
||||||
|
|
||||||
|
Jane.q(function()
|
||||||
|
save_run()
|
||||||
|
end)
|
||||||
|
end,
|
||||||
|
calculate = function(self, ...)
|
||||||
|
-- Game becomes genuinely unplayable if this is allowed.
|
||||||
|
-- if self.get_current_deck_key() == "b_jane_omega" and G.GAME.selected_sleeve == "sleeve_jane_omega" then
|
||||||
|
-- if calculate then
|
||||||
|
-- calculate(self, ...)
|
||||||
|
-- end
|
||||||
|
-- if x.alt_calculate then
|
||||||
|
-- x.alt_calculate(self, ...)
|
||||||
|
-- end
|
||||||
|
-- return
|
||||||
|
-- end
|
||||||
|
local c = (self.get_current_deck_key() == "b_jane_" .. key and x.alt_calculate or calculate)
|
||||||
|
|
||||||
|
if c then
|
||||||
|
return c(self, ...)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
loc_vars = function(self, ...)
|
||||||
|
local ret = x.loc_vars and x.loc_vars(self, ...) or {}
|
||||||
|
ret.key = self.get_current_deck_key() == "b_jane_" .. key and self.key .. "_alt" or self.key
|
||||||
|
return ret
|
||||||
|
end,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -37,58 +104,82 @@ back {
|
||||||
Cryptid and "an {C:spectral,E:1}Empowered Tag" or "create a {C:dark_edition}Negative {C:spectral,E:1}Soul",
|
Cryptid and "an {C:spectral,E:1}Empowered Tag" or "create a {C:dark_edition}Negative {C:spectral,E:1}Soul",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Jolt Sleeve",
|
||||||
|
text = {
|
||||||
|
Cryptid and "{C:attention}Ante number {}scales with {C:attention}square numbers" or "{C:attention}Ante increases twice{} as strong",
|
||||||
|
"After defeating the {C:attention}Small {}or {C:attention}Big Blind{},",
|
||||||
|
Cryptid and "create a {C:spectral,E:1}Empowered Tag" or "create a {C:dark_edition}Negative {C:spectral,E:1}Soul",
|
||||||
|
},
|
||||||
|
},
|
||||||
loc_vars = function(_, info_queue, _)
|
loc_vars = function(_, info_queue, _)
|
||||||
if info_queue then
|
if info_queue then
|
||||||
info_queue[#info_queue + 1] = Cryptid and G.P_CENTERS.c_cry_empowered or G.P_CENTERS.c_soul
|
info_queue[#info_queue + 1] = Cryptid and G.P_TAGS.tag_cry_empowered or G.P_CENTERS.c_soul
|
||||||
end
|
end
|
||||||
|
|
||||||
return {vars = {}}
|
return {vars = {}}
|
||||||
end,
|
end,
|
||||||
|
alt_apply = function(_)
|
||||||
|
G.GAME.win_ante = Cryptid and G.GAME.win_ante * G.GAME.win_ante or G.GAME.win_ante * 4 - 1
|
||||||
|
G.GAME.alt_nitro = true
|
||||||
|
G.GAME.nitro = true
|
||||||
|
end,
|
||||||
apply = function(_)
|
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.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
|
G.GAME.nitro = true
|
||||||
end,
|
end,
|
||||||
trigger_effect = function(_, args)
|
alt_calculate = function(_, _, context)
|
||||||
if args.context == "eval" and G.GAME.last_blind and G.GAME.last_blind.boss then
|
if context.end_of_round and not context.individual and not context.repetition and not context.retrigger_joker then
|
||||||
|
Jane.q(function()
|
||||||
|
Jane.empowered()
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
calculate = function(_, _, context)
|
||||||
|
if Jane.is_end_of_ante(context) then
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
Jane.empowered()
|
Jane.empowered()
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
local rain_world_jokers = {
|
||||||
|
"j_jane_monk",
|
||||||
|
"j_jane_survivor",
|
||||||
|
"j_jane_hunter",
|
||||||
|
"j_jane_gourmand",
|
||||||
|
"j_jane_artificer",
|
||||||
|
"j_jane_spearmaster",
|
||||||
|
"j_jane_rivulet",
|
||||||
|
"j_jane_saint",
|
||||||
|
"j_jane_rot",
|
||||||
|
}
|
||||||
|
|
||||||
|
local is_rain_world_joker = {}
|
||||||
|
|
||||||
|
for _, v in pairs(rain_world_jokers) do
|
||||||
|
is_rain_world_joker[v] = true
|
||||||
|
end
|
||||||
|
|
||||||
local function add_rain_world_joker()
|
local function add_rain_world_joker()
|
||||||
if not G.jokers then
|
if not G.jokers then
|
||||||
return true
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
local candidates = {
|
|
||||||
"j_jane_monk",
|
|
||||||
"j_jane_survivor",
|
|
||||||
"j_jane_hunter",
|
|
||||||
"j_jane_gourmand",
|
|
||||||
"j_jane_artificer",
|
|
||||||
"j_jane_spearmaster",
|
|
||||||
"j_jane_rivulet",
|
|
||||||
"j_jane_saint",
|
|
||||||
"j_jane_rot",
|
|
||||||
}
|
|
||||||
|
|
||||||
local unobtained = {}
|
local unobtained = {}
|
||||||
|
|
||||||
for _, v in pairs(candidates) do
|
for _, v in pairs(rain_world_jokers) do
|
||||||
if not next(SMODS.find_card(v, true)) then
|
if not next(SMODS.find_card(v, true)) then
|
||||||
unobtained[#unobtained + 1] = v
|
unobtained[#unobtained + 1] = v
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
local chosen = pseudorandom_element(next(unobtained) and unobtained or candidates, pseudoseed("karma_deck"))
|
local chosen = pseudorandom_element(next(unobtained) and unobtained or rain_world_jokers, pseudoseed("karma_deck"))
|
||||||
local card = create_card("Joker", G.jokers, nil, nil, nil, nil, chosen, "karma_deck_next")
|
local card = create_card("Joker", G.jokers, nil, nil, nil, nil, chosen, "karma_deck_next")
|
||||||
card:add_to_deck()
|
card:add_to_deck()
|
||||||
card:start_materialize()
|
card:start_materialize()
|
||||||
G.jokers:emplace(card)
|
G.jokers:emplace(card)
|
||||||
return true
|
|
||||||
end
|
end
|
||||||
|
|
||||||
back {
|
back {
|
||||||
|
|
@ -103,11 +194,61 @@ back {
|
||||||
"{C:attention}Boss Blind {}is defeated",
|
"{C:attention}Boss Blind {}is defeated",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
apply = function(_)
|
alt_loc_txt = {
|
||||||
G.E_MANAGER:add_event(Event({func = add_rain_world_joker}))
|
name = "Ascension Sleeve",
|
||||||
|
text = {
|
||||||
|
"Start with all {C:legendary}Rain World Jokers {}instead",
|
||||||
|
"Destroy a random {C:legendary}Rain World Joker {}when",
|
||||||
|
"{C:attention}Boss Blind {}is defeated, or {C:red}lose",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
alt_apply = function(_)
|
||||||
|
for _, v in ipairs(rain_world_jokers) do
|
||||||
|
Jane.q(function()
|
||||||
|
local card = create_card("Joker", G.jokers, nil, nil, nil, nil, v, "karma_deck_next")
|
||||||
|
card:add_to_deck()
|
||||||
|
card:start_materialize()
|
||||||
|
G.jokers:emplace(card)
|
||||||
|
play_sound("timpani")
|
||||||
|
end, 0.2)
|
||||||
|
end
|
||||||
end,
|
end,
|
||||||
trigger_effect = function(_, args)
|
apply = function(_)
|
||||||
if args.context == "eval" and G.GAME.last_blind and G.GAME.last_blind.boss then
|
Jane.q(add_rain_world_joker)
|
||||||
|
end,
|
||||||
|
alt_calculate = function(_, _, context)
|
||||||
|
local function l()
|
||||||
|
if G.STAGE == G.STAGES.RUN then
|
||||||
|
G.STATE = G.STATES.GAME_OVER
|
||||||
|
G.STATE_COMPLETE = false
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if not Jane.is_end_of_ante(context) then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
local destructible_jokers = {}
|
||||||
|
|
||||||
|
for _, v in pairs(G.jokers.cards) do
|
||||||
|
if is_rain_world_joker[v.config.center.key] and not ((v.ability or {}).eternal or (v.ability or {}).cry_absolute) then
|
||||||
|
destructible_jokers[#destructible_jokers + 1] = v
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if not next(destructible_jokers) then
|
||||||
|
return l()
|
||||||
|
end
|
||||||
|
|
||||||
|
local chosen = pseudorandom_element(destructible_jokers, pseudoseed("karma_deck"))
|
||||||
|
|
||||||
|
if chosen then
|
||||||
|
chosen.getting_sliced = true
|
||||||
|
chosen:start_dissolve()
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
calculate = function(_, _, context)
|
||||||
|
if Jane.is_end_of_ante(context) then
|
||||||
add_rain_world_joker()
|
add_rain_world_joker()
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
|
@ -126,16 +267,44 @@ back {
|
||||||
"to your possession",
|
"to your possession",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Sleeve?",
|
||||||
|
text = {"{C:attention}Ante order {}is {C:green,E:1}randomized"},
|
||||||
|
},
|
||||||
|
alt_apply = function(_)
|
||||||
|
G.GAME.mysterious = true
|
||||||
|
G.GAME.alt_mysterious = {}
|
||||||
|
|
||||||
|
for i = G.GAME.round_resets.ante + 1, G.GAME.round_resets.ante + G.GAME.win_ante - 1 do
|
||||||
|
G.GAME.alt_mysterious[#G.GAME.alt_mysterious + 1] = {i}
|
||||||
|
end
|
||||||
|
|
||||||
|
pseudoshuffle(G.GAME.alt_mysterious, pseudoseed("mysterious_deck"))
|
||||||
|
end,
|
||||||
apply = function(_)
|
apply = function(_)
|
||||||
G.GAME.mysterious = true
|
G.GAME.mysterious = true
|
||||||
|
end,
|
||||||
Jane.q(function()
|
alt_calculate = function(_, _, context)
|
||||||
save_run()
|
if context.setting_blind or context.skip_blind then
|
||||||
return true
|
G.GAME.mysterious_init = true
|
||||||
end)
|
end
|
||||||
|
end,
|
||||||
|
calculate = function(_, _, context)
|
||||||
|
if context.setting_blind or context.skip_blind then
|
||||||
|
G.GAME.mysterious_init = true
|
||||||
|
end
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
local function redeem_omen_globe()
|
||||||
|
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)
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
|
||||||
back {
|
back {
|
||||||
key = "obsidian",
|
key = "obsidian",
|
||||||
atlas = "janedecks",
|
atlas = "janedecks",
|
||||||
|
|
@ -148,6 +317,13 @@ back {
|
||||||
"Start run with {C:tarot}Omen Globe",
|
"Start run with {C:tarot}Omen Globe",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Bedrock Sleeve",
|
||||||
|
text = {
|
||||||
|
"{C:attention}Non-hidden {}cards do",
|
||||||
|
"not {C:attention}normally appear",
|
||||||
|
},
|
||||||
|
},
|
||||||
loc_vars = function(_, info_queue, _)
|
loc_vars = function(_, info_queue, _)
|
||||||
if info_queue then
|
if info_queue then
|
||||||
info_queue[#info_queue + 1] = G.P_CENTERS.v_omen_globe
|
info_queue[#info_queue + 1] = G.P_CENTERS.v_omen_globe
|
||||||
|
|
@ -155,15 +331,13 @@ back {
|
||||||
|
|
||||||
return {vars = {}}
|
return {vars = {}}
|
||||||
end,
|
end,
|
||||||
|
alt_apply = function(_)
|
||||||
|
G.GAME.alt_obsidian = true
|
||||||
|
redeem_omen_globe()
|
||||||
|
end,
|
||||||
apply = function(_)
|
apply = function(_)
|
||||||
G.GAME.obsidian = true
|
G.GAME.obsidian = true
|
||||||
G.GAME.used_vouchers.v_omen_globe = true
|
redeem_omen_globe()
|
||||||
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,
|
end,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -179,10 +353,83 @@ local function apply_orrery()
|
||||||
end
|
end
|
||||||
|
|
||||||
save_run()
|
save_run()
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local function rebalance_orrery()
|
||||||
|
local function small(x)
|
||||||
|
return type(x) == "table" and x:to_number() or x
|
||||||
|
end
|
||||||
|
|
||||||
|
local function hand(name, chip, mul, lv, notif, snd, vol, pit, de)
|
||||||
|
local config = {
|
||||||
|
delay = de or 0.3,
|
||||||
|
pitch = pit or 0.8,
|
||||||
|
volume = vol or 0.7,
|
||||||
|
sound = type(snd) == "string" and snd or type(snd) == "nil" and "button",
|
||||||
|
}
|
||||||
|
|
||||||
|
local vals = {
|
||||||
|
level = lv or "?",
|
||||||
|
mult = mul or "?",
|
||||||
|
StatusText = notif,
|
||||||
|
chips = chip or "?",
|
||||||
|
handname = name or "????",
|
||||||
|
}
|
||||||
|
|
||||||
|
update_hand_text(config, vals)
|
||||||
|
end
|
||||||
|
|
||||||
|
local orrery = (G.GAME or {}).orrery
|
||||||
|
|
||||||
|
if not orrery then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
local count = 0
|
||||||
|
local hands = {}
|
||||||
|
local inequalities = 0
|
||||||
|
local pools = {chips = 0, level = 0, mult = 0}
|
||||||
|
|
||||||
|
for k, v in pairs(G.GAME.hands) do
|
||||||
|
if orrery[k] and
|
||||||
|
(orrery[k].mult ~= v.mult or
|
||||||
|
orrery[k].chips ~= v.chips or
|
||||||
|
orrery[k].level ~= v.level) then
|
||||||
|
inequalities = inequalities + 1
|
||||||
|
end
|
||||||
|
|
||||||
|
count = count + 1
|
||||||
|
hands[#hands + 1] = v
|
||||||
|
pools.mult = v.mult + pools.mult
|
||||||
|
pools.chips = v.chips + pools.chips
|
||||||
|
pools.level = v.level + pools.level
|
||||||
|
end
|
||||||
|
|
||||||
|
if inequalities == 0 then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
pools.chips = pools.chips + inequalities * 150
|
||||||
|
table.sort(hands, function(x, y) return x.order > y.order end)
|
||||||
|
|
||||||
|
for i, v in ipairs(hands) do
|
||||||
|
v.mult = math.floor(pools.mult / count) + (small(pools.mult % count) >= i and 1 or 0)
|
||||||
|
v.chips = math.floor(pools.chips / count) + (small(pools.chips % count) >= i and 1 or 0)
|
||||||
|
v.level = math.floor(pools.level / count) + (small(pools.level % count) >= i and 1 or 0)
|
||||||
|
end
|
||||||
|
|
||||||
|
for k, v in pairs(G.GAME.hands) do
|
||||||
|
orrery[k] = {chips = v.chips, level = v.level, mult = v.mult}
|
||||||
|
end
|
||||||
|
|
||||||
|
hand(localize("k_all_hands"), math.floor(pools.chips / count), math.floor(pools.mult / count),
|
||||||
|
math.floor(pools.level / count))
|
||||||
|
delay(1)
|
||||||
|
update_hand_text({sound = "button", volume = 0.7, pitch = 1.1, delay = 0},
|
||||||
|
{mult = 0, chips = 0, handname = "", level = ""})
|
||||||
|
end
|
||||||
|
|
||||||
back {
|
back {
|
||||||
key = "orrery",
|
key = "orrery",
|
||||||
atlas = "janedecks",
|
atlas = "janedecks",
|
||||||
|
|
@ -194,9 +441,50 @@ back {
|
||||||
"always " .. (Cryptid and "{C:cry_ascendant}" or "{C:attention}") .. "equalized",
|
"always " .. (Cryptid and "{C:cry_ascendant}" or "{C:attention}") .. "equalized",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Ephemeris Sleeve",
|
||||||
|
text = {
|
||||||
|
"{C:blue}Hands{}, {C:red}discards{}, and {C:money}money",
|
||||||
|
"are always " .. (Cryptid and "{C:cry_ascendant}" or "{C:attention}") .. "equalized",
|
||||||
|
},
|
||||||
|
},
|
||||||
apply = function(_)
|
apply = function(_)
|
||||||
apply_orrery()
|
apply_orrery()
|
||||||
end,
|
end,
|
||||||
|
calculate = rebalance_orrery,
|
||||||
|
alt_calculate = function(_, _, context)
|
||||||
|
local function small(x)
|
||||||
|
return type(x) == "table" and x:to_number() or x
|
||||||
|
end
|
||||||
|
|
||||||
|
if context.setting_blind or context.skip_blind then
|
||||||
|
G.GAME.alt_orrery = true
|
||||||
|
end
|
||||||
|
|
||||||
|
if not G.GAME.alt_orrery then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
local dollars = G.GAME.dollars
|
||||||
|
local hands = G.GAME.current_round.hands_left
|
||||||
|
local discards = G.GAME.current_round.discards_left
|
||||||
|
local sum = hands + discards + dollars
|
||||||
|
local new_dollars = math.floor(sum / 3) - dollars
|
||||||
|
local new_hands = small(math.floor((sum + 2) / 3)) - hands
|
||||||
|
local new_discards = small(math.floor((sum + 1) / 3)) - discards
|
||||||
|
|
||||||
|
if new_dollars ~= 0 then
|
||||||
|
ease_dollars(new_dollars, true)
|
||||||
|
end
|
||||||
|
|
||||||
|
if new_hands ~= 0 then
|
||||||
|
ease_hands_played(new_hands, true)
|
||||||
|
end
|
||||||
|
|
||||||
|
if new_discards ~= 0 then
|
||||||
|
ease_discard(new_discards, true)
|
||||||
|
end
|
||||||
|
end,
|
||||||
}
|
}
|
||||||
|
|
||||||
back {
|
back {
|
||||||
|
|
@ -210,6 +498,17 @@ back {
|
||||||
"{C:attention}half{} as strong",
|
"{C:attention}half{} as strong",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Sleepy Sleeve",
|
||||||
|
text = {
|
||||||
|
"{C:attention}Ante {}changes",
|
||||||
|
"are {C:attention}inverted",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
alt_apply = function(_)
|
||||||
|
G.GAME.tortoise = true
|
||||||
|
G.GAME.alt_tortoise = true
|
||||||
|
end,
|
||||||
apply = function(_)
|
apply = function(_)
|
||||||
G.GAME.tortoise = true
|
G.GAME.tortoise = true
|
||||||
end,
|
end,
|
||||||
|
|
@ -219,6 +518,10 @@ local function apply_weeck()
|
||||||
G.GAME.weeck = true
|
G.GAME.weeck = true
|
||||||
|
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
|
if G.GAME.selected_sleeve == "sleeve_jane_omega" then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
local new_card = create_card("Joker", G.jokers, nil, nil, nil, nil, "j_wee", "weeck")
|
local new_card = create_card("Joker", G.jokers, nil, nil, nil, nil, "j_wee", "weeck")
|
||||||
new_card.ability.cry_absolute = true
|
new_card.ability.cry_absolute = true
|
||||||
new_card.ability.eternal = true
|
new_card.ability.eternal = true
|
||||||
|
|
@ -245,10 +548,23 @@ local function apply_weeck()
|
||||||
end
|
end
|
||||||
|
|
||||||
save_run()
|
save_run()
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local function two(x)
|
||||||
|
if type(x) ~= "table" then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
for k, v in pairs(x) do
|
||||||
|
if type(v) == "number" then
|
||||||
|
x[k] = 2
|
||||||
|
elseif type(v) == "table" then
|
||||||
|
two(v)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
back {
|
back {
|
||||||
key = "weeck",
|
key = "weeck",
|
||||||
atlas = "janedecks",
|
atlas = "janedecks",
|
||||||
|
|
@ -262,9 +578,58 @@ back {
|
||||||
"{C:attention}2's {}of {C:attention}each suit",
|
"{C:attention}2's {}of {C:attention}each suit",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Weeckweeck",
|
||||||
|
text = {
|
||||||
|
"Every stat and",
|
||||||
|
"card number is {C:attention}2",
|
||||||
|
"{C:inactive}(If possible)",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
alt_apply = function(_)
|
||||||
|
local p = G.GAME.starting_params
|
||||||
|
p.hands = 2
|
||||||
|
p.dollars = 2
|
||||||
|
p.discards = 2
|
||||||
|
p.hand_size = 2
|
||||||
|
G.GAME.skips = 2
|
||||||
|
p.joker_slots = 2
|
||||||
|
p.reroll_cost = 2
|
||||||
|
G.GAME.sunlevel = 2
|
||||||
|
p.boosters_in_shop = 2
|
||||||
|
p.consumable_slots = 2
|
||||||
|
p.vouchers_in_shop = 2
|
||||||
|
G.GAME.weeckweeck = true
|
||||||
|
|
||||||
|
for _, v in pairs(G.GAME.hands) do
|
||||||
|
v.mult = 2
|
||||||
|
v.chips = 2
|
||||||
|
v.level = 2
|
||||||
|
end
|
||||||
|
|
||||||
|
apply_weeck()
|
||||||
|
end,
|
||||||
apply = function(_)
|
apply = function(_)
|
||||||
apply_weeck()
|
apply_weeck()
|
||||||
end,
|
end,
|
||||||
|
alt_calculate = function(_)
|
||||||
|
for _, v in pairs(G.hand.cards) do
|
||||||
|
two(v.ability)
|
||||||
|
end
|
||||||
|
|
||||||
|
for _, v in pairs(G.jokers.cards) do
|
||||||
|
two(v.ability)
|
||||||
|
end
|
||||||
|
|
||||||
|
for _, v in pairs(G.consumeables.cards) do
|
||||||
|
two(v.ability)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|
||||||
|
local banned_keys = {
|
||||||
|
sleeve_Seen_Seen = true,
|
||||||
|
sleeve_jane_omega = true,
|
||||||
}
|
}
|
||||||
|
|
||||||
back {
|
back {
|
||||||
|
|
@ -278,33 +643,55 @@ back {
|
||||||
"of {C:attention}every Jane deck",
|
"of {C:attention}every Jane deck",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
alt_loc_txt = {
|
||||||
|
name = "Epsilon Sleeve",
|
||||||
|
text = {
|
||||||
|
"Applies {X:red,C:white}all{} effects of",
|
||||||
|
"{C:attention}every deck and sleeve",
|
||||||
|
"{X:black,C:red,E:2,s:2}UNPLAYABLE",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
alt_apply = function(_, ...)
|
||||||
|
if (Bakery_API or {}).create_charm_area then
|
||||||
|
Bakery_API.create_charm_area()
|
||||||
|
end
|
||||||
|
|
||||||
|
for _, v in pairs(G.P_CENTERS) do
|
||||||
|
if v.apply and not banned_keys[v.key] and (v.set == "Back" or v.set == "Sleeve") then
|
||||||
|
v:apply(...)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end,
|
||||||
apply = function(_)
|
apply = function(_)
|
||||||
apply_orrery()
|
apply_orrery()
|
||||||
G.GAME.used_vouchers.v_omen_globe = true
|
G.GAME.used_vouchers.v_omen_globe = true
|
||||||
G.GAME.starting_voucher_count = (G.GAME.starting_voucher_count or 0) + 1
|
G.GAME.starting_voucher_count = (G.GAME.starting_voucher_count or 0) + 1
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
func = function()
|
local wee = create_card("Joker", G.jokers, nil, nil, nil, nil, "j_wee", "weeck")
|
||||||
local wee = create_card("Joker", G.jokers, nil, nil, nil, nil, "j_wee", "weeck")
|
G.jokers:emplace(wee)
|
||||||
G.jokers:emplace(wee)
|
add_rain_world_joker()
|
||||||
add_rain_world_joker()
|
G.GAME.tortoise = true
|
||||||
G.GAME.tortoise = true
|
G.GAME.obsidian = true
|
||||||
G.GAME.obsidian = true
|
G.GAME.mysterious = true
|
||||||
G.GAME.mysterious = true
|
save_run()
|
||||||
save_run()
|
end)
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end,
|
end,
|
||||||
trigger_effect = function(_, args)
|
alt_calculate = function(_, ...)
|
||||||
|
for _, v in pairs(G.P_CENTERS) do
|
||||||
|
if v.calculate and not banned_keys[v.key] and (v.set == "Back" or v.set == "Sleeve") then
|
||||||
|
v:calculate(...)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
calculate = function(_, _, context)
|
||||||
G.GAME.mysterious = nil
|
G.GAME.mysterious = nil
|
||||||
|
|
||||||
if args.context == "eval" and G.GAME.last_blind and G.GAME.last_blind.boss then
|
if Jane.is_end_of_ante(context) then
|
||||||
add_rain_world_joker()
|
add_rain_world_joker()
|
||||||
|
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
Jane.empowered()
|
Jane.empowered()
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
|
@ -314,15 +701,36 @@ local orig_ante = ease_ante
|
||||||
|
|
||||||
---@diagnostic disable-next-line: lowercase-global
|
---@diagnostic disable-next-line: lowercase-global
|
||||||
function ease_ante(mod)
|
function ease_ante(mod)
|
||||||
local function next_triangle_number(x)
|
local function next_number(x)
|
||||||
|
if G.GAME.alt_nitro then
|
||||||
|
local n = math.sqrt(x) + 1
|
||||||
|
return n * n
|
||||||
|
end
|
||||||
|
|
||||||
local n = (math.sqrt(8 * x + 1) - 1) / 2
|
local n = (math.sqrt(8 * x + 1) - 1) / 2
|
||||||
return (n + 1) * (n + 2) / 2
|
return (n + 1) * (n + 2) / 2
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if G.GAME.alt_mysterious then
|
||||||
|
if not next(G.GAME.alt_mysterious) then
|
||||||
|
G.GAME.alt_mysterious = {}
|
||||||
|
|
||||||
|
for i = G.GAME.round_resets.ante + 1, G.GAME.round_resets.ante + G.GAME.win_ante do
|
||||||
|
G.GAME.alt_mysterious[#G.GAME.alt_mysterious + 1] = {i}
|
||||||
|
end
|
||||||
|
|
||||||
|
pseudoshuffle(G.GAME.alt_mysterious, pseudoseed("mysterious_deck"))
|
||||||
|
end
|
||||||
|
|
||||||
|
local target = G.GAME.alt_mysterious[#G.GAME.alt_mysterious][1]
|
||||||
|
G.GAME.alt_mysterious[#G.GAME.alt_mysterious] = nil
|
||||||
|
mod = target - G.GAME.round_resets.ante
|
||||||
|
end
|
||||||
|
|
||||||
if G.GAME.nitro then
|
if G.GAME.nitro then
|
||||||
mod = Cryptid and
|
mod = Cryptid and
|
||||||
(G.GAME.round_resets.ante < 0 and -G.GAME.round_resets.ante or
|
(G.GAME.round_resets.ante < 0 and -G.GAME.round_resets.ante or
|
||||||
math.ceil(next_triangle_number(G.GAME.round_resets.ante) - G.GAME.round_resets.ante)) or
|
math.ceil(next_number(G.GAME.round_resets.ante) - G.GAME.round_resets.ante)) or
|
||||||
(mod > 0 and mod * 2 or mod)
|
(mod > 0 and mod * 2 or mod)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -337,6 +745,10 @@ function ease_ante(mod)
|
||||||
mod = math.floor(mod / 2) + remainder
|
mod = math.floor(mod / 2) + remainder
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if G.GAME.alt_tortoise then
|
||||||
|
mod = mod * -1
|
||||||
|
end
|
||||||
|
|
||||||
orig_ante(mod)
|
orig_ante(mod)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -380,7 +792,6 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
end
|
end
|
||||||
|
|
||||||
c:juice_up(0.3, 0.3)
|
c:juice_up(0.3, 0.3)
|
||||||
return true
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -394,26 +805,23 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
for i = 1, #targets do
|
for i = 1, #targets do
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
trigger = "after",
|
targets[i]:flip()
|
||||||
delay = 0.15,
|
play_sound("card1", 1.15 - (i - 0.999) / (#G.hand.cards - 0.998) * 0.3)
|
||||||
func = function()
|
targets[i]:juice_up(0.3, 0.3)
|
||||||
targets[i]:flip()
|
end, 0.15)
|
||||||
play_sound("card1", 1.15 - (i - 0.999) / (#G.hand.cards - 0.998) * 0.3)
|
|
||||||
targets[i]:juice_up(0.3, 0.3)
|
Jane.q(function()
|
||||||
return true
|
targets[i]:flip()
|
||||||
end,
|
play_sound("card1", 1.15 - (i - 0.999) / (#G.hand.cards - 0.998) * 0.3)
|
||||||
}))
|
targets[i]:juice_up(0.3, 0.3)
|
||||||
|
end, 0.15)
|
||||||
end
|
end
|
||||||
|
|
||||||
delay(0.2)
|
delay(0.2)
|
||||||
|
|
||||||
for i = 1, #targets do
|
for i = 1, #targets do
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(go(i), 0.1)
|
||||||
trigger = "after",
|
|
||||||
delay = 0.1,
|
|
||||||
func = go(i),
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
@ -438,9 +846,8 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
passes = 0
|
passes = 0
|
||||||
pooling = false
|
pooling = false
|
||||||
tries = tries - 1
|
tries = tries - 1
|
||||||
|
local sd = pseudoseed(seed or "jane_rnd_mysterious")
|
||||||
selection = G.P_CENTERS
|
selection = G.P_CENTERS[pseudorandom_element(pool or G.P_CENTER_POOLS.Consumeables, sd).key]
|
||||||
[pseudorandom_element(pool or G.P_CENTER_POOLS.Consumeables, pseudoseed(seed or "jane_rnd_mysterious")).key]
|
|
||||||
|
|
||||||
if ignore_pooling then
|
if ignore_pooling then
|
||||||
pooling = true
|
pooling = true
|
||||||
|
|
@ -474,6 +881,7 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
card.created_from_split then
|
card.created_from_split then
|
||||||
card.ability.mysterious_created = true
|
card.ability.mysterious_created = true
|
||||||
local cen = card.gc and card:gc()
|
local cen = card.gc and card:gc()
|
||||||
|
|
||||||
if cen then
|
if cen then
|
||||||
if self == G.jokers then
|
if self == G.jokers then
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
|
|
@ -487,8 +895,6 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
card:juice_up(0.3, 0.3)
|
card:juice_up(0.3, 0.3)
|
||||||
play_sound("card1", 1, 0.6)
|
play_sound("card1", 1, 0.6)
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end, 0.75)
|
end, 0.75)
|
||||||
|
|
||||||
delay(0.75)
|
delay(0.75)
|
||||||
|
|
@ -504,8 +910,6 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
card:add_to_deck()
|
card:add_to_deck()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end, 0.75)
|
end, 0.75)
|
||||||
elseif self == G.consumeables then
|
elseif self == G.consumeables then
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
|
|
@ -519,8 +923,6 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
card:juice_up(0.3, 0.3)
|
card:juice_up(0.3, 0.3)
|
||||||
play_sound("card1", 1, 0.6)
|
play_sound("card1", 1, 0.6)
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end, 0.75)
|
end, 0.75)
|
||||||
|
|
||||||
delay(0.75)
|
delay(0.75)
|
||||||
|
|
@ -532,18 +934,17 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
play_sound("card3", 1, 0.6)
|
play_sound("card3", 1, 0.6)
|
||||||
|
|
||||||
card:set_ability(
|
card:set_ability(
|
||||||
rnd("mysterious_deck_consumable", cen.hidden and {} or {"hidden"}, G.P_CENTER_POOLS[cen.set])
|
rnd("mysterious_deck_consumable", cen.hidden and {} or {"hidden"},
|
||||||
|
G.P_CENTER_POOLS[cen.set])
|
||||||
)
|
)
|
||||||
|
|
||||||
if not card.added_to_deck then
|
if not card.added_to_deck then
|
||||||
card:add_to_deck()
|
card:add_to_deck()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end, 0.75)
|
end, 0.75)
|
||||||
elseif (card.base or {}).value or (card.base or {}).suit then
|
elseif (card.base or {}).value or (card.base or {}).suit then
|
||||||
randomize({card})
|
randomize({card}, not G.GAME.mysterious_init)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -551,8 +952,6 @@ function CardArea:emplace(card, location, stay_flipped)
|
||||||
if card and self then
|
if card and self then
|
||||||
orig_emplace(self, card, location, stay_flipped)
|
orig_emplace(self, card, location, stay_flipped)
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
else
|
else
|
||||||
orig_emplace(self, card, location, stay_flipped)
|
orig_emplace(self, card, location, stay_flipped)
|
||||||
|
|
|
||||||
|
|
@ -53,8 +53,6 @@ local function offset_operator(by)
|
||||||
if changed_text then
|
if changed_text then
|
||||||
play_sound("button", 1.1, 0.65)
|
play_sound("button", 1.1, 0.65)
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -113,14 +113,9 @@ SMODS.Edition({
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
on_apply = function(card)
|
on_apply = function(card)
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
blocking = false,
|
Jane.resize(card, Jane.config.wee_sizemod)
|
||||||
blockable = false,
|
end, nil, nil, nil, false, false)
|
||||||
func = function()
|
|
||||||
Jane.resize(card, Jane.config.wee_sizemod)
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
|
|
||||||
local obj = card:gc()
|
local obj = card:gc()
|
||||||
|
|
||||||
|
|
@ -139,14 +134,9 @@ SMODS.Edition({
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
on_remove = function(card)
|
on_remove = function(card)
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
blocking = false,
|
Jane.resize(card, 1 / Jane.config.wee_sizemod)
|
||||||
blockable = false,
|
end, nil, nil, nil, false, false)
|
||||||
func = function()
|
|
||||||
Jane.resize(card, 1 / Jane.config.wee_sizemod)
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
|
|
||||||
local was_added = card.added_to_deck
|
local was_added = card.added_to_deck
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,6 @@ local function grand_dad(card)
|
||||||
|
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
card:juice_up(0.5, 0.5)
|
card:juice_up(0.5, 0.5)
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
|
|
||||||
local rnd = math.random(6)
|
local rnd = math.random(6)
|
||||||
|
|
@ -454,27 +453,19 @@ SMODS.Joker {
|
||||||
(extra.progress <= 0 and extra.is_corrupted)) then
|
(extra.progress <= 0 and extra.is_corrupted)) then
|
||||||
extra.is_corrupting = true
|
extra.is_corrupting = true
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
delay = 0.1,
|
card:flip()
|
||||||
func = function()
|
play_sound("card1")
|
||||||
card:flip()
|
end, 0.1)
|
||||||
play_sound("card1")
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
delay = 1,
|
card:flip()
|
||||||
func = function()
|
card:juice_up(1, 1)
|
||||||
card:flip()
|
play_sound("card1")
|
||||||
card:juice_up(1, 1)
|
play_sound("jane_corrupt_milestone")
|
||||||
play_sound("card1")
|
extra.is_corrupted = not extra.is_corrupted
|
||||||
play_sound("jane_corrupt_milestone")
|
extra.is_corrupting = nil
|
||||||
extra.is_corrupted = not extra.is_corrupted
|
end, 1)
|
||||||
extra.is_corrupting = nil
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
|
|
||||||
if context.individual and
|
if context.individual and
|
||||||
|
|
|
||||||
168
src/main.lua
168
src/main.lua
|
|
@ -41,7 +41,7 @@ function Jane.card_status_text(
|
||||||
sound,
|
sound,
|
||||||
volume,
|
volume,
|
||||||
pitch,
|
pitch,
|
||||||
trig,
|
trigger,
|
||||||
f
|
f
|
||||||
)
|
)
|
||||||
if (delay or 0) <= 0 then
|
if (delay or 0) <= 0 then
|
||||||
|
|
@ -75,10 +75,8 @@ function Jane.card_status_text(
|
||||||
G.ROOM.jiggle = G.ROOM.jiggle + jiggle
|
G.ROOM.jiggle = G.ROOM.jiggle + jiggle
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(
|
||||||
trigger = trig,
|
function()
|
||||||
delay = delay,
|
|
||||||
func = function()
|
|
||||||
if f and type(f) == "function" then
|
if f and type(f) == "function" then
|
||||||
f(card)
|
f(card)
|
||||||
end
|
end
|
||||||
|
|
@ -108,17 +106,18 @@ function Jane.card_status_text(
|
||||||
if jiggle then
|
if jiggle then
|
||||||
G.ROOM.jiggle = G.ROOM.jiggle + jiggle
|
G.ROOM.jiggle = G.ROOM.jiggle + jiggle
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end,
|
end,
|
||||||
}))
|
delay,
|
||||||
|
nil,
|
||||||
|
trigger
|
||||||
|
)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function Jane.empowered()
|
function Jane.empowered()
|
||||||
if Cryptid then
|
if Cryptid then
|
||||||
add_tag(Tag("tag_cry_empowered"))
|
add_tag(Tag("tag_cry_empowered"))
|
||||||
return true
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
local card = create_card("Spectral", G.consumeables, nil, nil, nil, nil, "c_soul", "acceleration_soul")
|
local card = create_card("Spectral", G.consumeables, nil, nil, nil, nil, "c_soul", "acceleration_soul")
|
||||||
|
|
@ -159,19 +158,29 @@ function Jane.get_small_chipmult_sum(chips, mult)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Jane.hidden(card)
|
function Jane.hidden(card)
|
||||||
return G.GAME and not
|
local hidden = (type(card) == "table" and (card.name == "Black Hole" or card.name == "The Soul") or card.hidden)
|
||||||
G.GAME.obsidian and
|
|
||||||
type(card) == "table" and
|
if G.GAME.alt_obsidian then
|
||||||
(card.name == "Black Hole" or card.name == "The Soul" or card.hidden)
|
return not hidden
|
||||||
|
end
|
||||||
|
|
||||||
|
return G.GAME and not G.GAME.obsidian and hidden
|
||||||
|
end
|
||||||
|
|
||||||
|
function Jane.is_end_of_ante(context, card)
|
||||||
|
return not context.individual and not
|
||||||
|
context.repetition and not
|
||||||
|
(card or {}).debuff and
|
||||||
|
context.end_of_round and not
|
||||||
|
context.blueprint and
|
||||||
|
G.GAME.blind.boss and not
|
||||||
|
(G.GAME.blind.config and G.GAME.blind.config.bonus)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Jane.play_sound(sound, per, vol)
|
function Jane.play_sound(sound, per, vol)
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
func = function()
|
play_sound(sound, per, vol)
|
||||||
play_sound(sound, per, vol)
|
end)
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
|
|
||||||
function Jane.resize(card, mod, force_save)
|
function Jane.resize(card, mod, force_save)
|
||||||
|
|
@ -193,14 +202,17 @@ function Jane.resize(card, mod, force_save)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function Jane.q(fc, de, t, tr, bl, ba)
|
function Jane.q(func, delay, timer, trigger, blockable, blocking)
|
||||||
G.E_MANAGER:add_event(Event({
|
G.E_MANAGER:add_event(Event({
|
||||||
timer = t,
|
delay = delay,
|
||||||
trigger = tr,
|
timer = timer,
|
||||||
delay = de,
|
trigger = (delay and not trigger) and "after" or trigger,
|
||||||
blockable = bl,
|
blocking = blocking,
|
||||||
blocking = ba,
|
blockable = blockable,
|
||||||
func = fc,
|
func = function(...)
|
||||||
|
local ret = func(...)
|
||||||
|
return ret == nil and true or ret
|
||||||
|
end,
|
||||||
}))
|
}))
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -216,17 +228,6 @@ function Card:nosuit()
|
||||||
return self.ability.name == "Stone Card" or self.config.center.no_suit
|
return self.ability.name == "Stone Card" or self.config.center.no_suit
|
||||||
end
|
end
|
||||||
|
|
||||||
local orig_debuff = Card.set_debuff
|
|
||||||
|
|
||||||
function Card:set_debuff(should_debuff)
|
|
||||||
if should_debuff and ((self.config or {}).center or {}).debuff_immune then
|
|
||||||
Jane.card_status_text(self, "Immune", nil, 0.05 * self.T.h, G.C.RED, nil, 0.6, nil, nil, "bm", "cancel", 1, 0.9)
|
|
||||||
return false
|
|
||||||
else
|
|
||||||
orig_debuff(self, should_debuff)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
local orig_menu = Game.main_menu
|
local orig_menu = Game.main_menu
|
||||||
|
|
||||||
function Game:main_menu(change_context)
|
function Game:main_menu(change_context)
|
||||||
|
|
@ -249,82 +250,10 @@ function Game:update(dt)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
local function hand(name, chip, mul, lv, notif, snd, vol, pit, de)
|
|
||||||
local config = {
|
|
||||||
delay = de or 0.3,
|
|
||||||
pitch = pit or 0.8,
|
|
||||||
volume = vol or 0.7,
|
|
||||||
sound = type(snd) == "string" and snd or type(snd) == "nil" and "button",
|
|
||||||
}
|
|
||||||
|
|
||||||
local vals = {
|
|
||||||
level = lv or "?",
|
|
||||||
mult = mul or "?",
|
|
||||||
StatusText = notif,
|
|
||||||
chips = chip or "?",
|
|
||||||
handname = name or "????",
|
|
||||||
}
|
|
||||||
|
|
||||||
update_hand_text(config, vals)
|
|
||||||
end
|
|
||||||
|
|
||||||
local function rebalance_orrery()
|
|
||||||
local function small(x)
|
|
||||||
return type(x) == "table" and x:to_number() or x
|
|
||||||
end
|
|
||||||
|
|
||||||
local orrery = (G.GAME or {}).orrery
|
|
||||||
|
|
||||||
if not orrery then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
local count = 0
|
|
||||||
local hands = {}
|
|
||||||
local inequalities = 0
|
|
||||||
local pools = {chips = 0, level = 0, mult = 0}
|
|
||||||
|
|
||||||
for k, v in pairs(G.GAME.hands) do
|
|
||||||
if orrery[k] and
|
|
||||||
(orrery[k].mult ~= v.mult or
|
|
||||||
orrery[k].chips ~= v.chips or
|
|
||||||
orrery[k].level ~= v.level) then
|
|
||||||
inequalities = inequalities + 1
|
|
||||||
end
|
|
||||||
|
|
||||||
count = count + 1
|
|
||||||
hands[#hands + 1] = v
|
|
||||||
pools.mult = v.mult + pools.mult
|
|
||||||
pools.chips = v.chips + pools.chips
|
|
||||||
pools.level = v.level + pools.level
|
|
||||||
end
|
|
||||||
|
|
||||||
if inequalities == 0 then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
pools.chips = pools.chips + inequalities * 150
|
|
||||||
table.sort(hands, function(x, y) return x.order > y.order end)
|
|
||||||
|
|
||||||
for i, v in ipairs(hands) do
|
|
||||||
v.mult = math.floor(pools.mult / count) + (small(pools.mult % count) >= i and 1 or 0)
|
|
||||||
v.chips = math.floor(pools.chips / count) + (small(pools.chips % count) >= i and 1 or 0)
|
|
||||||
v.level = math.floor(pools.level / count) + (small(pools.level % count) >= i and 1 or 0)
|
|
||||||
end
|
|
||||||
|
|
||||||
for k, v in pairs(G.GAME.hands) do
|
|
||||||
orrery[k] = {chips = v.chips, level = v.level, mult = v.mult}
|
|
||||||
end
|
|
||||||
|
|
||||||
hand(localize("k_all_hands"), math.floor(pools.chips / count), math.floor(pools.mult / count),
|
|
||||||
math.floor(pools.level / count))
|
|
||||||
delay(1)
|
|
||||||
update_hand_text({sound = "button", volume = 0.7, pitch = 1.1, delay = 0},
|
|
||||||
{mult = 0, chips = 0, handname = "", level = ""})
|
|
||||||
end
|
|
||||||
|
|
||||||
local function hsv(h, s, v)
|
local function hsv(h, s, v)
|
||||||
if s <= 0 then return v, v, v end
|
if s <= 0 then
|
||||||
|
return v, v, v
|
||||||
|
end
|
||||||
|
|
||||||
h = h * 6
|
h = h * 6
|
||||||
local c = v * s
|
local c = v * s
|
||||||
|
|
@ -349,7 +278,6 @@ function Game:update(dt)
|
||||||
end
|
end
|
||||||
|
|
||||||
orig_update(self, dt)
|
orig_update(self, dt)
|
||||||
|
|
||||||
local ante = G.GAME.round_resets.ante
|
local ante = G.GAME.round_resets.ante
|
||||||
local blind = get_blind_amount((ante >= 1 and ante <= 8) and math.floor(ante) or ante)
|
local blind = get_blind_amount((ante >= 1 and ante <= 8) and math.floor(ante) or ante)
|
||||||
G.P_BLINDS["bl_jane_wee"].mult = 22 / blind
|
G.P_BLINDS["bl_jane_wee"].mult = 22 / blind
|
||||||
|
|
@ -357,8 +285,8 @@ function Game:update(dt)
|
||||||
Jane.update_honey()
|
Jane.update_honey()
|
||||||
|
|
||||||
if not Jane.bans_done then
|
if not Jane.bans_done then
|
||||||
delete_hardbans()
|
|
||||||
Jane.bans_done = true
|
Jane.bans_done = true
|
||||||
|
delete_hardbans()
|
||||||
end
|
end
|
||||||
|
|
||||||
if (G.GAME or {}).banned_keys then
|
if (G.GAME or {}).banned_keys then
|
||||||
|
|
@ -375,18 +303,6 @@ function Game:update(dt)
|
||||||
self.C.jane_RGB_HUE = (self.C.jane_RGB_HUE + 0.5) % 360
|
self.C.jane_RGB_HUE = (self.C.jane_RGB_HUE + 0.5) % 360
|
||||||
G.ARGS.LOC_COLOURS.jane_RGB = self.C.jane_RGB
|
G.ARGS.LOC_COLOURS.jane_RGB = self.C.jane_RGB
|
||||||
end
|
end
|
||||||
|
|
||||||
rebalance_orrery()
|
|
||||||
end
|
|
||||||
|
|
||||||
local orig_card = SMODS.find_card
|
|
||||||
|
|
||||||
---@param key string
|
|
||||||
---@param count_debuffed true?
|
|
||||||
---@return Card[]|table[]
|
|
||||||
--- Returns all cards matching provided `key`.
|
|
||||||
function SMODS.find_card(key, count_debuffed)
|
|
||||||
return orig_card(key == "j_jen_saint" and "j_jane_saint" or key, count_debuffed)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
SMODS.Atlas {
|
SMODS.Atlas {
|
||||||
|
|
|
||||||
123
src/slugcat.lua
123
src/slugcat.lua
|
|
@ -162,6 +162,7 @@ SMODS.Joker {
|
||||||
local function spawn_rot()
|
local function spawn_rot()
|
||||||
card:flip()
|
card:flip()
|
||||||
card:juice_up(2, 0.8)
|
card:juice_up(2, 0.8)
|
||||||
|
card.getting_sliced = true
|
||||||
Jane.card_status_text(card, "Dead!", nil, 0.05 * card.T.h, G.C.BLACK, 2, 0, 0, nil, "bm", "jane_gore6")
|
Jane.card_status_text(card, "Dead!", nil, 0.05 * card.T.h, G.C.BLACK, 2, 0, 0, nil, "bm", "jane_gore6")
|
||||||
|
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
|
|
@ -171,24 +172,19 @@ SMODS.Joker {
|
||||||
card:set_eternal(nil)
|
card:set_eternal(nil)
|
||||||
card2:set_eternal(true)
|
card2:set_eternal(true)
|
||||||
play_sound("jane_gore5")
|
play_sound("jane_gore5")
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
|
||||||
|
|
||||||
local function die()
|
|
||||||
spawn_rot()
|
|
||||||
|
|
||||||
Jane.q(function()
|
|
||||||
Jane.empowered()
|
|
||||||
return true
|
|
||||||
end, 0.1)
|
|
||||||
|
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
card:start_dissolve()
|
card:start_dissolve()
|
||||||
return true
|
|
||||||
end, 1)
|
end, 1)
|
||||||
|
end
|
||||||
|
|
||||||
return true
|
local function die()
|
||||||
|
Jane.q(function()
|
||||||
|
Jane.empowered()
|
||||||
|
end, 0.1)
|
||||||
|
|
||||||
|
spawn_rot()
|
||||||
end
|
end
|
||||||
|
|
||||||
if context.blueprint then
|
if context.blueprint then
|
||||||
|
|
@ -204,17 +200,13 @@ SMODS.Joker {
|
||||||
|
|
||||||
if not card.hunter_prep then
|
if not card.hunter_prep then
|
||||||
card.hunter_prep = true
|
card.hunter_prep = true
|
||||||
|
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
Jane.q(function()
|
card.hunter_prep = nil
|
||||||
card.hunter_prep = nil
|
|
||||||
if G.GAME.current_round.hands_left < G.GAME.round_resets.hands then
|
|
||||||
ease_hands_played(G.GAME.round_resets.hands - G.GAME.current_round.hands_left)
|
|
||||||
end
|
|
||||||
|
|
||||||
return true
|
if G.GAME.current_round.hands_left < G.GAME.round_resets.hands then
|
||||||
end)
|
ease_hands_played(G.GAME.round_resets.hands - G.GAME.current_round.hands_left)
|
||||||
|
end
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -259,7 +251,7 @@ SMODS.Joker {
|
||||||
else
|
else
|
||||||
card:juice_up(2, 0.8)
|
card:juice_up(2, 0.8)
|
||||||
Jane.play_sound("jane_warning_heartbeat")
|
Jane.play_sound("jane_warning_heartbeat")
|
||||||
G.E_MANAGER:add_event(Event({trigger = "after", func = die}))
|
Jane.q(die, 0)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
|
@ -380,17 +372,11 @@ function Card:open()
|
||||||
|
|
||||||
orig_open(self)
|
orig_open(self)
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
delay = 0.5,
|
if next(spearmasters) then
|
||||||
timer = "REAL",
|
G.GAME.pack_choices = math.floor(self.ability.extra)
|
||||||
func = function()
|
end
|
||||||
if next(spearmasters) then
|
end, 0.5, "REAL")
|
||||||
G.GAME.pack_choices = math.floor(self.ability.extra)
|
|
||||||
end
|
|
||||||
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
|
|
||||||
SMODS.Joker {
|
SMODS.Joker {
|
||||||
|
|
@ -441,7 +427,30 @@ function Card:draw(layer)
|
||||||
orig_draw(self, layer)
|
orig_draw(self, layer)
|
||||||
end
|
end
|
||||||
|
|
||||||
local attune = Cryptid and 1.001 or 1.2
|
local orig_debuff = Card.set_debuff
|
||||||
|
|
||||||
|
function Card:set_debuff(should_debuff)
|
||||||
|
if should_debuff and ((self.config or {}).center or {}).debuff_immune then
|
||||||
|
Jane.card_status_text(self, "Immune", nil, 0.05 * self.T.h, G.C.RED, nil, 0.6, nil, nil, "bm", "cancel", 1, 0.9)
|
||||||
|
return false
|
||||||
|
else
|
||||||
|
orig_debuff(self, should_debuff)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local orig_card = SMODS.find_card
|
||||||
|
|
||||||
|
---@param key string
|
||||||
|
---@param count_debuffed true?
|
||||||
|
---@return Card[]|table[]
|
||||||
|
--- Returns all cards matching provided `key`.
|
||||||
|
function SMODS.find_card(key, count_debuffed)
|
||||||
|
return orig_card(key == "j_jen_saint" and "j_jane_saint" or key, count_debuffed)
|
||||||
|
end
|
||||||
|
|
||||||
|
local function attunement()
|
||||||
|
return (G.GAME or {}).weeckweeck and 2 or (Cryptid and 1.001 or 1.2)
|
||||||
|
end
|
||||||
|
|
||||||
SMODS.Joker {
|
SMODS.Joker {
|
||||||
key = "saint",
|
key = "saint",
|
||||||
|
|
@ -477,7 +486,7 @@ SMODS.Joker {
|
||||||
attuned and " (Attuned)" or "",
|
attuned and " (Attuned)" or "",
|
||||||
attuned and "" or "Attune ",
|
attuned and "" or "Attune ",
|
||||||
attuned and "" or "after using ",
|
attuned and "" or "after using ",
|
||||||
attuned and "^^" .. attune or max_karma,
|
attuned and "^^" .. attunement() or max_karma,
|
||||||
attuned and "" or " Gateways",
|
attuned and "" or " Gateways",
|
||||||
attuned and " Chips " or "",
|
attuned and " Chips " or "",
|
||||||
attuned and "& " or "",
|
attuned and "& " or "",
|
||||||
|
|
@ -522,6 +531,8 @@ SMODS.Joker {
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local attune = attunement()
|
||||||
|
|
||||||
local trigger = ({
|
local trigger = ({
|
||||||
e_holo = {mult_mod = 50},
|
e_holo = {mult_mod = 50},
|
||||||
e_foil = {chip_mod = 250},
|
e_foil = {chip_mod = 250},
|
||||||
|
|
@ -601,25 +612,17 @@ SMODS.Joker {
|
||||||
"jane_enlightened"
|
"jane_enlightened"
|
||||||
)
|
)
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
delay = 0.1,
|
card:flip()
|
||||||
func = function()
|
play_sound("card1")
|
||||||
card:flip()
|
end, 0.1)
|
||||||
play_sound("card1")
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
delay = 1,
|
card:flip()
|
||||||
func = function()
|
card:juice_up(1, 1)
|
||||||
card:flip()
|
play_sound("card1")
|
||||||
card:juice_up(1, 1)
|
extra.is_attuned = true
|
||||||
play_sound("card1")
|
end, 1)
|
||||||
extra.is_attuned = true
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -657,31 +660,19 @@ SMODS.Joker {
|
||||||
return G.jokers.config.card_count < G.jokers.config.card_limit
|
return G.jokers.config.card_count < G.jokers.config.card_limit
|
||||||
end
|
end
|
||||||
|
|
||||||
local function is_end_of_ante()
|
|
||||||
return not context.individual and not
|
|
||||||
context.repetition and not
|
|
||||||
card.debuff and
|
|
||||||
context.end_of_round and not
|
|
||||||
context.blueprint and
|
|
||||||
G.GAME.blind.boss and not
|
|
||||||
(G.GAME.blind.config and G.GAME.blind.config.bonus)
|
|
||||||
end
|
|
||||||
|
|
||||||
local function spawn()
|
local function spawn()
|
||||||
local rot = copy_card(card)
|
local rot = copy_card(card)
|
||||||
rot.cloned = true
|
rot.cloned = true
|
||||||
rot:add_to_deck()
|
rot:add_to_deck()
|
||||||
G.jokers:emplace(rot)
|
G.jokers:emplace(rot)
|
||||||
Jane.card_status_text(rot, "...", nil, 0.05 * card.T.h, G.C.BLACK, 3, 0, 0, nil, "bm")
|
Jane.card_status_text(rot, "...", nil, 0.05 * card.T.h, G.C.BLACK, 3, 0, 0, nil, "bm")
|
||||||
return true
|
|
||||||
end
|
end
|
||||||
|
|
||||||
if has_room() and not card.cloned and is_end_of_ante() then
|
if has_room() and not card.cloned and Jane.is_end_of_ante(context, card) then
|
||||||
Jane.q(spawn, 0.5)
|
Jane.q(spawn, 0.5)
|
||||||
else
|
else
|
||||||
Jane.q(function()
|
Jane.q(function()
|
||||||
card.cloned = false
|
card.cloned = false
|
||||||
return true
|
|
||||||
end, 5)
|
end, 5)
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
|
|
||||||
177
src/spectral.lua
177
src/spectral.lua
|
|
@ -12,22 +12,17 @@ local function conjure(card, number)
|
||||||
math.ceil(card.ability.extra.spectrals) * number,
|
math.ceil(card.ability.extra.spectrals) * number,
|
||||||
G.consumeables.config.card_limit - #G.consumeables.cards
|
G.consumeables.config.card_limit - #G.consumeables.cards
|
||||||
) do
|
) do
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
trigger = "after",
|
if G.consumeables.config.card_limit <= #G.consumeables.cards then
|
||||||
delay = 0.4,
|
return
|
||||||
func = function()
|
end
|
||||||
if G.consumeables.config.card_limit <= #G.consumeables.cards then
|
|
||||||
return true
|
|
||||||
end
|
|
||||||
|
|
||||||
play_sound("jane_draw")
|
play_sound("jane_draw")
|
||||||
local spectral = create_card("Spectral", G.consumeables, nil, nil, nil, nil, nil, "pri")
|
local spectral = create_card("Spectral", G.consumeables, nil, nil, nil, nil, nil, "pri")
|
||||||
spectral:add_to_deck()
|
spectral:add_to_deck()
|
||||||
G.consumeables:emplace(spectral)
|
G.consumeables:emplace(spectral)
|
||||||
card:juice_up(0.3, 0.5)
|
card:juice_up(0.3, 0.5)
|
||||||
return true
|
end, 0.4)
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -35,38 +30,33 @@ local function create_full_deck(enhancement, edition, amount, emplacement)
|
||||||
local cards = {}
|
local cards = {}
|
||||||
|
|
||||||
for _, v in pairs(G.P_CARDS) do
|
for _, v in pairs(G.P_CARDS) do
|
||||||
for i = 1, (amount or 1) do
|
for i = 1, amount or 1 do
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
delay = 0.1,
|
cards[i] = true
|
||||||
func = function()
|
G.playing_card = (G.playing_card and G.playing_card + 1) or 1
|
||||||
cards[i] = true
|
|
||||||
G.playing_card = (G.playing_card and G.playing_card + 1) or 1
|
|
||||||
|
|
||||||
local card = Card(
|
local card = Card(
|
||||||
G.play.T.x + G.play.T.w / 2,
|
G.play.T.x + G.play.T.w / 2,
|
||||||
G.play.T.y, G.CARD_W, G.CARD_H,
|
G.play.T.y, G.CARD_W, G.CARD_H,
|
||||||
v,
|
v,
|
||||||
enhancement or G.P_CENTERS.c_base,
|
enhancement or G.P_CENTERS.c_base,
|
||||||
{playing_card = G.playing_card}
|
{playing_card = G.playing_card}
|
||||||
)
|
)
|
||||||
|
|
||||||
if edition then
|
if edition then
|
||||||
card:set_edition(type(edition) == "table" and edition or {[edition] = true}, true, true)
|
card:set_edition(type(edition) == "table" and edition or {[edition] = true}, true, true)
|
||||||
end
|
end
|
||||||
|
|
||||||
play_sound("card1")
|
play_sound("card1")
|
||||||
table.insert(G.playing_cards, card)
|
table.insert(G.playing_cards, card)
|
||||||
card:add_to_deck()
|
card:add_to_deck()
|
||||||
|
|
||||||
if emplacement then
|
if emplacement then
|
||||||
emplacement:emplace(card)
|
emplacement:emplace(card)
|
||||||
else
|
else
|
||||||
G.deck:emplace(card)
|
G.deck:emplace(card)
|
||||||
end
|
end
|
||||||
|
end, 0.1)
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -74,13 +64,6 @@ local function create_full_deck(enhancement, edition, amount, emplacement)
|
||||||
if next(cards) then
|
if next(cards) then
|
||||||
playing_card_joker_effects(cards)
|
playing_card_joker_effects(cards)
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end)
|
|
||||||
|
|
||||||
Jane.q(function()
|
|
||||||
cards = nil
|
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -125,16 +108,11 @@ local function randomize(targets, noanim)
|
||||||
for i = 1, #targets do
|
for i = 1, #targets do
|
||||||
local percent = 1.15 - (i - 0.999) / (#G.hand.cards - 0.998) * 0.3
|
local percent = 1.15 - (i - 0.999) / (#G.hand.cards - 0.998) * 0.3
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
trigger = "after",
|
targets[i]:flip()
|
||||||
delay = 0.15,
|
play_sound("card1", percent)
|
||||||
func = function()
|
targets[i]:juice_up(0.3, 0.3)
|
||||||
targets[i]:flip()
|
end, 0.15)
|
||||||
play_sound("card1", percent)
|
|
||||||
targets[i]:juice_up(0.3, 0.3)
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
end
|
end
|
||||||
|
|
||||||
delay(0.2)
|
delay(0.2)
|
||||||
|
|
@ -142,39 +120,34 @@ local function randomize(targets, noanim)
|
||||||
for i = 1, #targets do
|
for i = 1, #targets do
|
||||||
local percent = 0.85 + (i - 0.999) / (#G.hand.cards - 0.998) * 0.3
|
local percent = 0.85 + (i - 0.999) / (#G.hand.cards - 0.998) * 0.3
|
||||||
|
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
trigger = "after",
|
local card = targets[i]
|
||||||
delay = 0.1,
|
card:set_base(pseudorandom_element(G.P_CARDS))
|
||||||
func = function()
|
card:set_ability(pseudorandom_element(G.P_CENTER_POOLS["Enhanced"]))
|
||||||
local card = targets[i]
|
|
||||||
card:set_base(pseudorandom_element(G.P_CARDS))
|
|
||||||
card:set_ability(pseudorandom_element(G.P_CENTER_POOLS["Enhanced"]))
|
|
||||||
|
|
||||||
local edition_rate = 2
|
local edition_rate = 2
|
||||||
card:set_edition(poll_edition("standard_edition" .. G.GAME.round_resets.ante, edition_rate, true))
|
card:set_edition(poll_edition("standard_edition" .. G.GAME.round_resets.ante, edition_rate, true))
|
||||||
local seal_rate = 10
|
local seal_rate = 10
|
||||||
local seal_poll = pseudorandom(pseudoseed("stdseal" .. G.GAME.round_resets.ante))
|
local seal_poll = pseudorandom(pseudoseed("stdseal" .. G.GAME.round_resets.ante))
|
||||||
|
|
||||||
if seal_poll > 1 - 0.02 * seal_rate then
|
if seal_poll > 1 - 0.02 * seal_rate then
|
||||||
local seal_type = pseudorandom(pseudoseed("stdsealtype" .. G.GAME.round_resets.ante))
|
local seal_type = pseudorandom(pseudoseed("stdsealtype" .. G.GAME.round_resets.ante))
|
||||||
local seal_list = {}
|
local seal_list = {}
|
||||||
|
|
||||||
for k, _ in pairs(G.P_SEALS) do
|
for k, _ in pairs(G.P_SEALS) do
|
||||||
table.insert(seal_list, k)
|
table.insert(seal_list, k)
|
||||||
end
|
|
||||||
|
|
||||||
seal_type = math.floor(seal_type * #seal_list)
|
|
||||||
card:set_seal(seal_list[seal_type])
|
|
||||||
else
|
|
||||||
card:set_seal()
|
|
||||||
end
|
end
|
||||||
|
|
||||||
card:flip()
|
seal_type = math.floor(seal_type * #seal_list)
|
||||||
play_sound("card3", percent, 0.6)
|
card:set_seal(seal_list[seal_type])
|
||||||
card:juice_up(0.3, 0.3)
|
else
|
||||||
return true
|
card:set_seal()
|
||||||
end,
|
end
|
||||||
}))
|
|
||||||
|
card:flip()
|
||||||
|
play_sound("card3", percent, 0.6)
|
||||||
|
card:juice_up(0.3, 0.3)
|
||||||
|
end, 0.1)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
@ -197,15 +170,10 @@ SMODS.Consumable {
|
||||||
return Jane.can_use() and #((G.hand or {}).cards or {}) > 0
|
return Jane.can_use() and #((G.hand or {}).cards or {}) > 0
|
||||||
end,
|
end,
|
||||||
use = function(_, card, _, _)
|
use = function(_, card, _, _)
|
||||||
G.E_MANAGER:add_event(Event({
|
Jane.q(function()
|
||||||
trigger = "after",
|
play_sound("tarot1")
|
||||||
delay = 0.4,
|
card:juice_up(0.3, 0.5)
|
||||||
func = function()
|
end, 0.4)
|
||||||
play_sound("tarot1")
|
|
||||||
card:juice_up(0.3, 0.5)
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}))
|
|
||||||
|
|
||||||
randomize(G.hand.cards)
|
randomize(G.hand.cards)
|
||||||
delay(0.5)
|
delay(0.5)
|
||||||
|
|
@ -331,22 +299,9 @@ SMODS.Consumable {
|
||||||
for _, v in pairs(G.playing_cards) do
|
for _, v in pairs(G.playing_cards) do
|
||||||
v:start_dissolve()
|
v:start_dissolve()
|
||||||
end
|
end
|
||||||
|
|
||||||
return true
|
|
||||||
end)
|
end)
|
||||||
|
|
||||||
local function realdelay(time, queue)
|
delay(2)
|
||||||
G.E_MANAGER:add_event(Event({
|
|
||||||
trigger = "after",
|
|
||||||
timer = "REAL",
|
|
||||||
delay = time or 1,
|
|
||||||
func = function()
|
|
||||||
return true
|
|
||||||
end,
|
|
||||||
}), queue)
|
|
||||||
end
|
|
||||||
|
|
||||||
realdelay(1)
|
|
||||||
create_full_deck()
|
create_full_deck()
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue