From 4c3f187ba178868a47f19c44e5f1848dfda6482f Mon Sep 17 00:00:00 2001 From: 157 <3619242020@qq.com> Date: Wed, 24 Apr 2024 19:08:20 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E8=B0=83=E6=95=B4/=E4=BF=AE=E5=A4=8D/?= =?UTF-8?q?=E4=BC=98=E5=8C=96=E9=83=A8=E5=88=86=E6=8A=80=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- character/diy.js | 90 +++++++++++++++++++++++++++++------------- character/key/skill.js | 7 ++++ 2 files changed, 70 insertions(+), 27 deletions(-) diff --git a/character/diy.js b/character/diy.js index 21eaf15e8..d29e8f68e 100755 --- a/character/diy.js +++ b/character/diy.js @@ -4657,6 +4657,9 @@ game.import("character", function () { ) player.storage.nsfuzhou_draw = true; }, + ai: { + combo: "nsfuzhou" + }, derivation: ["nsfuzhou_damage", "nsfuzhou_draw"], }, nsweiyuan: { @@ -7587,6 +7590,7 @@ game.import("character", function () { }, }, nschangshi: { + mode: ["identity"], enable: "phaseUse", usable: 1, filter(event, player) { @@ -7602,17 +7606,20 @@ game.import("character", function () { multitarget: true, selectTarget: 2, content() { - var tmp = targets[0].hp; - targets[0].hp = targets[1].hp; - targets[1].hp = tmp; - targets[0].update(); - targets[1].update(); - if (Math.abs(targets[0].hp - targets[1].hp) == 1) { - player.loseHp(); - } - //else{ - //player.die(); - //} + game.broadcastAll(function (player, targets) { + player.showIdentity(); + var tmp = targets[0].hp; + targets[0].hp = targets[1].hp; + targets[1].hp = tmp; + targets[0].update(); + targets[1].update(); + if (Math.abs(targets[0].hp - targets[1].hp) == 1) { + player.loseHp(); + } + //else{ + //player.die(); + //} + }, player, targets); }, ai: { order: 10, @@ -7636,6 +7643,7 @@ game.import("character", function () { }, }, nsjianning: { + mode: ["identity"], enable: "phaseUse", usable: 1, filter(event, player) { @@ -7646,6 +7654,11 @@ game.import("character", function () { }, content() { "step 0"; + if (!player.identityShown) { + game.broadcastAll(function (player) { + player.showIdentity(); + }, player); + } player.swapHandcards(target); "step 1"; target.damage(); @@ -7675,6 +7688,7 @@ game.import("character", function () { }, }, nscuanquan: { + mode: ["identity"], init(player) { player.storage.nscuanquan = 0; }, @@ -7707,16 +7721,19 @@ game.import("character", function () { }, content() { player.awakenSkill("nscuanquan"); - var tmp = player.maxHp; - player.identity = "zhu"; - player.maxHp = game.zhu.hp; - player.showIdentity(); - player.update(); - game.zhu.identity = "zhong"; - game.zhu.maxHp = tmp; - game.zhu.showIdentity(); - game.zhu.update(); - game.zhu = player; + game.broadcastAll(function (player) { + var tmp = player.maxHp; + player.identity = "zhu"; + player.maxHp = game.zhu.hp; + player.showIdentity(); + player.update(); + game.zhu.identity = "zhong"; + game.zhu.maxHp = tmp; + game.zhu.showIdentity(); + game.zhu.update(); + game.zhu = player; + }, player); + event.trigger("zhuUpdate"); }, }, nstianji: { @@ -7991,6 +8008,9 @@ game.import("character", function () { }, }, group: "nsshijun_hp", + ai: { + halfneg: true + }, }, nszhaoxin: { mark: true, @@ -8012,6 +8032,9 @@ game.import("character", function () { } }, }, + ai: { + neg: true + }, }, nsxiuxin: { mod: { @@ -10000,6 +10023,9 @@ game.import("character", function () { "step 2"; trigger.cancel(); }, + ai: { + combo: "jugong" + }, }, nsxinsheng: { trigger: { source: "damageEnd" }, @@ -10563,6 +10589,7 @@ game.import("character", function () { }, ai: { expose: 0.2, + combo: "zhucheng" }, }, zhucheng: { @@ -11093,16 +11120,25 @@ game.import("character", function () { inherit: "jianxiong", }, diyjianxiong: { - mode: ["identity"], + mode: ["identity", "guozhan"], trigger: { global: "dieBefore" }, forced: true, filter(event, player) { - return event.player != game.zhu && _status.currentPhase == player; + if (_status.currentPhase !== player) return false; + if (get.mode() === "identity") return event.player != game.zhu; + return get.mode() === "guozhan" && event.player.isFriendOf(player); }, content() { - trigger.player.identity = "fan"; - trigger.player.setIdentity("fan"); - trigger.player.identityShown = true; + game.broadcastAll(function (target, group) { + if (get.mode() === "identity") { + target.identity = group; + target.setIdentity(group); + target.identityShown = true; + } + else { + target.trueIdentity = lib.group.slice(0).filter(i => group !== i).randomGet(); + } + }, trigger.player, get.mode() === "identity" ? "fan" : player.getGuozhanGroup()); }, }, nsshuaiyan: { @@ -12178,7 +12214,7 @@ game.import("character", function () { nsshijun_info: "锁定技,你造成伤害时,你令此伤害+1,并在结算后失去1点体力。", nshunyou: "魂佑", nshunyou_info: - "出阶段限一次,你可以弃置一张基本牌,获得弃牌堆底的一张装备牌和一张锦囊牌,然后你可以将那张装备牌装备给一名角色(允许替换)。如果弃牌堆没有装备以及锦囊牌,则改为摸X张牌,X为损失的体力加一(最多3张)。", + "出牌阶段限一次,你可以弃置一张基本牌,获得弃牌堆底的一张装备牌和一张锦囊牌,然后你可以将那张装备牌装备给一名角色(允许替换)。如果弃牌堆没有装备以及锦囊牌,则改为摸X张牌,X为你已损失的体力值+1(最多3张)。", nswulie: "武烈", nswulie_info: "限定技,准备阶段,你可以失去1点体力上限,从弃牌堆选择最多三张牌以任意顺序放置于牌堆顶。若如此做,此回合的结束阶段,你可以重复此操作。", diff --git a/character/key/skill.js b/character/key/skill.js index efe6814d0..b5621566f 100644 --- a/character/key/skill.js +++ b/character/key/skill.js @@ -149,6 +149,9 @@ const skills = { if (draws) player.draw(draws).gaintag = ["fuuko_chuanyuan"]; player.addSkill("fuuko_chuanyuan_effect"); }, + ai: { + combo: "fuuko_xingdiao" + }, subSkill: { effect: { mod: { @@ -4450,6 +4453,7 @@ const skills = { return player.getUseValue({ name: "kaihua" }); }, }, + combo: "kotori_yumo" }, }, kotori_huazhan2: { onremove: true, charlotte: true }, @@ -9223,6 +9227,9 @@ const skills = { content() { player.turnOver(); }, + ai: { + combo: "yusa_yanyi" + }, }, misa_yusa: { charlotte: true, From 4c0387e6bcd2ab5e34ad16d2850c2ec8b40ee3b4 Mon Sep 17 00:00:00 2001 From: 157 <3619242020@qq.com> Date: Wed, 24 Apr 2024 19:14:12 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=9B=BD=E6=88=98?= =?UTF-8?q?=E7=89=8C=E5=A0=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- character/sp2.js | 3 +++ mode/guozhan.js | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/character/sp2.js b/character/sp2.js index de3e006b4..da9ff336f 100644 --- a/character/sp2.js +++ b/character/sp2.js @@ -9763,6 +9763,9 @@ game.import("character", function () { content: "出牌阶段开始时,你可以亮出牌堆顶的四张牌。你可弃置任意张手牌,并可获得任意张点数之和不大于你弃置的牌点数之和的牌。然后你可将以此法得到的牌以任意方式交给其他角色。", }, + ai: { + combo: "mubing" + }, }, diaoling: { audio: 2, diff --git a/mode/guozhan.js b/mode/guozhan.js index 89853ddca..472dd8216 100644 --- a/mode/guozhan.js +++ b/mode/guozhan.js @@ -24327,7 +24327,7 @@ game.import("mode", function (lib, game, ui, get, ai, _status) { ["heart", 3, "jingfanma", null, ["lianheng"]], ["heart", 4, "shan"], ["heart", 5, "shan"], - ["heart", 6, "shan"], + ["heart", 6, "shan", null, ["lianheng"]], ["heart", 7, "shan"], ["heart", 8, "tao"], ["heart", 9, "tao"],