feedback6 R21B: 联防 plays on the round's battlefield again — its terrain, crates, water, devices and runes, as in 0.1.4 (the owner's decision of 2026-10-07, 「官服保留地形,改回去」; GitHub #244). 0.2.0's escaped-level map (8a436249, §25.6.4) is withdrawn: that map is the placeholder grid all 39 wave template levels carry, tile for tile; only the 11 stage levels have terrain. match/unitePhase.js _uniteOpts fields this.stageId in both combat modes, unite.js uniteStageId is removed, the client draws the 联防 on the board's stage again (screens/game.js: 0.1.4's ownStage / baseStage, no map switch, nothing to restore on leaving), the dev mock likewise. Kept from 0.2.0: own-board 突袭 / 乌尔比安 S3 landings (onOwnBoard, raidTile untouched), the bounty payee, the 联防 BGM, the SETTLE result box. data/stages.json keeps the two kind 'unite' records (no field uses them; engine tests use them as a plain two-halves road); tools/build-data.mjs comments only, an offline rebuild reproduces data/ byte for byte. The 联防 battle input is byte-identical to v0.1.4's in 20 cases (5 stages × 1 / 2 helpers × both combat modes); GitHub #41 item 3 (野鬃 pushing walkers back across the gate onto the other half) is back with v0.1.4's numbers, none off the map. Tests: test/match/feedback5-unite-map.test.js rewritten (6, all fail on the parent), test/e2e/coop.e2e.mjs checks the 联防 field's drawn stage; docs: DATA §12, META §4, PLAYING §5, design/geometry-time, I18N, the §25.6.4 pointer; golden: fields unite-1 (escaped_single → act1autochess_m02) and unite-2 (escaped_multi → act1autochess_m07), the stages of 0.1.4, and the co-op matches whose 联防 rounds come out differently on the round's map — coop2-NORMAL-3, coop2-HARD-4, coop3-ABYSS-5, coop4-ABYSS-7, coop2-NORMAL-8-serverrun, coop2-NORMAL-14-standins (now a victory)
This commit is contained in:
1 parent
ac6de8a12d
commit
75202776cc
25 files changed
+333
-281
No files matched your search
+8
-5
@@ -664,7 +664,7 @@ test('stages: player-facing names are clean Chinese "战场#NN…" labels (no re
|
||||
// Regression: research 05 named act1 m01 '战场#01 (upper half #01)'; the English note reached the
|
||||
// briefing BATTLEFIELD row. Names come from research only, so the build must strip such notes.
|
||||
for (const s of Object.values(stages)) {
|
||||
if (s.kind === 'unite') continue; // the two 联防 maps: the remake's own label, checked in the 联防 test below
|
||||
if (s.kind === 'unite') continue; // the escaped levels' two maps: the remake's own label, checked in the test below
|
||||
assert.match(s.name, /^战场#\d{2}(?:\((?:上半|下半)\))?(?: \S.*)?$/, `${s.id}: name ${JSON.stringify(s.name)}`);
|
||||
assert.doesNotMatch(s.name, /[A-Za-z]/, `${s.id}: Latin text in name ${JSON.stringify(s.name)}`);
|
||||
assert.equal(s.name, s.name.trim().replace(/\s+/g, ' '), `${s.id}: stray whitespace in name`);
|
||||
@@ -673,8 +673,10 @@ test('stages: player-facing names are clean Chinese "战场#NN…" labels (no re
|
||||
assert.equal(stages.act2autochess_m01.name, '战场#05(下半) 源石流发生装置');
|
||||
});
|
||||
|
||||
test('stages: the 联防 maps (GitHub #41) — the escaped template levels, one per helper count, never a match stage', () => {
|
||||
// act2autochess constData escapedBattleTemplateMapSinglePlayer / MultiPlayer → config.unite.templates { 1, 2 }
|
||||
test('stages: the escaped levels\' maps — one per helper count, never a match stage (and since 0.2.1 never the 联防 field)', () => {
|
||||
// act2autochess constData escapedBattleTemplateMapSinglePlayer / MultiPlayer → config.unite.templates { 1, 2 }. 0.2.0
|
||||
// fought the 联防 battle on these maps (GitHub #41); 联防 plays on the round's battlefield again (the owner's decision of
|
||||
// 2026-10-07, test/match/feedback5-unite-map.test.js) and the records stay as the official level data
|
||||
assert.deepEqual(config.unite.templates, { 1: 'act1autochess_escaped_single', 2: 'act1autochess_escaped_multi' });
|
||||
for (const [n, id] of Object.entries(config.unite.templates)) {
|
||||
const s = stages[id];
|
||||
@@ -688,13 +690,14 @@ test('stages: the 联防 maps (GitHub #41) — the escaped template levels, one
|
||||
assert.equal(s.name, `联防阵地(${n}名玩家)`);
|
||||
assert.deepEqual(s.devices, [], 'no crates, platforms or other devices');
|
||||
assert.deepEqual(s.special, {}, 'no water, mire, smog or infection');
|
||||
// the official level map (level_act1autochess_escaped_*.json): two road halves joined at col 10, not the round's stage
|
||||
// the official level map (level_act1autochess_escaped_*.json): two road halves joined at col 10
|
||||
assert.deepEqual(s.rows.slice(9, 13), ['##ErrrrrrrSrrrrrrrS##', '###rrrrrrr#rrrrrrr###', '###rrrrrrr#rrrrrrr###', '###rrrrrrrSrrrrrrrS##']);
|
||||
for (let r = 9; r <= 12; r++) for (const c of [19, 20]) assert.equal(s.tiles[s.rows[r][c]].groundPassable, false, `${id} (${r},${c}) is no ground`);
|
||||
assert.ok(s.groundPaths['9,10->9,2'] && s.groundPaths['9,18->9,2'], 'walkable from both gates');
|
||||
}
|
||||
// the two maps are tile for tile the same: they differ in their routes (data/waves.json — 1 helper enters at col 10,
|
||||
// 2 helpers at col 18 through the checkpoint (9,10))
|
||||
// 2 helpers at col 18 through the checkpoint (9,10)), which the 联防 field follows on the round's stage (its gates
|
||||
// (9,10) / (12,10) and (9,18) / (12,18))
|
||||
assert.deepEqual(stages.act1autochess_escaped_single.rows, stages.act1autochess_escaped_multi.rows);
|
||||
assert.deepEqual(waves.act1autochess_escaped_single.routes.map((r) => r.start), [[9, 10], [9, 10], [12, 10], [9, 10], [9, 10], [9, 10], [9, 10], [9, 10]]);
|
||||
assert.deepEqual(waves.act1autochess_escaped_multi.routes.map((r) => r.start), [[9, 18], [9, 18], [12, 18], [9, 18], [9, 18], [9, 18], [9, 18], [9, 18]]);
|
||||
|
||||
Reference in new issue
Block a user