private void Awake() { bool debug = Debug.isDebugBuild; #if DEBUG debug = true; #endif if (!debug) { this.enabled = false; return; } // populate recording path populatedRecordingPath_ = recordingPath_; populatedRecordingPath_ = SavePathUtil.PopulateDesktopVariable(populatedRecordingPath_); #if DT_DEBUG_MENU var inspector = DTDebugMenu.GenericInspectorRegistry.Get("DTMediaCapture"); inspector.BeginDynamic(); inspector.RegisterHeader("Recorder"); string keybindingComment = useKeyBindings_ ? string.Format("({0})", toggleRecordingKey_) : ""; inspector.RegisterToggleButton((b) => b ? "Stop Recording " + keybindingComment : "Start Recording " + keybindingComment, () => recording_, (b) => { if (b) { StartRecording(); } else { StopRecording(); } }); dynamicGroup_ = inspector.EndDynamic(); #endif }
private void Awake() { bool debug = Debug.isDebugBuild; #if DEBUG debug = true; #endif if (!debug) { this.enabled = false; return; } #if DT_DEBUG_MENU var inspector = DTDebugMenu.GenericInspectorRegistry.Get("DTMediaCapture"); inspector.BeginDynamic(); inspector.RegisterHeader("Screenshotter"); inspector.RegisterButton("Toggle Paused TimeScale " + (useKeyBindings_ ? string.Format("({0})", togglePauseKey_) : ""), TogglePausedTimeScale); inspector.RegisterButton("Capture Screenshot " + (useKeyBindings_ ? string.Format("({0})", screenshotKey_) : ""), CaptureScreenshot); dynamicGroup_ = inspector.EndDynamic(); #endif }