From e9241720f871dad154862ed1fa7e36f7e55ffcfc Mon Sep 17 00:00:00 2001 From: mengxinzxz <2223529500@qq.com> Date: Thu, 30 May 2024 21:00:06 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=86=85=E4=BA=8B=E5=A4=96?= =?UTF-8?q?=E4=BA=8BmarkCharacter=E5=A4=B4=E5=83=8F=E5=86=99=E5=8F=8D?= =?UTF-8?q?=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- character/collab/skill.js | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/character/collab/skill.js b/character/collab/skill.js index 919bb75fe..32c034e2f 100644 --- a/character/collab/skill.js +++ b/character/collab/skill.js @@ -86,8 +86,7 @@ const skills = { ) { const result = await player .chooseTarget(get.prompt("dchuanli"), "令一名其他角色的所有技能失效,然后令其获得〖直谏〗和〖固政〗直到其回合结束", (card, player, target) => { - if (player == target) return false; - return !target.hasSkill("dchuanli_zhangzhang") && !target.hasSkill("dchuanli_zhouyu"); + return target != player && !target.hasSkill("dchuanli_zhangzhang"); }) .set("ai", target => { const player = get.event("player"); @@ -105,13 +104,12 @@ const skills = { const target = result.targets[0]; await player.logSkill("dchuanli", target); target.addTempSkill("dchuanli_zhangzhang", { player: "phaseAfter" }); - target.markSkillCharacter("dchuanli_zhangzhang", "re_zhouyu", "唤理-内事", "内事不决问张昭"); + target.markSkillCharacter("dchuanli_zhangzhang", "zhangzhang", "唤理-内事", "内事不决问张昭"); await target.addAdditionalSkills("dchuanli_zhangzhang", ["zhijian", "guzheng"]); } } const targets = game.filterPlayer(target => { - if (target == player) return false; - if (target.hasSkill("dchuanli_zhangzhang") || target.hasSkill("dchuanli_zhouyu")) return false; + if (target == player || target.hasSkill("dchuanli_zhouyu")) return false; return ( player.getHistory("useCard", evt => { return (evt.targets || []).includes(target); @@ -121,7 +119,6 @@ const skills = { if (targets.length) { const result = await player .chooseTarget(get.prompt("dchuanli"), "令一名其他角色的所有技能失效,然后令其获得〖直谏〗和〖固政〗直到其回合结束", (card, player, target) => { - if (player == target) return false; return get.event("targets").includes(target); }) .set("ai", target => { @@ -141,7 +138,7 @@ const skills = { const target = result.targets[0]; await player.logSkill("dchuanli", target); target.addTempSkill("dchuanli_zhouyu", { player: "phaseAfter" }); - target.markSkillCharacter("dchuanli_zhouyu", "zhangzhang", "唤理-外事", "外事不决问周瑜"); + target.markSkillCharacter("dchuanli_zhouyu", "re_zhouyu", "唤理-外事", "外事不决问周瑜"); await target.addAdditionalSkills("dchuanli_zhouyu", ["reyingzi", "refanjian"]); } }