Add unlock condition for Excalibur
This commit is contained in:
parent
d15638243f
commit
1f1914e5de
3 changed files with 17 additions and 5 deletions
|
|
@ -165,8 +165,8 @@ return {
|
||||||
j_Roland_bulldozer = {
|
j_Roland_bulldozer = {
|
||||||
name = "Bulldozer",
|
name = "Bulldozer",
|
||||||
text = {
|
text = {
|
||||||
"Give {X:red,C:white}XMult{} equal to",
|
"Give the {C:attention}Blind",
|
||||||
"the current {C:attention}Blind Size{C:attention}",
|
"{C:attention}Base {}as {X:red,C:white}XMult",
|
||||||
"{C:inactive}(Currently {X:red,C:white}X#1#{C:inactive})",
|
"{C:inactive}(Currently {X:red,C:white}X#1#{C:inactive})",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
@ -212,6 +212,7 @@ return {
|
||||||
"to {C:attention}pull {}this {C:attention}Joker",
|
"to {C:attention}pull {}this {C:attention}Joker",
|
||||||
"{C:inactive}(Currently {C:attention}#2#{C:inactive})",
|
"{C:inactive}(Currently {C:attention}#2#{C:inactive})",
|
||||||
},
|
},
|
||||||
|
unlock = {"Have only {C:enhanced}Stone", "cards in your deck"},
|
||||||
},
|
},
|
||||||
j_Roland_excalibur_Back = {
|
j_Roland_excalibur_Back = {
|
||||||
name = "Excalibur",
|
name = "Excalibur",
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
"id": "Roland",
|
"id": "Roland",
|
||||||
"name": "Roland",
|
"name": "Roland",
|
||||||
"prefix": "Roland",
|
"prefix": "Roland",
|
||||||
"version": "2.9.32",
|
"version": "2.9.33",
|
||||||
"badge_colour": "8BE9FD",
|
"badge_colour": "8BE9FD",
|
||||||
"display_name": "Roland",
|
"display_name": "Roland",
|
||||||
"main_file": "src/main.lua",
|
"main_file": "src/main.lua",
|
||||||
|
|
|
||||||
|
|
@ -35,8 +35,6 @@ local joker = (function()
|
||||||
end
|
end
|
||||||
|
|
||||||
if tbl.defeated_blind then
|
if tbl.defeated_blind then
|
||||||
tbl.discovered, tbl.unlocked = false, false
|
|
||||||
|
|
||||||
function tbl.check_for_unlock()
|
function tbl.check_for_unlock()
|
||||||
return Bakery_API.defeated_blinds[tbl.defeated_blind] > 0
|
return Bakery_API.defeated_blinds[tbl.defeated_blind] > 0
|
||||||
end
|
end
|
||||||
|
|
@ -48,6 +46,10 @@ local joker = (function()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if tbl.check_for_unlock then
|
||||||
|
tbl.discovered, tbl.unlocked = false, false
|
||||||
|
end
|
||||||
|
|
||||||
return q(SMODS.Joker(tbl))
|
return q(SMODS.Joker(tbl))
|
||||||
end
|
end
|
||||||
end)()
|
end)()
|
||||||
|
|
@ -1200,11 +1202,20 @@ joker {
|
||||||
eternal_compat = true,
|
eternal_compat = true,
|
||||||
blueprint_compat = false,
|
blueprint_compat = false,
|
||||||
perishable_compat = true,
|
perishable_compat = true,
|
||||||
|
check_for_unlock = function(_, args)
|
||||||
|
return args.type == "modify_deck" and f(G.playing_cards):all(function(v)
|
||||||
|
return SMODS.has_enhancement(v, "m_stone")
|
||||||
|
end)
|
||||||
|
end,
|
||||||
loc_vars = function(_, info_queue, card)
|
loc_vars = function(_, info_queue, card)
|
||||||
local extra = card.ability.extra
|
local extra = card.ability.extra
|
||||||
local _ = card.fake_card or table.insert(info_queue, G.P_CENTERS.m_stone)
|
local _ = card.fake_card or table.insert(info_queue, G.P_CENTERS.m_stone)
|
||||||
return {vars = {extra.required, extra.scored, extra.xmult}}
|
return {vars = {extra.required, extra.scored, extra.xmult}}
|
||||||
end,
|
end,
|
||||||
|
locked_loc_vars = function(_, info_queue, card)
|
||||||
|
local _ = card.fake_card or table.insert(info_queue, G.P_CENTERS.m_stone)
|
||||||
|
return {vars = {}}
|
||||||
|
end,
|
||||||
generate_ui = function(self, info_queue, card, ...)
|
generate_ui = function(self, info_queue, card, ...)
|
||||||
Bakery_API.werewolf_ui "j_Roland_excalibur_Back" (self, info_queue, card, ...)
|
Bakery_API.werewolf_ui "j_Roland_excalibur_Back" (self, info_queue, card, ...)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue