feedback5 WE1: 秘术师 stores its energy at the attack check, not one interval later (GitHub #181)
PRTS 分支特性信息 秘术师: "能量储存与攻击占用相同的攻击间隔:在进行攻击判定时…若无有效目标且能量储存数未满,则改为储存一份 攻击能量(属于攻击行为);仅没有有效目标,且能量储存数已满的情况下才进入待机状态", "攻击被打断且弹道未能成功生成的情况下,储存的 能量不会被消耗"; PRTS 异常效果 缴械 "秘术师储存能量同样无法进行". - ai.js updateAlly: a ready unit (able to act, not disarmed) whose attack check finds no valid target — no target, or its profile's canAttack false (a 秘术师 kit's target rule: 深靛's bound enemies, 维伊's marked ones) — calls the profile's storeEnergy; a stored energy restarts the attack interval, a full store idles with the attack ready. A DEFAULT cast at the check that leaves no target stores in the same check. - professions.js mystic: storeEnergy (up to bb times), releaseEnergy (performAttack, after beforeAttack: a cancelled shot keeps them) and hitsFn(b, u, info) — the energies leave with the attack and land with its main hit; the old separate store timer (it started only once the attack was ready and never restarted the interval) is gone. [ASSUMED] a redeployment holds no energy. - 维伊 / 黑键 kits: their own tick stores become the kit's storeEnergy on the shared check; 深靛 / 维伊 no longer write hadTarget themselves. Golden: roster-003, roster-021, roster-022, bond-preciShip-high (深靛 stores at her check); matches solo-FUNNY-1, solo-NORMAL-2, solo-HARD-2, solo-ABYSS-1, solo-ABYSS-2, coop2-NORMAL-3, coop2-HARD-4, coop4-FUNNY-6, coop4-ABYSS-7, coop2-NORMAL-8-serverrun, solo-HARD-9-boosted, coop2-ABYSS-10-boosted, coop2-NORMAL-14-standins (each fields 深靛); diy-032 (维伊) and diy-114 (黑键): the first store after a redeployment comes at the next tick's attack check instead of the end of the redeploy tick (with the old tick store added back as a fallback the diy family matches the old digests). fields, standins unchanged. Tests: test/sim/feedback5-mystic-store.test.js (new, 4); op_veen, op_ebnhlz, kits_t1t2, kits_alt_t1 pass unchanged. Docs: SIM.md §Professions (mystic row, profile hooks).
This commit is contained in:
1 parent
a009d77d71
commit
8f62f3e360
11 files changed
+354
-214
No files matched your search
@@ -9,9 +9,9 @@
|
||||
// - Trait (秘术师) "攻击造成法术伤害,在找不到攻击目标时可以将攻击能量储存起来之后一齐发射" (ranged arts, hits air units,
|
||||
// targetable by ground enemies). PRTS 分支特性信息 秘术师: "能量储存与攻击占用相同的攻击间隔:在进行攻击判定时,若范围内存在
|
||||
// 有效目标,则进行普通攻击;若无有效目标且能量储存数未满,则改为储存一份攻击能量(属于攻击行为)" — when her attack is ready
|
||||
// and she has no valid target she stores one energy and her attack interval starts again (this kit replaces the
|
||||
// engine's mystic profile, which stores one interval after the attack is ready); the energies fly with her next attack,
|
||||
// at its target ("由储存能量形成的弹道造成攻击力100%的法术普通伤害").
|
||||
// and she has no valid target she stores one energy and her attack interval starts again (the shared 秘术师 profile,
|
||||
// professions.js installMystic, with this kit's `storeEnergy`); the energies fly with her next attack, at its target
|
||||
// ("由储存能量形成的弹道造成攻击力100%的法术普通伤害").
|
||||
// T1 “在挥刀之前” "特性储存的能量达到3个时,合成为1个转置能量(至多储存等同于9倍的能量)" (trait bb merge_cnt 3, times 9):
|
||||
// 3 stored make 1 转置能量, at most times / merge_cnt of those, then no more storing (备注 "转置能量数量达到上限时,停止储存
|
||||
// 攻击能量"); a 转置能量 hits for merge_cnt × ATK (备注 "攻击力300%的法术普通伤害"). Every shot uses the ATK it left with
|
||||
@@ -39,7 +39,7 @@
|
||||
// preferring an enemy not hit yet by it, else another one, else the same (text "优先不同目标" [ASSUMED order]), each
|
||||
// attack@bounce_atk_scale × the cached ATK arts. The skill ends when the bullets run out.
|
||||
|
||||
import { num, talentBb, moduleBb, traitBb, skillRec, batMod, up, toggleBuff } from '../shared/tier1.js';
|
||||
import { num, talentBb, moduleBb, traitBb, skillRec, batMod, toggleBuff } from '../shared/tier1.js';
|
||||
import { canTargetEnemy, sortEnemyTargets } from '../../../targeting.js';
|
||||
|
||||
const S1 = 'skchr_veen_1';
|
||||
@@ -146,23 +146,19 @@ export default {
|
||||
trait: {
|
||||
hitsFn: () => 0, // the volley's hits are the kit's (land)
|
||||
onEachHit(battle, unit, victim, hc) { if (hc.kind === 'main' && victim && victim.side === 'enemy') land(battle, unit, victim, hc.attackId, !!hc.isSkill); },
|
||||
// only enemies under her 战争技艺 in range: she holds her fire (and stores energy)
|
||||
canAttack(battle, u) {
|
||||
const ok = validTargets(battle, u, u.profile).length > 0;
|
||||
if (!ok) u.trait.hadTarget = false;
|
||||
return ok;
|
||||
// only enemies under her 战争技艺 in range: no valid target — she holds her fire (and stores energy)
|
||||
canAttack(battle, u) { return validTargets(battle, u, u.profile).length > 0; },
|
||||
// the mystic store (the shared profile calls it at her attack check with no valid target — professions.js
|
||||
// installMystic: an attack action, the interval restarts): one energy, 3 merge into a 转置能量; none once the
|
||||
// 转置能量 are at their cap (a full store: she idles)
|
||||
storeEnergy(battle, unit) {
|
||||
const v = stateOf(unit);
|
||||
if (v.t >= tMax) return false;
|
||||
if (++v.s >= merge) { v.s -= merge; v.t++; }
|
||||
return true;
|
||||
},
|
||||
install(battle, unit) {
|
||||
battle.on('deploy', (ctx) => { if (ctx.unit === unit) unit.trait.veen = null; }, { owner: unit });
|
||||
// the mystic store: her attack ready and no valid target ⇒ one energy, an attack action (the interval restarts);
|
||||
// 3 merge into a 转置能量 (the attack loop ran first this tick: a valid target was attacked instead)
|
||||
battle.on('tick', () => {
|
||||
const v = stateOf(unit);
|
||||
if (!up(unit) || !unit.canAct || unit.s.flags.disarm || unit.atkCd > 0 || v.t >= tMax) return;
|
||||
if (validTargets(battle, unit, unit.profile).length) return;
|
||||
if (++v.s >= merge) { v.s -= merge; v.t++; }
|
||||
unit.atkCd = unit.s.interval;
|
||||
}, { owner: unit });
|
||||
battle.on('death', (ctx) => { if (ctx.unit && ctx.unit.side === 'enemy') stateOf(unit).q.delete(ctx.unit.id); }, { owner: unit });
|
||||
},
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user