feedback2 WC: 阿戈尔's devour cancels the pending marks of a unit it knocked out, also when that unit is revived at once, so the revived members stay standing (GitHub #33 item 1)
This commit is contained in:
1 parent
2a03467897
commit
215d52efe3
5 files changed
+84
-7
No files matched your search
@@ -339,7 +339,9 @@ function installLaterano(battle, pid, bb, members) {
|
||||
* 物理流失 (PRTS 盟约记录: "造成5000点物理流失", 修正 "【吞噬】的物理流失来源为被付与目标自身;单位被【吞噬】击杀时,击杀来源始终为
|
||||
* 对应标记的付与来源"; PRTS 作战机制: a 物理流失 "会受到目标当前防御力…影响而相应衰减") — less the target's DEF as a physical hit
|
||||
* (its own source: no DEF ignore), then battle.loseHp: no shields, dodge or damage multipliers (DEF-free until 0.1.1); the
|
||||
* kill is credited to the marker — in marking order. A unit that died cancels its remaining marks (as target and as marker).
|
||||
* kill is credited to the marker — in marking order. A unit knocked out during the pass cancels its remaining marks, also
|
||||
* when it is revived at once (the 5-tier 立刻复活, 埃芒加德 / M3茧甲): as target (PRTS 盟约记录 "目标首次被击倒后解除自身被付与
|
||||
* 但还未触发的【吞噬】效果") and as marker (the remake's rule since 0.1.0, [ASSUMED]: PRTS names only the target).
|
||||
* Each devoured operator adds its tier to 阿戈尔 once (IN_BATTLE gain, disabled in 联防 / boss fields).
|
||||
* Tokens / devices / empty tiles are never devoured.
|
||||
*/
|
||||
@@ -382,8 +384,14 @@ function devour(battle, pid, bb, members) {
|
||||
}
|
||||
const amount = num(bb.damage_value, 0);
|
||||
const layered = new Set();
|
||||
// knocked out during the pass = off the field, or in another deployment than when the marks were placed (items
|
||||
// deploymentOf: the 5-tier revive redeploys, 埃芒加德 / M3茧甲 revive in place) — a revived member was standing again
|
||||
// when its pending marks used to knock it out a second time and spend every revive at t = 0 (GitHub #33)
|
||||
const dep = new Map();
|
||||
for (const pair of marks) for (const u of pair) if (!dep.has(u)) dep.set(u, items.deploymentOf(u));
|
||||
const knocked = (u) => !u.alive || items.deploymentOf(u) !== dep.get(u);
|
||||
for (const [m, t] of marks) {
|
||||
if (!t.alive || !m.alive) continue;
|
||||
if (knocked(t) || knocked(m)) continue;
|
||||
S.fxOn(battle, 'devour', t, 'bond:egirShip', 'devour', { from: m.id });
|
||||
if (amount > 0) battle.loseHp(t, mitigate(amount, 'phys', t.s), { source: m, tags: ['bond:egir:devour'] });
|
||||
if (!layered.has(t)) {
|
||||
@@ -408,6 +416,8 @@ function installEgir(battle, pid, bb, members) {
|
||||
// fell —, or its own home when it fell on another board piece's home; PRTS 卫戍协议/帮助 §作战阶段 单位部署) with full
|
||||
// HP, SP reset and `deploy` effects (卡西米尔 / 叙拉古). Death priority 11: before 不屈 (10),
|
||||
// whose redeploy "also consumes a 复活 charge" — with this order the charge is always the one used, same outcome.
|
||||
// A member the battle-start devour knocks out spends a charge like any other first knock-out; the marks still pending
|
||||
// on it are cancelled (devour), so it stays standing.
|
||||
const memberSet = new Set(members);
|
||||
const max = Math.max(0, Math.floor(num(bb.max_free_respawn_cnt, 0)));
|
||||
const st = { knocked: new Set(), revives: 0 };
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// server/sim/content/items.js — equipment & Arts content (research 04, docs/DATA.md §5).
|
||||
// Battle side: install(battle) is called once per Battle by content/index.js (inside try/catch).
|
||||
// Prep side: registerMeta(registry) is called once at server boot by match/effectsMeta.js.
|
||||
// lendItemEffects(battle, fromUnit, toUnit, { maxTier, duration }) is used by 萨尔贡 × 娜仁图亚 (bands).
|
||||
export { install, lendItemEffects } from './items/battle.js';
|
||||
// lendItemEffects(battle, fromUnit, toUnit, { maxTier, duration }) is used by 萨尔贡 × 娜仁图亚 (bands); deploymentOf(u)
|
||||
// (the deployment a unit is in — a redeploy or an in-place 复活 opens a new one) by 阿戈尔's devour (bonds/core.js).
|
||||
export { install, lendItemEffects, deploymentOf } from './items/battle.js';
|
||||
export { registerMeta } from './items/meta.js';
|
||||
@@ -238,8 +238,9 @@ function hammerState(battle, rt, u) {
|
||||
* [ASSUMED a deployment], 阿戈尔's 立刻复活), and an in-place 复活 (M3茧甲, 埃芒加德: revivedInPlace) opens a new one too
|
||||
* [ASSUMED] — PRTS (M3茧甲 / 埃芒加德 / 阿戈尔 备注) "“复活”的实现方式为:受益者因移动之外的原因退场时下次部署的再部署时间和
|
||||
* 费用归零": officially a revive is a 0-time / 0-cost redeploy; the remake keeps the unit standing instead.
|
||||
* Also read by 阿戈尔's devour (bonds/core.js): a unit whose deployment changed during the pass was knocked out.
|
||||
*/
|
||||
function deploymentOf(u) { return `${u.deploySeq}:${u.mem.revives | 0}`; }
|
||||
export function deploymentOf(u) { return `${u.deploySeq}:${u.mem.revives | 0}`; }
|
||||
|
||||
/** An in-place 复活 (M3茧甲, 埃芒加德) happened: a new deployment for the once-per-deployment lock (deploymentOf). */
|
||||
export function revivedInPlace(u) { if (u && u.mem) u.mem.revives = (u.mem.revives | 0) + 1; }
|
||||
|
||||
Reference in new issue
Block a user