From 87e7de731c31c9009419512c4a1dc2fe27b9f5c3 Mon Sep 17 00:00:00 2001 From: Voyager Date: Mon, 17 Aug 2026 21:43:57 -0400 Subject: [PATCH] test: respect authored gatherable spawn heights --- tests/world_spawn_multiplayer_validation.gd | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/tests/world_spawn_multiplayer_validation.gd b/tests/world_spawn_multiplayer_validation.gd index 5378188..f1001a3 100644 --- a/tests/world_spawn_multiplayer_validation.gd +++ b/tests/world_spawn_multiplayer_validation.gd @@ -1,7 +1,7 @@ extends SceneTree const MainScene: PackedScene = preload("res://main/main.tscn") -const TEST_PORT: int = 18141 +const TEST_PORT: int = 18170 const EXPECTED_POPULATION: int = 2 @@ -111,12 +111,15 @@ func _validate_population(service: Node, expect_authoritative_state: bool) -> vo var position: Variant = state.get("position") assert(typeof(position) == TYPE_VECTOR3) assert((position as Vector3).is_finite()) - assert((position as Vector3).y > 0.08) + var entry := state.get("data") as GatherableData + assert(entry != null) + assert( + (position as Vector3).y + >= entry.minimum_surface_y - 0.001 + ) if expect_authoritative_state: var quality: int = int(state.get("quality", -1)) assert(FishQuality.is_valid(quality)) - var entry := state.get("data") as GatherableData - assert(entry != null) assert(entry.get_movement_speed_for_quality(quality) > 0.0) assert(entry.get_scare_radius_for_quality(quality) > 0.0)