mirror of
https://github.com/ershisan99/Fantoms-Preview.git
synced 2025-12-16 20:49:23 +00:00
fixed smods issue and implemented multi jokers
This commit is contained in:
@@ -1,13 +0,0 @@
|
|||||||
--
|
|
||||||
-- SMODS compatibility:
|
|
||||||
--
|
|
||||||
|
|
||||||
local orig_get_X_same = get_X_same
|
|
||||||
function get_X_same(num, hand)
|
|
||||||
return orig_get_X_same(num, clean_hand(hand))
|
|
||||||
end
|
|
||||||
|
|
||||||
local orig_get_highest = get_highest
|
|
||||||
function get_highest(hand)
|
|
||||||
return orig_get_highest(clean_hand(hand))
|
|
||||||
end
|
|
||||||
@@ -4,29 +4,25 @@
|
|||||||
-- ie. whenever the player modifies card selection or card order.
|
-- ie. whenever the player modifies card selection or card order.
|
||||||
|
|
||||||
function DV.PRE.simulate()
|
function DV.PRE.simulate()
|
||||||
-- Guard against simulating in redundant places:
|
-- Guard against simulating in redundant places:
|
||||||
if
|
if not (G.STATE == G.STATES.SELECTING_HAND or
|
||||||
not (G.STATE == G.STATES.SELECTING_HAND or G.STATE == G.STATES.DRAW_TO_HAND or G.STATE == G.STATES.PLAY_TAROT)
|
G.STATE == G.STATES.DRAW_TO_HAND or
|
||||||
then
|
G.STATE == G.STATES.PLAY_TAROT)
|
||||||
return { score = { min = 0, exact = 0, max = 0 }, dollars = { min = 0, exact = 0, max = 0 } }
|
then return {score = {min = 0, exact = 0, max = 0}, dollars = {min = 0, exact = 0, max = 0}}
|
||||||
end
|
end
|
||||||
|
|
||||||
if G.SETTINGS.DV.hide_face_down then
|
if G.SETTINGS.DV.hide_face_down then
|
||||||
for _, card in ipairs(G.hand.highlighted) do
|
for _, card in ipairs(G.hand.highlighted) do
|
||||||
if card.facing == "back" then
|
if card.facing == "back" then return nil end
|
||||||
return nil
|
end
|
||||||
end
|
if #(G.hand.highlighted) ~= 0 then
|
||||||
end
|
for _, joker in ipairs(G.jokers.cards) do
|
||||||
if #G.hand.highlighted ~= 0 then
|
if joker.facing == "back" then return nil end
|
||||||
for _, joker in ipairs(G.jokers.cards) do
|
end
|
||||||
if joker.facing == "back" then
|
end
|
||||||
return nil
|
end
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
return DV.SIM.run()
|
return DV.SIM.run()
|
||||||
end
|
end
|
||||||
|
|
||||||
--
|
--
|
||||||
@@ -34,90 +30,85 @@ end
|
|||||||
--
|
--
|
||||||
|
|
||||||
function DV.PRE.add_update_event(trigger)
|
function DV.PRE.add_update_event(trigger)
|
||||||
function sim_func()
|
function sim_func()
|
||||||
DV.PRE.data = DV.PRE.simulate()
|
DV.PRE.data = DV.PRE.simulate()
|
||||||
return true
|
return true
|
||||||
end
|
end
|
||||||
if DV.PRE.enabled() then
|
if DV.PRE.enabled() then
|
||||||
G.E_MANAGER:add_event(Event({ trigger = trigger, func = sim_func }))
|
G.E_MANAGER:add_event(Event({trigger = trigger, func = sim_func}))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Update simulation after a consumable (eg. Tarot, Planet) is used:
|
-- Update simulation after a consumable (eg. Tarot, Planet) is used:
|
||||||
local orig_use = Card.use_consumeable
|
local orig_use = Card.use_consumeable
|
||||||
function Card:use_consumeable(area, copier)
|
function Card:use_consumeable(area, copier)
|
||||||
orig_use(self, area, copier)
|
orig_use(self, area, copier)
|
||||||
DV.PRE.add_update_event("immediate")
|
DV.PRE.add_update_event("immediate")
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Update simulation after card selection changed:
|
-- Update simulation after card selection changed:
|
||||||
local orig_hl = CardArea.parse_highlighted
|
local orig_hl = CardArea.parse_highlighted
|
||||||
function CardArea:parse_highlighted()
|
function CardArea:parse_highlighted()
|
||||||
orig_hl(self)
|
orig_hl(self)
|
||||||
DV.PRE.add_update_event("immediate")
|
DV.PRE.add_update_event("immediate")
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Update simulation after joker sold:
|
-- Update simulation after joker sold:
|
||||||
local orig_card_remove = Card.remove_from_area
|
local orig_card_remove = Card.remove_from_area
|
||||||
function Card:remove_from_area()
|
function Card:remove_from_area()
|
||||||
orig_card_remove(self)
|
orig_card_remove(self)
|
||||||
if self.config.type == "joker" then
|
if self.config.type == 'joker' then
|
||||||
DV.PRE.add_update_event("immediate")
|
DV.PRE.add_update_event("immediate")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Update simulation after joker reordering:
|
-- Update simulation after joker reordering:
|
||||||
local orig_update = CardArea.update
|
local orig_update = CardArea.update
|
||||||
function CardArea:update(dt)
|
function CardArea:update(dt)
|
||||||
orig_update(self, dt)
|
orig_update(self, dt)
|
||||||
DV.PRE.update_on_card_order_change(self)
|
DV.PRE.update_on_card_order_change(self)
|
||||||
end
|
end
|
||||||
|
|
||||||
function DV.PRE.update_on_card_order_change(cardarea)
|
function DV.PRE.update_on_card_order_change(cardarea)
|
||||||
if
|
if #cardarea.cards == 0 or
|
||||||
#cardarea.cards == 0
|
not (G.STATE == G.STATES.SELECTING_HAND or
|
||||||
or not (
|
G.STATE == G.STATES.DRAW_TO_HAND or
|
||||||
G.STATE == G.STATES.SELECTING_HAND
|
G.STATE == G.STATES.PLAY_TAROT)
|
||||||
or G.STATE == G.STATES.DRAW_TO_HAND
|
then return end
|
||||||
or G.STATE == G.STATES.PLAY_TAROT
|
-- Important not to update on G.STATES.HAND_PLAYED, because it would reset the preview text!
|
||||||
)
|
|
||||||
then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
-- Important not to update on G.STATES.HAND_PLAYED, because it would reset the preview text!
|
|
||||||
|
|
||||||
local prev_order = nil
|
local prev_order = nil
|
||||||
if cardarea.config.type == "joker" and cardarea.cards[1].ability.set == "Joker" then
|
if cardarea.config.type == 'joker' and cardarea.cards[1].ability.set == 'Joker' then
|
||||||
-- Note that the consumables cardarea also has type 'joker' so must verify by checking first card.
|
-- Note that the consumables cardarea also has type 'joker' so must verify by checking first card.
|
||||||
prev_order = DV.PRE.joker_order
|
prev_order = DV.PRE.joker_order
|
||||||
elseif cardarea.config.type == "hand" then
|
elseif cardarea.config.type == 'hand' then
|
||||||
prev_order = DV.PRE.hand_order
|
prev_order = DV.PRE.hand_order
|
||||||
else
|
else
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Go through stored card IDs and check against current card IDs, in-order.
|
-- Go through stored card IDs and check against current card IDs, in-order.
|
||||||
-- If any mismatch occurs, toggle flag and update name for next time.
|
-- If any mismatch occurs, toggle flag and update name for next time.
|
||||||
local should_update = false
|
local should_update = false
|
||||||
if #cardarea.cards ~= #prev_order then
|
if #cardarea.cards ~= #prev_order then
|
||||||
prev_order = {}
|
prev_order = {}
|
||||||
end
|
end
|
||||||
for i, c in ipairs(cardarea.cards) do
|
for i, c in ipairs(cardarea.cards) do
|
||||||
if c.sort_id ~= prev_order[i] then
|
if c.sort_id ~= prev_order[i] then
|
||||||
prev_order[i] = c.sort_id
|
prev_order[i] = c.sort_id
|
||||||
should_update = true
|
should_update = true
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
if should_update then
|
if should_update then
|
||||||
if cardarea.config.type == "joker" or cardarea.cards[1].ability.set == "Joker" then
|
if cardarea.config.type == 'joker' or cardarea.cards[1].ability.set == 'Joker' then
|
||||||
DV.PRE.joker_order = prev_order
|
DV.PRE.joker_order = prev_order
|
||||||
elseif cardarea.config.type == "hand" then
|
elseif cardarea.config.type == 'hand' then
|
||||||
DV.PRE.hand_order = prev_order
|
DV.PRE.hand_order = prev_order
|
||||||
end
|
end
|
||||||
|
|
||||||
DV.PRE.add_update_event("immediate")
|
DV.PRE.add_update_event("immediate")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
--
|
--
|
||||||
@@ -125,27 +116,27 @@ end
|
|||||||
--
|
--
|
||||||
|
|
||||||
function DV.PRE.add_reset_event(trigger)
|
function DV.PRE.add_reset_event(trigger)
|
||||||
function reset_func()
|
function reset_func()
|
||||||
DV.PRE.data = { score = { min = 0, exact = 0, max = 0 }, dollars = { min = 0, exact = 0, max = 0 } }
|
DV.PRE.data = {score = {min = 0, exact = 0, max = 0}, dollars = {min = 0, exact = 0, max = 0}}
|
||||||
return true
|
return true
|
||||||
end
|
end
|
||||||
if DV.PRE.enabled() then
|
if DV.PRE.enabled() then
|
||||||
G.E_MANAGER:add_event(Event({ trigger = trigger, func = reset_func }))
|
G.E_MANAGER:add_event(Event({trigger = trigger, func = reset_func}))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
local orig_eval = G.FUNCS.evaluate_play
|
local orig_eval = G.FUNCS.evaluate_play
|
||||||
function G.FUNCS.evaluate_play(e)
|
function G.FUNCS.evaluate_play(e)
|
||||||
orig_eval(e)
|
orig_eval(e)
|
||||||
DV.PRE.add_reset_event("after")
|
DV.PRE.add_reset_event("after")
|
||||||
end
|
end
|
||||||
|
|
||||||
local orig_discard = G.FUNCS.discard_cards_from_highlighted
|
local orig_discard = G.FUNCS.discard_cards_from_highlighted
|
||||||
function G.FUNCS.discard_cards_from_highlighted(e, is_hook_blind)
|
function G.FUNCS.discard_cards_from_highlighted(e, is_hook_blind)
|
||||||
orig_discard(e, is_hook_blind)
|
orig_discard(e, is_hook_blind)
|
||||||
if not is_hook_blind then
|
if not is_hook_blind then
|
||||||
DV.PRE.add_reset_event("immediate")
|
DV.PRE.add_reset_event("immediate")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
--
|
--
|
||||||
@@ -154,105 +145,94 @@ end
|
|||||||
|
|
||||||
-- Add animation to preview text:
|
-- Add animation to preview text:
|
||||||
function G.FUNCS.dv_pre_score_UI_set(e)
|
function G.FUNCS.dv_pre_score_UI_set(e)
|
||||||
local new_preview_text = ""
|
local new_preview_text = ""
|
||||||
local should_juice = false
|
local should_juice = false
|
||||||
if DV.PRE.data then
|
if DV.PRE.data then
|
||||||
if G.SETTINGS.DV.show_min_max and (DV.PRE.data.score.min ~= DV.PRE.data.score.max) then
|
if G.SETTINGS.DV.show_min_max and (DV.PRE.data.score.min ~= DV.PRE.data.score.max) then
|
||||||
-- Format as 'X - Y' :
|
-- Format as 'X - Y' :
|
||||||
if e.config.id == "dv_pre_l" then
|
if e.config.id == "dv_pre_l" then
|
||||||
new_preview_text = DV.PRE.format_number(DV.PRE.data.score.min) .. " - "
|
new_preview_text = DV.PRE.format_number(DV.PRE.data.score.min) .. " - "
|
||||||
if DV.PRE.is_enough_to_win(DV.PRE.data.score.min) then
|
if DV.PRE.is_enough_to_win(DV.PRE.data.score.min) then should_juice = true end
|
||||||
should_juice = true
|
elseif e.config.id == "dv_pre_r" then
|
||||||
end
|
new_preview_text = DV.PRE.format_number(DV.PRE.data.score.max)
|
||||||
elseif e.config.id == "dv_pre_r" then
|
if DV.PRE.is_enough_to_win(DV.PRE.data.score.max) then should_juice = true end
|
||||||
new_preview_text = DV.PRE.format_number(DV.PRE.data.score.max)
|
end
|
||||||
if DV.PRE.is_enough_to_win(DV.PRE.data.score.max) then
|
else
|
||||||
should_juice = true
|
-- Format as single number:
|
||||||
end
|
if e.config.id == "dv_pre_l" then
|
||||||
end
|
if G.SETTINGS.DV.show_min_max then
|
||||||
else
|
-- Spaces around number necessary to distinguish Min/Max text from Exact text,
|
||||||
-- Format as single number:
|
-- which is itself necessary to force a HUD update when switching between Min/Max and Exact.
|
||||||
if e.config.id == "dv_pre_l" then
|
new_preview_text = " " .. DV.PRE.format_number(DV.PRE.data.score.min) .. " "
|
||||||
if G.SETTINGS.DV.show_min_max then
|
if DV.PRE.is_enough_to_win(DV.PRE.data.score.min) then should_juice = true end
|
||||||
-- Spaces around number necessary to distinguish Min/Max text from Exact text,
|
else
|
||||||
-- which is itself necessary to force a HUD update when switching between Min/Max and Exact.
|
new_preview_text = number_format(DV.PRE.data.score.exact)
|
||||||
new_preview_text = " " .. DV.PRE.format_number(DV.PRE.data.score.min) .. " "
|
if DV.PRE.is_enough_to_win(DV.PRE.data.score.exact) then should_juice = true end
|
||||||
if DV.PRE.is_enough_to_win(DV.PRE.data.score.min) then
|
end
|
||||||
should_juice = true
|
else
|
||||||
end
|
new_preview_text = ""
|
||||||
else
|
end
|
||||||
new_preview_text = number_format(DV.PRE.data.score.exact)
|
end
|
||||||
if DV.PRE.is_enough_to_win(DV.PRE.data.score.exact) then
|
else
|
||||||
should_juice = true
|
-- Spaces around number necessary to distinguish Min/Max text from Exact text, same as above ^
|
||||||
end
|
if e.config.id == "dv_pre_l" then
|
||||||
end
|
if G.SETTINGS.DV.show_min_max then new_preview_text = " ?????? "
|
||||||
else
|
else new_preview_text = "??????"
|
||||||
new_preview_text = ""
|
end
|
||||||
end
|
else
|
||||||
end
|
new_preview_text = ""
|
||||||
else
|
end
|
||||||
-- Spaces around number necessary to distinguish Min/Max text from Exact text, same as above ^
|
end
|
||||||
if e.config.id == "dv_pre_l" then
|
|
||||||
if G.SETTINGS.DV.show_min_max then
|
|
||||||
new_preview_text = " ?????? "
|
|
||||||
else
|
|
||||||
new_preview_text = "??????"
|
|
||||||
end
|
|
||||||
else
|
|
||||||
new_preview_text = ""
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
if (not DV.PRE.text.score[e.config.id:sub(-1)]) or new_preview_text ~= DV.PRE.text.score[e.config.id:sub(-1)] then
|
if (not DV.PRE.text.score[e.config.id:sub(-1)]) or new_preview_text ~= DV.PRE.text.score[e.config.id:sub(-1)] then
|
||||||
DV.PRE.text.score[e.config.id:sub(-1)] = new_preview_text
|
DV.PRE.text.score[e.config.id:sub(-1)] = new_preview_text
|
||||||
e.config.object:update_text()
|
e.config.object:update_text()
|
||||||
-- Wobble:
|
-- Wobble:
|
||||||
if not G.TAROT_INTERRUPT_PULSE then
|
if not G.TAROT_INTERRUPT_PULSE then
|
||||||
if should_juice then
|
if should_juice
|
||||||
G.FUNCS.text_super_juice(e, 5)
|
then
|
||||||
e.config.object.colours = { G.C.MONEY }
|
G.FUNCS.text_super_juice(e, 5)
|
||||||
else
|
e.config.object.colours = {G.C.MONEY}
|
||||||
G.FUNCS.text_super_juice(e, 0)
|
else
|
||||||
e.config.object.colours = { G.C.UI.TEXT_LIGHT }
|
G.FUNCS.text_super_juice(e, 0)
|
||||||
end
|
e.config.object.colours = {G.C.UI.TEXT_LIGHT}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function G.FUNCS.dv_pre_dollars_UI_set(e)
|
function G.FUNCS.dv_pre_dollars_UI_set(e)
|
||||||
local new_preview_text = ""
|
local new_preview_text = ""
|
||||||
local new_colour = nil
|
local new_colour = nil
|
||||||
if DV.PRE.data then
|
if DV.PRE.data then
|
||||||
if G.SETTINGS.DV.show_min_max and (DV.PRE.data.dollars.min ~= DV.PRE.data.dollars.max) then
|
if G.SETTINGS.DV.show_min_max and (DV.PRE.data.dollars.min ~= DV.PRE.data.dollars.max) then
|
||||||
if e.config.id == "dv_pre_dollars_top" then
|
if e.config.id == "dv_pre_dollars_top" then
|
||||||
new_preview_text = " " .. DV.PRE.get_sign_str(DV.PRE.data.dollars.max) .. DV.PRE.data.dollars.max
|
new_preview_text = " " .. DV.PRE.get_sign_str(DV.PRE.data.dollars.max) .. DV.PRE.data.dollars.max
|
||||||
new_colour = DV.PRE.get_dollar_colour(DV.PRE.data.dollars.max)
|
new_colour = DV.PRE.get_dollar_colour(DV.PRE.data.dollars.max)
|
||||||
elseif e.config.id == "dv_pre_dollars_bot" then
|
elseif e.config.id == "dv_pre_dollars_bot" then
|
||||||
new_preview_text = " " .. DV.PRE.get_sign_str(DV.PRE.data.dollars.min) .. DV.PRE.data.dollars.min
|
new_preview_text = " " .. DV.PRE.get_sign_str(DV.PRE.data.dollars.min) .. DV.PRE.data.dollars.min
|
||||||
new_colour = DV.PRE.get_dollar_colour(DV.PRE.data.dollars.min)
|
new_colour = DV.PRE.get_dollar_colour(DV.PRE.data.dollars.min)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
if e.config.id == "dv_pre_dollars_top" then
|
if e.config.id == "dv_pre_dollars_top" then
|
||||||
local _data = G.SETTINGS.DV.show_min_max and DV.PRE.data.dollars.min or DV.PRE.data.dollars.exact
|
local _data = (G.SETTINGS.DV.show_min_max) and DV.PRE.data.dollars.min or DV.PRE.data.dollars.exact
|
||||||
|
|
||||||
new_preview_text = " " .. DV.PRE.get_sign_str(_data) .. _data
|
new_preview_text = " " .. DV.PRE.get_sign_str(_data) .. _data
|
||||||
new_colour = DV.PRE.get_dollar_colour(_data)
|
new_colour = DV.PRE.get_dollar_colour(_data)
|
||||||
else
|
else
|
||||||
new_preview_text = ""
|
new_preview_text = ""
|
||||||
new_colour = DV.PRE.get_dollar_colour(0)
|
new_colour = DV.PRE.get_dollar_colour(0)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
new_preview_text = " +??"
|
new_preview_text = " +??"
|
||||||
new_colour = DV.PRE.get_dollar_colour(0)
|
new_colour = DV.PRE.get_dollar_colour(0)
|
||||||
end
|
end
|
||||||
|
|
||||||
if not DV.PRE.text.dollars[e.config.id:sub(-3)] or new_preview_text ~= DV.PRE.text.dollars[e.config.id:sub(-3)] then
|
if (not DV.PRE.text.dollars[e.config.id:sub(-3)]) or new_preview_text ~= DV.PRE.text.dollars[e.config.id:sub(-3)] then
|
||||||
DV.PRE.text.dollars[e.config.id:sub(-3)] = new_preview_text
|
DV.PRE.text.dollars[e.config.id:sub(-3)] = new_preview_text
|
||||||
e.config.object.colours = { new_colour }
|
e.config.object.colours = {new_colour}
|
||||||
e.config.object:update_text()
|
e.config.object:update_text()
|
||||||
if not G.TAROT_INTERRUPT_PULSE then
|
if not G.TAROT_INTERRUPT_PULSE then e.config.object:pulse(0.25) end
|
||||||
e.config.object:pulse(0.25)
|
end
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -2,36 +2,33 @@
|
|||||||
--
|
--
|
||||||
-- Global values that must be present for the rest of this mod to work.
|
-- Global values that must be present for the rest of this mod to work.
|
||||||
|
|
||||||
if not DV then
|
if not DV then DV = {} end
|
||||||
DV = {}
|
|
||||||
end
|
|
||||||
|
|
||||||
DV.PRE = {
|
DV.PRE = {
|
||||||
data = {
|
data = {
|
||||||
score = { min = 0, exact = 0, max = 0 },
|
score = {min = 0, exact = 0, max = 0},
|
||||||
dollars = { min = 0, exact = 0, max = 0 },
|
dollars = {min = 0, exact = 0, max = 0}
|
||||||
},
|
},
|
||||||
text = {
|
text = {
|
||||||
score = { l = "", r = "" },
|
score = {l = "", r = ""},
|
||||||
dollars = { top = "", bot = "" },
|
dollars = {top = "", bot = ""}
|
||||||
},
|
},
|
||||||
joker_order = {},
|
joker_order = {},
|
||||||
hand_order = {},
|
hand_order = {}
|
||||||
}
|
}
|
||||||
|
|
||||||
DV.PRE._start_up = Game.start_up
|
DV.PRE._start_up = Game.start_up
|
||||||
function Game:start_up()
|
function Game:start_up()
|
||||||
DV.PRE._start_up(self)
|
DV.PRE._start_up(self)
|
||||||
|
|
||||||
if not G.SETTINGS.DV then
|
if not G.SETTINGS.DV then G.SETTINGS.DV = {} end
|
||||||
G.SETTINGS.DV = {}
|
if not G.SETTINGS.DV.PRE then
|
||||||
end
|
G.SETTINGS.DV.PRE = true
|
||||||
if not G.SETTINGS.DV.PRE then
|
|
||||||
G.SETTINGS.DV.PRE = true
|
G.SETTINGS.DV.preview_score = true
|
||||||
|
G.SETTINGS.DV.preview_dollars = true
|
||||||
|
G.SETTINGS.DV.hide_face_down = true
|
||||||
|
G.SETTINGS.DV.show_min_max = true
|
||||||
|
end
|
||||||
|
|
||||||
G.SETTINGS.DV.preview_score = true
|
|
||||||
G.SETTINGS.DV.preview_dollars = true
|
|
||||||
G.SETTINGS.DV.hide_face_down = true
|
|
||||||
G.SETTINGS.DV.show_min_max = true
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -39,13 +39,3 @@ end
|
|||||||
function DV.PRE.enabled()
|
function DV.PRE.enabled()
|
||||||
return G.SETTINGS.DV.preview_score or G.SETTINGS.DV.preview_dollars
|
return G.SETTINGS.DV.preview_score or G.SETTINGS.DV.preview_dollars
|
||||||
end
|
end
|
||||||
|
|
||||||
function clean_hand(hand)
|
|
||||||
local clean_hand = {}
|
|
||||||
for _, v in pairs(hand) do
|
|
||||||
if v.get_id then -- Should work for all functions even if they don't use get_id because get_id is a meta function and the broken cards don't have meta values
|
|
||||||
table.insert(clean_hand, v)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
return clean_hand
|
|
||||||
end
|
|
||||||
|
|||||||
48
FNSimulate/Jokers/ExtraCredit.lua
Normal file
48
FNSimulate/Jokers/ExtraCredit.lua
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
local DVSJ = DV.SIM.JOKERS
|
||||||
|
|
||||||
|
DVSJ.simulate_doublerainbow = function(j, context)
|
||||||
|
if context.cardarea == G.play and context.repetition then
|
||||||
|
if context.other_card.ability.name == "Lucky Card" then
|
||||||
|
DV.SIM.add_reps(1)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
-- TODO: The source also has G.hand cardarea predicated on context.card_effects.
|
||||||
|
-- I'm unsure of what it does, and currently not mirroring here.
|
||||||
|
end
|
||||||
|
DVSJ.simulate_starfruit = function(j, context)
|
||||||
|
-- TODO: Verify
|
||||||
|
if context.cardarea == G.jokers and context.before then
|
||||||
|
if G.GAME.current_round.hands_played == 0 then
|
||||||
|
local hand_data = G.GAME.hands[DV.SIM.env.scoring_name]
|
||||||
|
|
||||||
|
local rand = pseudorandom("star") -- Must reuse same pseudorandom value:
|
||||||
|
local exact_chips, min_chips, max_chips = DV.SIM.get_probabilistic_extremes(rand, j.ability.extra, hand_data.l_chips, 0)
|
||||||
|
local exact_mult, min_mult, max_mult = DV.SIM.get_probabilistic_extremes(rand, j.ability.extra, hand_data.l_mult, 0)
|
||||||
|
|
||||||
|
DV.SIM.add_chips(exact_chips, min_chips, max_chips)
|
||||||
|
DV.SIM.add_mult(exact_mult, min_mult, max_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local function level_diff()
|
||||||
|
local num_hands = 0
|
||||||
|
local num_levels = 0
|
||||||
|
for _, hand in ipairs(G.GAME.hands) do
|
||||||
|
num_hands = num_hands + 1
|
||||||
|
num_levels = num_levels + hand.level
|
||||||
|
end
|
||||||
|
return (num_levels - num_hands)
|
||||||
|
end
|
||||||
|
DVSJ.simulate_eclipse = function(j, context)
|
||||||
|
-- TODO: Verify
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
local lvl_diff = level_diff()
|
||||||
|
if lvl_diff > 0 then
|
||||||
|
DV.SIM.add_chips(lvl_diff)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
DVSJ.simulate_rubberducky = function(j, context)
|
||||||
|
end
|
||||||
261
FNSimulate/Jokers/MoreFluff.lua
Normal file
261
FNSimulate/Jokers/MoreFluff.lua
Normal file
@@ -0,0 +1,261 @@
|
|||||||
|
local DVSJ = DV.SIM.JOKERS
|
||||||
|
|
||||||
|
DVSJ.simulate_badlegaldefence = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_basepaul_card = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.gloabl then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
if string.find(string.lower(G.PROFILES[G.SETTINGS.profile].name), "paul") then
|
||||||
|
DV.SIM.x_mult(10)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_bladedance = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_blasphemy = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.xmult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_bloodpact = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
local any_heart = false
|
||||||
|
for _, card in ipairs(context.full_hand) do
|
||||||
|
if DV.SIM.is_suit(card, "Hearts") then
|
||||||
|
any_heart = true
|
||||||
|
break
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if not any_heart then
|
||||||
|
DV.SIM.x_mult(j.ability.extra)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_bowlingball = function(j, context)
|
||||||
|
if context.cardarea == G.play and context.individual then
|
||||||
|
if DV.SIM.is_rank(context.other_card, 3) then
|
||||||
|
DV.SIM.add_chips(j.ability.extra.chips)
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_cba = function(j, context)
|
||||||
|
-- TODO: Unsure how the mod's implementation works?
|
||||||
|
end
|
||||||
|
DVSJ.simulate_clipart = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_clownfish = function(j, context)
|
||||||
|
if context.cardarea == G.play and context.individual then
|
||||||
|
if context.other_card.ability.name ~= "Default Base" then
|
||||||
|
DV.SIM.add_chips(j.ability.extra.chips)
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_colorem = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_coupon_catalogue = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
local redeemed = 0
|
||||||
|
for _, v in pairs(G.GAME.used_vouchers) do
|
||||||
|
if v then redeemed = redeemed + 1 end
|
||||||
|
end
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult * redeemed)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_css = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_dramaticentrance = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
if G.GAME.current_round.hands_played == 0 then
|
||||||
|
DV.SIM.add_chips(j.ability.extra.chips)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_dropkick = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_expansion_pack = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_fleshpanopticon = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_fleshprison = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_globe = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_goldencarrot = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_hallofmirrors = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_hollow = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
if G.hand.config.card_limit < j.ability.extra.thresh then
|
||||||
|
local diff = j.ability.extra.thresh - G.hand.config.card_limit
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult_per * diff)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_hugejoker = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_hyperbeam = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.x_mult(j.ability.extra)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_impostor = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
local num_reds = 0
|
||||||
|
for _, card in ipairs(context.full_hand) do
|
||||||
|
if DV.SIM.is_suit(card, "Hearts") or DV.SIM.is_suit(card, "Diamonds") then
|
||||||
|
num_reds = num_reds + 1
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if num_reds == 1 then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_jankman = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.other_joker then
|
||||||
|
local is_vanilla = false
|
||||||
|
for _, j in ipairs(MF_VANILLA_JOKERS) do
|
||||||
|
if j == context.other_joker.config.center.key then
|
||||||
|
is_vanilla = true
|
||||||
|
break
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if not is_vanilla then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_jester = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.add_chips(j.ability.extra.chips)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_loadeddisk = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_lollipop = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.x_mult(j.ability.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_luckycharm = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
local exact_mult, min_mult, max_mult = DV.SIM.get_probabilistic_extremes(pseudorandom("lucky_charm_mult"), j.ability.extra.mult_chance, j.ability.extra.mult, 0)
|
||||||
|
DV.SIM.add_mult(exact_mult, min_mult, max_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_mashupalbum = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.before then
|
||||||
|
if next(context.poker_hands["Flush"]) then
|
||||||
|
local card1 = context.scoring_hand[1]
|
||||||
|
if DV.SIM.is_suit(card1, "Hearts") or DV.SIM.is_suit(card1, "Diamonds") then
|
||||||
|
j.ability.extra.mult = j.ability.extra.mult + 4
|
||||||
|
else
|
||||||
|
j.ability.extra.chips = j.ability.extra.chips + 15
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.add_chips(j.ability.extra.chips)
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_monochrome = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_mspaint = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_philosophical = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_pixeljoker = function(j, context)
|
||||||
|
if context.cardarea == G.play and context.individual then
|
||||||
|
if DV.SIM.is_rank(context.other_card, {4, 9, 14}) then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_rainbow = function(j, context)
|
||||||
|
-- TODO: Unsure how to implement currently
|
||||||
|
end
|
||||||
|
DVSJ.simulate_recycling = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_rosetinted = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_simplified = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.other_joker then
|
||||||
|
if context.other_joker.rarity == 1 then
|
||||||
|
DV.SIM.add_mult(j.ability.extra.mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_spiral = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
local jdata = j.ability.extra
|
||||||
|
local jmult = jdata.mult + math.floor(jdata.coeff * math.cos(math.pi/jdata.dilation * G.GAME.dollars or 0) + 0.5)
|
||||||
|
DV.SIM.add_mult(jmult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_stylemeter = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_teacup = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.before then
|
||||||
|
local hand_data = G.GAME.hands[DV.SIM.env.scoring_name]
|
||||||
|
DV.SIM.add_chips(hand_data.l_chips)
|
||||||
|
DV.SIM.add_mult(hand_data.l_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_the_solo = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.before then
|
||||||
|
if #context.full_hand == 1 then
|
||||||
|
j.ability.extra.x_mult = j.ability.extra.x_mult + j.ability.extra.x_mult_gain
|
||||||
|
end
|
||||||
|
elseif context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_tonersoup = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_treasuremap = function(j, context)
|
||||||
|
-- Effect not relevant
|
||||||
|
end
|
||||||
|
DVSJ.simulate_triangle = function(j, context)
|
||||||
|
if context.cardarea == G.play and context.individual then
|
||||||
|
-- vs. next(context.poker_hands["Three of a Kind"]) ?
|
||||||
|
if context.scoring_name == "Three of a Kind" then
|
||||||
|
DV.SIM.x_mult(j.ability.extra.x_mult)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
DVSJ.simulate_virtual = function(j, context)
|
||||||
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
DV.SIM.x_mult(j.ability.extra)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local MF_VANILLA_JOKERS = {"j_joker", "j_greedy_joker", "j_lusty_joker", "j_wrathful_joker", "j_gluttenous_joker", "j_zany", "j_mad", "j_crazy", "j_droll", "j_sly", "j_wily", "j_clever", "j_devious", "j_crafty", "j_half", "j_stencil", "j_four_fingers", "j_mime", "j_credit_card", "j_ceremonial", "j_banner", "j_mystic_summit", "j_marble", "j_loyalty_card", "j_8_ball", "j_misprint", "j_dusk", "j_raised_fist", "j_chaos", "j_fibonacci", "j_steel_joker", "j_scary_face", "j_abstract", "j_delayed_grat", "j_hack", "j_pareidolia", "j_gros_michel", "j_even_steven", "j_odd_todd", "j_scholar", "j_business", "j_supernova", "j_ride_the_bus", "j_space", "j_egg", "j_burglar", "j_blackboard", "j_runner", "j_ice_cream", "j_dna", "j_splash", "j_blue_joker", "j_sixth_sense", "j_constellation", "j_hiker", "j_faceless", "j_green_joker", "j_superposition", "j_todo_list", "j_cavendish", "j_card_sharp", "j_red_card", "j_madness", "j_square", "j_seance", "j_riff_raff", "j_vampire", "j_shortcut", "j_hologram", "j_vagabond", "j_baron", "j_cloud_9", "j_rocket", "j_obelisk", "j_midas_mask", "j_luchador", "j_photograph", "j_gift", "j_turtle_bean", "j_erosion", "j_reserved_parking", "j_mail", "j_to_the_moon", "j_hallucination", "j_fortune_teller", "j_juggler", "j_drunkard", "j_stone", "j_golden", "j_lucky_cat", "j_baseball", "j_bull", "j_diet_cola", "j_trading", "j_flash", "j_popcorn", "j_trousers", "j_ancient", "j_ramen", "j_walkie_talkie", "j_selzer", "j_castle", "j_smiley", "j_campfire", "j_ticket", "j_mr_bones", "j_acrobat", "j_sock_and_buskin", "j_swashbuckler", "j_troubadour", "j_certificate", "j_smeared", "j_throwback", "j_hanging_chad", "j_rough_gem", "j_bloodstone", "j_arrowhead", "j_onyx_agate", "j_glass", "j_ring_master", "j_flower_pot", "j_blueprint", "j_wee", "j_merry_andy", "j_oops", "j_idol", "j_seeing_double", "j_matador", "j_hit_the_road", "j_duo", "j_trio", "j_family", "j_order", "j_tribe", "j_stuntman", "j_invisible", "j_brainstorm", "j_satellite", "j_shoot_the_moon", "j_drivers_license", "j_cartomancer", "j_astronomer", "j_burnt", "j_bootstraps", "j_caino", "j_triboulet", "j_yorick", "j_chicot", "j_perkeo"}
|
||||||
@@ -1,28 +1,28 @@
|
|||||||
DVSJ.simulate_j_mp_defensive_joker= function(joker_obj, context)
|
DVSJ.simulate_mp_defensive_joker= function(joker_obj, context)
|
||||||
if context.cardarea == G.jokers and context.global then
|
if context.cardarea == G.jokers and context.global then
|
||||||
DV.SIM.add_chips(joker_obj.ability.extra.chips)
|
DV.SIM.add_chips(joker_obj.ability.t_chips)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
DVSJ.simulate_j_mp_taxes = function(joker_obj, context)
|
DVSJ.simulate_mp_taxes = function(joker_obj, context)
|
||||||
if context.cardarea == G.jokers and context.global then
|
if context.cardarea == G.jokers and context.global then
|
||||||
DV.SIM.add_mult(joker_obj.ability.mult)
|
DV.SIM.add_mult(joker_obj.ability.extra.mult)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
DVSJ.simulate_j_mp_pacifist = function(joker_obj, context)
|
DVSJ.simulate_mp_pacifist = function(joker_obj, context)
|
||||||
if context.cardarea == G.jokers and context.global then
|
if context.cardarea == G.jokers and context.global then
|
||||||
DV.SIM.x_mult(joker_obj.ability.extra.Xmult)
|
DV.SIM.x_mult(joker_obj.ability.extra.x_mult)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
DVSJ.simulate_j_mp_conjoined_joker = function(joker_obj, context)
|
DVSJ.simulate_mp_conjoined_joker = function(joker_obj, context)
|
||||||
if context.cardarea == G.jokers and context.global then
|
if context.cardarea == G.jokers and context.global then
|
||||||
DV.SIM.x_mult(joker_obj.ability.extra.Xmult)
|
DV.SIM.x_mult(joker_obj.ability.extra.x_mult)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
DVSJ.simulate_j_mp_hanging_chad = function(joker_obj, context)
|
DVSJ.simulate_mp_hanging_chad = function(joker_obj, context)
|
||||||
if context.cardarea == G.play and context.repetition then
|
if context.cardarea == G.play and context.repetition then
|
||||||
if context.other_card == context.scoring_hand[1] and not context.other_card.debuff then
|
if context.other_card == context.scoring_hand[1] and not context.other_card.debuff then
|
||||||
DV.SIM.add_reps(joker_obj.ability.extra)
|
DV.SIM.add_reps(joker_obj.ability.extra)
|
||||||
@@ -33,14 +33,14 @@ DVSJ.simulate_j_mp_hanging_chad = function(joker_obj, context)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
DVSJ.simulate_j_mp_lets_go_gambling = function(joker_obj, context)
|
DVSJ.simulate_mp_lets_go_gambling = function(joker_obj, context)
|
||||||
if context.cardarea == G.jokers and context.before then
|
if context.cardarea == G.jokers and context.global then
|
||||||
|
|
||||||
local rand = pseudorandom("gambling") -- Must reuse same pseudorandom value:
|
local rand = pseudorandom("gambling") -- Must reuse same pseudorandom value:
|
||||||
local exact_xmult, min_xmult, max_xmult = DV.SIM.get_probabilistic_extremes(rand, .25, 4, 1)
|
local exact_xmult, min_xmult, max_xmult = DV.SIM.get_probabilistic_extremes(rand, 4, 4, 1)
|
||||||
local exact_money, min_money, max_money = DV.SIM.get_probabilistic_extremes(rand, .25, 10, 0)
|
local exact_money, min_money, max_money = DV.SIM.get_probabilistic_extremes(rand, 4, 10, 0)
|
||||||
|
|
||||||
DV.SIM.add_dollars(exact_money, min_money, max_money)
|
DV.SIM.add_dollars(exact_money, min_money, max_money)
|
||||||
DV.SIM.add_xmult(exact_xmult, min_xmult, max_xmult)
|
DV.SIM.x_mult(exact_xmult, min_xmult, max_xmult)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
33
lovely.toml
33
lovely.toml
@@ -5,31 +5,36 @@ priority = 0
|
|||||||
|
|
||||||
# This manifest assumes the following release structure:
|
# This manifest assumes the following release structure:
|
||||||
#
|
#
|
||||||
# DVSimulate/
|
# Fantoms-Preview/
|
||||||
# ├─ Engine.lua
|
# ├─ FNPreview
|
||||||
# ├─ Init.lua
|
# ├─ FNSimulate
|
||||||
# ├─ Utils.lua
|
|
||||||
# ├─ Jokers/
|
|
||||||
# │ ├─ _Vanilla.lua
|
|
||||||
# │ ├─ etc.
|
|
||||||
|
|
||||||
[[patches]]
|
[[patches]]
|
||||||
[patches.copy]
|
[patches.copy]
|
||||||
target = "globals.lua"
|
target = "globals.lua"
|
||||||
position = "append"
|
position = "append"
|
||||||
sources = ["FNSimulate/Init.lua", "FNPreview/Init.lua", "FNPreview/Card.lua"]
|
sources = [
|
||||||
|
"FNSimulate/Init.lua",
|
||||||
|
"FNPreview/Init.lua"
|
||||||
|
]
|
||||||
|
|
||||||
[[patches]]
|
[[patches]]
|
||||||
[patches.copy]
|
[patches.copy]
|
||||||
target = "main.lua"
|
target = "main.lua"
|
||||||
position = "append"
|
position = "append"
|
||||||
sources = ["FNPreview/Core.lua", "FNPreview/Utils.lua"]
|
sources = [
|
||||||
|
"FNPreview/Core.lua",
|
||||||
|
"FNPreview/Utils.lua"
|
||||||
|
]
|
||||||
|
|
||||||
[[patches]]
|
[[patches]]
|
||||||
[patches.copy]
|
[patches.copy]
|
||||||
target = "functions/common_events.lua"
|
target = "functions/common_events.lua"
|
||||||
position = "append"
|
position = "append"
|
||||||
sources = ["FNSimulate/Engine.lua", "FNSimulate/Utils.lua"]
|
sources = [
|
||||||
|
"FNSimulate/Engine.lua",
|
||||||
|
"FNSimulate/Utils.lua"
|
||||||
|
]
|
||||||
|
|
||||||
[[patches]]
|
[[patches]]
|
||||||
[patches.copy]
|
[patches.copy]
|
||||||
@@ -37,21 +42,21 @@ target = "card.lua"
|
|||||||
position = "append"
|
position = "append"
|
||||||
sources = [
|
sources = [
|
||||||
"FNSimulate/Jokers/_Vanilla.lua",
|
"FNSimulate/Jokers/_Vanilla.lua",
|
||||||
"FNSimulate/Jokers/Multiplayer.lua",
|
"FNSimulate/Jokers/Multiplayer.lua"
|
||||||
]
|
]
|
||||||
|
|
||||||
[[patches]]
|
[[patches]]
|
||||||
[patches.copy]
|
[patches.copy]
|
||||||
target = "functions/UI_definitions.lua"
|
target = "functions/UI_definitions.lua"
|
||||||
position = "append"
|
position = "append"
|
||||||
sources = ["FNPreview/Interface.lua"]
|
sources = [ "FNPreview/Interface.lua" ]
|
||||||
|
|
||||||
[[patches]]
|
[[patches]]
|
||||||
[patches.pattern]
|
[patches.pattern]
|
||||||
target = '''=[SMODS _ "src/overrides.lua"]'''
|
target = '''=[SMODS _ "src/overrides.lua"]'''
|
||||||
pattern = "function get_straight(hand, min_length, skip, wrap)"
|
pattern = "function Blind:debuff_hand(cards, hand, handname, check)"
|
||||||
position = 'after'
|
position = 'after'
|
||||||
payload = '''
|
payload = '''
|
||||||
hand = clean_hand(hand)
|
do return debuff_hand(self, cards, hand, handname, check) end
|
||||||
'''
|
'''
|
||||||
match_indent = true
|
match_indent = true
|
||||||
|
|||||||
Reference in New Issue
Block a user