diff --git a/image/generals/joy__guanping.jpg b/image/generals/joy__guanping.jpg new file mode 100644 index 0000000000000000000000000000000000000000..1a69e46a406444af9329494b049f70458930a2d5 Binary files /dev/null and b/image/generals/joy__guanping.jpg differ diff --git a/image/generals/joy__guanyinping.jpg b/image/generals/joy__guanyinping.jpg new file mode 100644 index 0000000000000000000000000000000000000000..21746a65540612079d09ecacb84675c55f39962f Binary files /dev/null and b/image/generals/joy__guanyinping.jpg differ diff --git a/image/generals/joy__xushu.jpg b/image/generals/joy__xushu.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f6428190a17ff3853fc0dd8215bcddf98be9f4cd Binary files /dev/null and b/image/generals/joy__xushu.jpg differ diff --git a/joy_sp.lua b/joy_sp.lua index 923e353986cb1b6113099ec03d2879454d0d19a5..0e9bb3fa06a3f2873a61f3c257d14a31f1d41518 100644 --- a/joy_sp.lua +++ b/joy_sp.lua @@ -221,12 +221,80 @@ Fk:loadTranslationTable{ [":joy__gongao"] = "锁定技,每当一名其他角色进入濒死状态时,你增加1点体力上限,然后回复1点体力。", ["joy__juyi"] = "举义", [":joy__juyi"] = "限定技,准备阶段,若你体力上限大于全场角色数,你可以将手牌摸至体力上限,然后获得技能〖崩坏〗和〖威重〗。", - -- 可以不发动的觉醒技 村成限定技 ["joy__benghuai"] = "崩坏", [":joy__benghuai"] = "锁定技,结束阶段,若你不是体力值最低的角色,则你失去1点体力或减少1点体力上限,并摸一张牌。", } +local joy__guanyinping = General(extension, "joy__guanyinping", "shu", 3, 3, General.Female) +local joy__huxiao = fk.CreateTriggerSkill{ + name = "joy__huxiao", + anim_type = "offensive", + events = {fk.Damage}, + frequency = Skill.Compulsory, + can_trigger = function(self, event, target, player, data) + return player:hasSkill(self) and player == target and data.damageType == fk.FireDamage and not data.to.dead + end, + on_use = function(self, event, target, player, data) + if data.to.dead then return end + local mark = U.getMark(data.to, "@@joy__huxiao-turn") + table.insertIfNeed(mark, player.id) + player.room:setPlayerMark(data.to, "@@joy__huxiao-turn", mark) + end, +} +local ol__huxiao_targetmod = fk.CreateTargetModSkill{ + name = "#joy__huxiao_targetmod", + bypass_times = function(self, player, skill, scope, card, to) + return table.contains(U.getMark(to, "@@joy__huxiao-turn"), player.id) + end, +} +joy__huxiao:addRelatedSkill(joy__huxiao_targetmod) +local joy__wuji = fk.CreateTriggerSkill{ + name = "joy__wuji", + anim_type = "special", + events = {fk.EventPhaseStart}, + frequency = Skill.Wake, + can_trigger = function(self, event, target, player, data) + return target == player and player:hasSkill(self) and player.phase == Player.Finish and player:usedSkillTimes(self.name, Player.HistoryGame) == 0 + end, + can_wake = function(self, event, target, player, data) + local n = 0 + U.getActualDamageEvents(player.room, 1, function(e) + local damage = e.data[1] + n = n + damage.damage + if n > 2 then return true end + end) + return n > 2 + end, + on_use = function(self, event, target, player, data) + local room = player.room + room:changeMaxHp(player, 1) + if player:isWounded() and not player.dead then + room:recover({ who = player, num = 1, recoverBy = player, skillName = self.name }) + end + if player.dead then return end + for _, id in ipairs(Fk:getAllCardIds()) do + if Fk:getCardById(id).name == "blade" then + if room:getCardArea(id) == Card.DrawPile or room:getCardArea(id) == Card.DiscardPile or room:getCardArea(id) == Card.PlayerEquip then + room:moveCardTo(id, Card.PlayerHand, player, fk.ReasonPrey, self.name) + break + end + end + end + end, +} +joy__guanyinping:addSkill("ol__xuehen") +joy__guanyinping:addSkill(joy__huxiao) +joy__guanyinping:addSkill(joy__wuji) +Fk:loadTranslationTable{ + ["joy__guanyinping"] = "关银屏", + ["#joy__guanyinping"] = "武姬", + ["joy__huxiao"] = "虎啸", + [":joy__huxiao"] = "锁定技,当你对一名角色造成火焰伤害后,本回合你对其使用牌无次数限制。", + ["@@joy__huxiao-turn"] = "虎啸", + ["joy__wuji"] = "武继", + [":joy__wuji"] = "觉醒技,结束阶段,若你本回合造成过至少3点伤害,你加1点体力上限并回复1点体力,,然后从牌堆、弃牌堆或场上获得【青龙偃月刀】。", +} local sunshangxiang = General(extension, "joysp__sunshangxiang", "shu", 3, 3, General.Female) local joy__liangzhu = fk.CreateTriggerSkill{ diff --git a/joy_yj.lua b/joy_yj.lua index d35dc9ddfbed11b828fc82c9db15eb65a78aa6a0..6439121279d728bb56fdda08fa410b5438c03225 100644 --- a/joy_yj.lua +++ b/joy_yj.lua @@ -299,4 +299,124 @@ Fk:loadTranslationTable{ ["#joy__kuangbi-draw"] = "匡弼:是否令 %dest 摸%arg张牌?", ["@@joy__kuangbi"] = "匡弼", } + +local joy__guanping = General(extension, "joy__guanping", "shu", 4) +local joy__longyin = fk.CreateTriggerSkill{ + name = "joy__longyin", + anim_type = "support", + events = {fk.CardUsing}, + can_trigger = function(self, event, target, player, data) + return player:hasSkill(self) and target.phase == Player.Play and data.card.trueName == "slash" and not player:isNude() + end, + on_cost = function(self, event, target, player, data) + local cards = player.room:askForDiscard(player, 1, 1, true, self.name, true, ".", "#joy__longyin-invoke::"..target.id, true) + if #cards > 0 then + self.cost_data = cards + return true + end + end, + on_use = function(self, event, target, player, data) + player.room:throwCard(self.cost_data, self.name, player, player) + if not data.extraUse then + data.extraUse = true + target:addCardUseHistory(data.card.trueName, -1) + end + if data.card.color == Card.Red and not player.dead then + player:drawCards(1, self.name) + end + if data.card.suit == Fk:getCardById(self.cost_data[1]).suit and player:usedSkillTimes("joy__jiezhong", Player.HistoryGame) > 0 then + player:setSkillUseHistory("joy__jiezhong", 0, Player.HistoryGame) + end + end, +} +local joy__jiezhong = fk.CreateTriggerSkill{ + name = "joy__jiezhong", + anim_type = "drawcard", + frequency = Skill.Limited, + events = {fk.EventPhaseStart}, + can_trigger = function(self, event, target, player, data) + return target == player and player:hasSkill(self) and player.phase == Player.Play and + math.min(player.maxHp, 5) > player:getHandcardNum() and player:usedSkillTimes(self.name, Player.HistoryGame) == 0 + end, + on_cost = function(self, event, target, player, data) + local draw = player.maxHp - player:getHandcardNum() + return player.room:askForSkillInvoke(player, self.name, nil, "#joy__jiezhong-invoke:::"..draw) + end, + on_use = function(self, event, target, player, data) + local room = player.room + local n = player.maxHp - player:getHandcardNum() + player:drawCards(n, self.name) + end, +} +joy__guanping:addSkill(joy__longyin) +joy__guanping:addSkill(joy__jiezhong) +Fk:loadTranslationTable{ + ["joy__guanping"] = "关平", + ["#joy__guanping"] = "忠臣孝子", + + ["joy__longyin"] = "龙吟", + [":joy__longyin"] = "每当一名角色在其出牌阶段使用【杀】时,你可以弃置一张牌令此【杀】不计入出牌阶段使用次数,若此【杀】为红色,你摸一张牌。".. + "若你以此法弃置的牌花色与此【杀】相同,你重置〖竭忠〗。", + ["#joy__longyin-invoke"] = "龙吟:你可以弃置一张牌令 %dest 的【杀】不计入次数限制", + ["joy__jiezhong"] = "竭忠", + [":joy__jiezhong"] = "限定技,出牌阶段开始时,若你的手牌数小于体力上限,你可以将手牌补至体力上限。", + ["#joy__jiezhong-invoke"] = "竭忠:是否发动“竭忠”摸%arg张牌? ", + +} + +local joy__xushu = General(extension, "joy__xushu", "shu", 3) +local joy__jujian = fk.CreateTriggerSkill{ + name = "joy__jujian", + anim_type = "support", + events = {fk.EventPhaseStart}, + can_trigger = function(self, event, target, player, data) + return target == player and player:hasSkill(self) and (player.phase == Player.Finish or player.phase == Player.Start)and not player:isNude() + end, + on_cost = function(self, event, target, player, data) + local room = player.room + local tos, id = player.room:askForChooseCardAndPlayers(player, table.map(room.alive_players, Util.IdMapper), 1, 1, ".|.|.|.|.|^basic", "#joy__jujian-choose", self.name, true) + if #tos > 0 then + self.cost_data = {tos[1], id} + return true + end + end, + on_use = function(self, event, target, player, data) + local room = player.room + local to = room:getPlayerById(self.cost_data[1]) + room:throwCard({self.cost_data[2]}, self.name, player, player) + local choices = {"draw2"} + if to:isWounded() then + table.insert(choices, "recover") + end + if not to.faceup or to.chained then + table.insert(choices, "joy__jujian_reset") + end + local choice = room:askForChoice(to, choices, self.name, nil, false, {"draw2", "recover", "joy__jujian_reset"}) + if choice == "draw2" then + to:drawCards(2, self.name) + elseif choice == "recover" then + room:recover({ + who = to, + num = 1, + recoverBy = player, + skillName = self.name + }) + else + to:reset() + end + end, +} +joy__xushu:addSkill("wuyan") +joy__xushu:addSkill(joy__jujian) +Fk:loadTranslationTable{ + ["joy__xushu"] = "徐庶", + ["#joy__xushu"] = "忠孝的侠士", + + ["joy__jujian"] = "举荐", + [":joy__jujian"] = "准备或结束阶段,你可以弃置一张非基本牌,令一名角色选择一项:摸两张牌;回复1点体力;复原武将牌。", + ["#joy__jujian-choose"] = "举荐:你可以弃置一张非基本牌,令一名角色选择摸俩张牌/回复体力/复原武将牌", + ["joy__jujian_reset"] = "复原武将牌", + +} + return extension