feedback2 WH: 荒芜拉普兰德 S3's drones pick the nearest enemy by its position (a huge leader's centre), the owner's decision so leader rounds stay close to 0.1.1
This commit is contained in:
1 parent
f88b2368f6
commit
a4cf492160
1 file changed
+6
-5
@@ -2801,15 +2801,16 @@ function whitw2(bb, chess, def) {
|
||||
};
|
||||
// speed v → v + acc·dt (capped); the distance covered at the mean of the two (exact under constant acceleration)
|
||||
const accelerate = (d, lim, dt) => { const v1 = Math.min(lim.max, d.v + lim.acc * dt), s = ((d.v + v1) / 2) * dt; d.v = v1; return s; };
|
||||
// ② the selectable enemy nearest to the drone, ties broken by the one nearest to her. [ASSUMED] a huge enemy's distance
|
||||
// is to its hit rectangle (body.js bodyDist), as in the sim's other nearest-enemy picks (targeting.js sortEnemyTargets
|
||||
// 'nearest' / 'farthest', tier3 enemiesAround, 异客's storm chain, 溯光星源's bounces and links): a huge leader (胄, 管 …)
|
||||
// is near every drone around it, so in such a round the drones mostly lock the leader
|
||||
// ② the selectable enemy nearest to the drone, ties broken by the one nearest to her. [ASSUMED] distances are measured
|
||||
// to every enemy's position (a huge enemy's centre, its 判定中心) — the owner's decision of 2026-10-04: the centre, so
|
||||
// leader rounds stay close to 0.1.1; the sim's general convention for operator-side distance picks, the hit rectangle
|
||||
// (body.js bodyDist: targeting.js sortEnemyTargets 'nearest', tier3 enemiesAround, 异客 / 溯光星源's chains), was
|
||||
// considered — it made a huge leader (胄, 管) the nearest enemy of every drone around it (DESIGN §22.9)
|
||||
const pickTarget = (battle, unit, d, ok) => {
|
||||
let best = null, bd = Infinity, bh = Infinity;
|
||||
for (const e of battle.enemies) {
|
||||
if (!ok(e)) continue;
|
||||
const de = bodyDist(e, d.x, d.y), dh = bodyDist(e, unit.x, unit.y);
|
||||
const de = Math.hypot(e.x - d.x, e.y - d.y), dh = Math.hypot(e.x - unit.x, e.y - unit.y);
|
||||
if (de < bd - 1e-9 || (de <= bd + 1e-9 && dh < bh - 1e-9)) { best = e; bd = de; bh = dh; }
|
||||
}
|
||||
return best;
|
||||
|
||||
Reference in new issue
Block a user