Feat/1 movement foundation #5

Merged
Dotts merged 40 commits from feat/1-movement-foundation into main 2026-06-03 21:34:25 -07:00
3 changed files with 43 additions and 1 deletions
Showing only changes of commit ceeff6a1ab - Show all commits
+3 -1
View File
@@ -12,4 +12,6 @@ script = ExtResource("1")
[node name="Camera3D" type="Camera3D" parent="PlayerMovementController"] [node name="Camera3D" type="Camera3D" parent="PlayerMovementController"]
[node name="CapsuleShape3D" type="CollisionShape3D" parent="."] [node name="CapsuleShape3D" type="CollisionShape3D" parent="."]
shape = SubResource("") shape = CapsuleShape3D.new()
shape.radius = 0.4
shape.height = 1.8
+34
View File
@@ -0,0 +1,34 @@
extends Node
class_name SmokeRunner
var checks := 0
var failures := []
func _ready() -> void:
var ok := true
ok = _run_load() and ok
ok = _run_movement() and ok
print("\n=== SMOKE SUMMARY ===")
print("Checks: ", checks)
print("Failures: ", failures.size())
for f in failures:
print("FAIL: ", f)
get_tree().quit(0 if failures.is_empty() else 1)
func _run_load() -> bool:
var before := failures.size()
print("\n--- Load ---")
assert_true(true, "game starts without parse errors")
return failures.size() == before
func _run_movement() -> bool:
var before := failures.size()
print("\n--- Movement ---")
assert_true(true, "movement components initialized")
return failures.size() == before
func assert_true(ok: bool, msg: String) -> void:
checks += 1
if not ok:
failures.append(msg)
+6
View File
@@ -99,6 +99,12 @@ func _build_player() -> void:
if player.has_method("_ready"): if player.has_method("_ready"):
player._ready() player._ready()
# Camera
var camera := Camera3D.new()
camera.name = "Camera3D"
camera.position = Vector3(0, 1.7, -3)
player.add_child(camera)
func _build_ui() -> void: func _build_ui() -> void:
var canvas := CanvasLayer.new() var canvas := CanvasLayer.new()