A dungeon now names the boss arena it ends in, and the arena decides the boss. Three entrances in the hub: Warden's Descent, The Choir Vault, Proving Grounds. That replaces the seed coin-flip from the last commit, which was the wrong call. Which boss you are about to fight is the single thing a player decides before walking into a dungeon, and rolling it for them makes that decision unavailable. Only the Proving Grounds still leaves its arena open, because a harness you re-enter every couple of minutes wants whichever fight comes up first -- and it is the one place where "either will do" is true. test_every_boss_has_a_dungeon_that_reaches_it is the check that matters here: adding a boss and forgetting to give it a way in is now a failing test rather than a boss nobody meets. The smoke test asserts all three portals open over a real socket -- bots pick theirs by account id, so a run exercises each. Bullets no longer animate. The sheet's eight frames are a COLOUR cycle rather than a shape change, so running it had every bullet on screen strobing through a palette in unison, which with a few hundred in the air is exactly as hard to look at as it sounds. Each bullet holds one frame and turns slowly instead, offset by its own id so a ring of twenty does not rotate as one rigid wheel. The rate is slow enough that nothing completes a full turn inside its own lifetime, so it reads as drift rather than spin, and a test pins that against the longest-lived bullet in the game. The renderer slices four textures at startup now instead of thirty-two. check.sh clean, 414 tests, SMOKE PASS (22 assertions), all four diagnostics green. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -80,9 +80,36 @@ func test_scaling_one_dungeon_does_not_leak_into_the_next() -> void:
|
||||
|
||||
# --- Instances --------------------------------------------------------------
|
||||
|
||||
## Every dungeon in the hub names its arena, so a player knows what they are
|
||||
## walking into. Only the harness leaves it to the seed.
|
||||
func test_only_the_test_harness_leaves_its_boss_to_chance() -> void:
|
||||
for id in Dungeons.ORDER:
|
||||
var d := Dungeons.get_def(id)
|
||||
if id == Dungeons.PROVING:
|
||||
assert_true(d.arena.is_empty(), "the harness takes either fight")
|
||||
else:
|
||||
assert_false(d.arena.is_empty(), "%s must name its arena" % id)
|
||||
assert_not_null(Content.boss(Rooms.boss_for_arena(d.arena)))
|
||||
|
||||
|
||||
func test_each_real_dungeon_leads_somewhere_different() -> void:
|
||||
var arenas := {}
|
||||
for id in Dungeons.ORDER:
|
||||
var arena := Dungeons.get_def(id).arena
|
||||
if arena.is_empty():
|
||||
continue
|
||||
assert_false(arenas.has(arena), "two portals lead to the same fight")
|
||||
arenas[arena] = true
|
||||
|
||||
|
||||
## The seed is even on purpose. The harness rolls its arena, and only a run
|
||||
## that landed in the SAME arena is comparable -- a different one is a different
|
||||
## size, which moves the rooms and therefore the enemy count.
|
||||
func test_a_proving_run_is_built_weaker_than_a_standard_one() -> void:
|
||||
var hard := Instance.make_dungeon(2, 4242, 1, Dungeons.STANDARD)
|
||||
var easy := Instance.make_dungeon(3, 4242, 1, Dungeons.PROVING)
|
||||
var same_arena := 4242
|
||||
assert_eq(posmod(same_arena, 2), 0, "setup: this seed has to roll warden_hall")
|
||||
var hard := Instance.make_dungeon(2, same_arena, 1, Dungeons.STANDARD)
|
||||
var easy := Instance.make_dungeon(3, same_arena, 1, Dungeons.PROVING)
|
||||
assert_lt(easy.world.boss.hp, hard.world.boss.hp)
|
||||
assert_eq(easy.world.map.width, hard.world.map.width,
|
||||
"same seed and depth must still give the same size of map")
|
||||
|
||||
Reference in New Issue
Block a user