diff --git a/project.godot b/project.godot index 7a87c1d..6382ac2 100644 --- a/project.godot +++ b/project.godot @@ -63,6 +63,8 @@ config/accessibility/enable_hit_lag=true WorldGroup="Singleton group for the active world instance, if any." GameGroup="Singleton group for the active game instance, if any." +DemoCamera="" +PlayerSpawn="" [gui] diff --git a/src/game/game.tscn b/src/game/game.tscn index f34e32d..00c28d2 100644 --- a/src/game/game.tscn +++ b/src/game/game.tscn @@ -162,6 +162,7 @@ libraries = { [node name="Rumbler" type="Control" parent="RootControl"] unique_name_in_owner = true +process_mode = 1 layout_mode = 1 anchors_preset = 15 anchor_right = 1.0 diff --git a/src/player/shot_setup/shot_setup.tscn b/src/player/shot_setup/shot_setup.tscn index 3c92e90..f9e5d2a 100644 --- a/src/player/shot_setup/shot_setup.tscn +++ b/src/player/shot_setup/shot_setup.tscn @@ -234,6 +234,9 @@ unique_name_in_owner = true [node name="GfolfGirl" parent="PlayerPivot" instance=ExtResource("3_e4aur")] transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, -0.555968, 0, 0.0999683) +[node name="DemoCamera" type="Camera3D" parent="PlayerPivot" groups=["DemoCamera"]] +transform = Transform3D(-0.124487, 0.584637, 0.801687, 0, 0.807972, -0.589221, -0.992221, -0.0733503, -0.100582, 0.395614, 0.0284514, -0.0394773) + [node name="Direction" type="Node3D" parent="."] unique_name_in_owner = true diff --git a/src/ui/game_viewport_container.gd b/src/ui/game_viewport_container.gd index d1272bf..ee1d482 100644 --- a/src/ui/game_viewport_container.gd +++ b/src/ui/game_viewport_container.gd @@ -65,7 +65,7 @@ func _reset_position() -> void: func _process(_delta: float) -> void: if _hit_lag_frames >= 0: if _hit_lag_frames == 0: - content.process_mode = Node.PROCESS_MODE_INHERIT + get_tree().paused = false else: - content.process_mode = Node.PROCESS_MODE_DISABLED + get_tree().paused = true _hit_lag_frames -= 1 diff --git a/src/ui/menus/pause_menu/pause_menu.gd b/src/ui/menus/pause_menu/pause_menu.gd index 5a6715b..5c3ce75 100644 --- a/src/ui/menus/pause_menu/pause_menu.gd +++ b/src/ui/menus/pause_menu/pause_menu.gd @@ -6,15 +6,18 @@ extends Control func _ready() -> void: + print_debug("Pause menu _ready()") Input.set_mouse_mode(Input.MOUSE_MODE_VISIBLE) func _exit_tree() -> void: + print_debug("Pause menu _exit_tree()") Input.set_mouse_mode(Input.MOUSE_MODE_CAPTURED) func _unhandled_key_input(event: InputEvent) -> void: if event.is_action_pressed("pause"): + get_viewport().set_input_as_handled() resume() @@ -27,6 +30,7 @@ func _hide() -> void: func resume() -> void: + print_debug("Pause menu resume()") queue_free() diff --git a/src/ui/world_ui.gd b/src/ui/world_ui.gd index 825f737..aa48f13 100644 --- a/src/ui/world_ui.gd +++ b/src/ui/world_ui.gd @@ -13,6 +13,7 @@ var _prev_camera: Camera3D func _unhandled_key_input(event: InputEvent) -> void: if event.is_action_pressed("pause"): + get_viewport().set_input_as_handled() pause()