fix: Temporarily disable prop trace and scale trace for debugging purposes

This commit is contained in:
2026-10-10 12:17:01 -04:00
parent 373f40cf75
commit 235c6aa6a6
4 changed files with 340 additions and 651 deletions
File diff suppressed because it is too large Load Diff
@@ -33,7 +33,8 @@ const THROW_SPIN_SPEED: float = 2.4
const THROW_TRAJECTORY_SEGMENTS: int = 24 const THROW_TRAJECTORY_SEGMENTS: int = 24
const THROW_HEAD_CLEARANCE: float = 36.0 const THROW_HEAD_CLEARANCE: float = 36.0
const THROW_REACH_MARGIN: float = 8.0 const THROW_REACH_MARGIN: float = 8.0
const PROP_TRACE_ENABLED: bool = true ## Set true temporarily when diagnosing prop interaction flow.
const PROP_TRACE_ENABLED: bool = false
signal action_completed signal action_completed
signal prop_event(event_type: String, prop: PropBlock, reason: String) signal prop_event(event_type: String, prop: PropBlock, reason: String)
+4 -1
View File
@@ -117,7 +117,8 @@ const RECENT_SCENE_LIMIT: int = STAGE_DOCUMENT_CONTROLLER_SCRIPT.RECENT_LIMIT
const DEFAULT_SCENE_NAME: String = "Untitled" const DEFAULT_SCENE_NAME: String = "Untitled"
const DEFAULT_CAMERA_POSITION: Vector2 = Vector2(0.0, -400.0) const DEFAULT_CAMERA_POSITION: Vector2 = Vector2(0.0, -400.0)
const DEFAULT_CAMERA_ZOOM: float = 0.5 const DEFAULT_CAMERA_ZOOM: float = 0.5
const PROP_SCALE_TRACE_ENABLED: bool = true ## Set true temporarily when diagnosing prop interaction flow in the stage.
const PROP_TRACE_ENABLED: bool = false
## Director action-popup item ids (Phase 3a). ## Director action-popup item ids (Phase 3a).
const ACT_WALK := 0 const ACT_WALK := 0
@@ -1229,6 +1230,7 @@ func _physics_process(delta: float) -> void:
if current_mode == StageMode.PLAY or _run_state != RunState.STOPPED: if current_mode == StageMode.PLAY or _run_state != RunState.STOPPED:
_restore_frames_left = 0 _restore_frames_left = 0
else: else:
if PROP_TRACE_ENABLED:
print("[PropTrace] stage deferred_authored_restore remaining=%d mode=%s run_state=%s" % [_restore_frames_left, StageMode.keys()[int(current_mode)], RunState.keys()[int(_run_state)]]) print("[PropTrace] stage deferred_authored_restore remaining=%d mode=%s run_state=%s" % [_restore_frames_left, StageMode.keys()[int(current_mode)], RunState.keys()[int(_run_state)]])
_restore_frames_left -= 1 _restore_frames_left -= 1
_restore_authored_state() _restore_authored_state()
@@ -1698,6 +1700,7 @@ func _resume_run() -> void:
func _reset_run() -> void: func _reset_run() -> void:
if PROP_TRACE_ENABLED:
print("[PropTrace] stage reset_run mode=%s run_state=%s" % [StageMode.keys()[int(current_mode)], RunState.keys()[int(_run_state)]]) print("[PropTrace] stage reset_run mode=%s run_state=%s" % [StageMode.keys()[int(current_mode)], RunState.keys()[int(_run_state)]])
_run_session.begin_reset() _run_session.begin_reset()
_run_session.reset_world(_world_children_selectable(), StageMode.keys()[int(current_mode)], _camera.zoom) _run_session.reset_world(_world_children_selectable(), StageMode.keys()[int(current_mode)], _camera.zoom)
+2 -1
View File
@@ -8,7 +8,8 @@ const PROP_STAGE_ROLES := preload("res://scripts/props/prop_stage_roles.gd")
const STATE_STOPPED: int = 0 const STATE_STOPPED: int = 0
const STATE_RUNNING: int = 1 const STATE_RUNNING: int = 1
const STATE_PAUSED: int = 2 const STATE_PAUSED: int = 2
const PROP_SCALE_TRACE_ENABLED: bool = true ## Set true temporarily when diagnosing authored/play prop scale transfer.
const PROP_SCALE_TRACE_ENABLED: bool = false
var run_state: int = STATE_STOPPED var run_state: int = STATE_STOPPED
var elapsed_seconds: float = 0.0 var elapsed_seconds: float = 0.0