Improve production cockpit realism
This commit is contained in:
1 parent
7613daee84
commit
5455ae7928
9 files changed
+668
-21
No files matched your search
@@ -5,6 +5,9 @@ const VerticalSliceRoot = preload(
|
||||
)
|
||||
const MainMenuScreen = preload("res://game/presentation/main_menu/main_menu_screen.gd")
|
||||
const CockpitHud = preload("res://game/presentation/cockpit/cockpit_hud.gd")
|
||||
const CockpitDetailing = preload(
|
||||
"res://game/presentation/cockpit/cockpit_detailing.gd"
|
||||
)
|
||||
const PauseMenu = preload("res://game/presentation/pause/pause_menu.gd")
|
||||
const ControlsSettingsScreen = preload(
|
||||
"res://game/presentation/settings/controls_settings_screen.gd"
|
||||
@@ -13,7 +16,7 @@ const ProductionInputAdapter = preload(
|
||||
"res://game/infrastructure/input/production_input_adapter.gd"
|
||||
)
|
||||
|
||||
const TEST_COUNT := 51
|
||||
const TEST_COUNT := 55
|
||||
|
||||
var _failures: Array[String] = []
|
||||
|
||||
@@ -76,6 +79,9 @@ func _test_vehicle_slice(composition: VerticalSliceRoot) -> void:
|
||||
var actor = composition.submarine_actor()
|
||||
var camera = composition.camera_controller()
|
||||
var instruments = composition.cockpit_instrument_panel()
|
||||
var detailing: CockpitDetailing = (
|
||||
instruments.detailing() if instruments != null else null
|
||||
)
|
||||
var adapter := composition.input_adapter() as ProductionInputAdapter
|
||||
var hud := composition.active_screen() as CockpitHud
|
||||
var sonar_service = composition.sonar_service()
|
||||
@@ -84,16 +90,27 @@ func _test_vehicle_slice(composition: VerticalSliceRoot) -> void:
|
||||
_expect(actor != null, "production submarine actor is assembled")
|
||||
_expect(camera != null, "cockpit camera is attached to the submarine")
|
||||
_expect(instruments != null, "physical cockpit instruments are assembled")
|
||||
_expect(detailing != null, "cockpit structural detailing is assembled")
|
||||
_expect(hud != null, "critical HUD overlay is assembled")
|
||||
_expect(sonar_service != null, "production sonar service is assembled")
|
||||
_expect(sonar_display != null, "shared sonar presentation is assembled")
|
||||
_expect(composition.latest_update() != null, "dive session starts with a typed update")
|
||||
if actor == null or camera == null or instruments == null or adapter == null or hud == null:
|
||||
if (
|
||||
actor == null
|
||||
or camera == null
|
||||
or instruments == null
|
||||
or detailing == null
|
||||
or adapter == null
|
||||
or hud == null
|
||||
):
|
||||
return
|
||||
|
||||
_expect(instruments.get_node("%WindowFrame") is MeshInstance3D, "cockpit has a physical porthole frame")
|
||||
_expect(instruments.get_node("%Dashboard") is Node3D, "cockpit has a physical dashboard")
|
||||
_expect(instruments.get_node("%SonarScreen") is MeshInstance3D, "cockpit reserves a physical sonar display")
|
||||
_expect(detailing.pressure_hull_rib_count() >= 6, "cockpit exposes reinforced pressure-hull structure")
|
||||
_expect(detailing.pipe_segment_count() >= 13, "cockpit exposes a complete life-support pipe run")
|
||||
_expect(absf(detailing.battery_needle_degrees()) > 100.0, "analog battery gauge follows the dive snapshot")
|
||||
_expect("kWh" in instruments.resources_text() and "kW" in instruments.resources_text(), "battery instrument has exact units")
|
||||
_expect("L/min" in instruments.resources_text(), "oxygen instrument has volume and consumption")
|
||||
_expect("bar" in instruments.integrity_text(), "hull instrument has current and certified pressure")
|
||||
|
||||
Reference in new issue
Block a user