Buff voucher

This commit is contained in:
Emik 2026-06-21 00:06:48 +02:00
parent 480c4ffd45
commit 2b78455ff8
Signed by: emik
GPG key ID: 6B0CD72A5E503BDF
4 changed files with 17 additions and 13 deletions

View file

@ -500,14 +500,14 @@ return {
name = "Ceres", name = "Ceres",
text = { text = {
"Level up {C:attention}Flush House", "Level up {C:attention}Flush House",
"when it is played", "by {C:attention}#1# {}when it is played",
}, },
}, },
v_Roland_neptune = { v_Roland_neptune = {
name = "Neptune", name = "Neptune",
text = { text = {
"Level up {C:attention}Straight Flush", "Level up {C:attention}Straight Flush",
"when it is played", "by {C:attention}#1# {}when it is played",
}, },
}, },
}, },

View file

@ -3,7 +3,7 @@
"id": "Roland", "id": "Roland",
"name": "Roland", "name": "Roland",
"prefix": "Roland", "prefix": "Roland",
"version": "2.9.20", "version": "2.9.21",
"badge_colour": "8BE9FD", "badge_colour": "8BE9FD",
"display_name": "Roland", "display_name": "Roland",
"main_file": "src/main.lua", "main_file": "src/main.lua",

View file

@ -354,13 +354,11 @@ function SMODS.current_mod:calculate(context)
f {"v_Roland_ceres", "v_Roland_neptune"} f {"v_Roland_ceres", "v_Roland_neptune"}
:where(f.index_into(G.GAME.used_vouchers)) :where(f.index_into(G.GAME.used_vouchers))
:map(f.index_into(G.P_CENTERS)) :map(f.index_into(G.P_CENTERS))
:where("config.hand_type", context.scoring_name) :where("config.extra.hand_type", context.scoring_name)
:any() and :pun "SMODS.Voucher"
SMODS.calculate_effect { :each(function(v, _)
level_up = true, SMODS.smart_level_up_hand(nil, v.config.extra.hand_type, nil, v.config.extra.amount)
message = localize "k_level_up_ex", end)
card = G.play.cards[math.ceil(#G.play.cards / 2)] or G.deck.cards[#G.deck.cards] or {},
}
local improbable, orig = G.GAME.modifiers.Roland_improbable, G.GAME.probabilities local improbable, orig = G.GAME.modifiers.Roland_improbable, G.GAME.probabilities

View file

@ -22,10 +22,13 @@ SMODS.Atlas {
voucher { voucher {
key = "ceres", key = "ceres",
pronouns = "it_its", pronouns = "it_its",
config = {hand_type = "Flush House"}, config = {extra = {amount = 1, hand_type = "Flush House"}},
attributes = {"planet", "passive", "hand_type", "space"}, attributes = {"planet", "passive", "hand_type", "space"},
loc_vars = function(_, _, card)
return {vars = {card.ability.extra.amount}}
end,
in_pool = function(self) in_pool = function(self)
return G.GAME.hands[self.config.hand_type].visible return G.GAME.hands[self.config.extra.hand_type].visible
end, end,
} }
@ -33,6 +36,9 @@ voucher {
key = "neptune", key = "neptune",
pronouns = "it_its", pronouns = "it_its",
requires = {"v_Roland_ceres"}, requires = {"v_Roland_ceres"},
config = {hand_type = "Straight Flush"}, config = {extra = {amount = 2, hand_type = "Straight Flush"}},
attributes = {"planet", "passive", "hand_type", "space"}, attributes = {"planet", "passive", "hand_type", "space"},
loc_vars = function(_, _, card)
return {vars = {card.ability.extra.amount}}
end,
} }