diff --git a/Source/Engine/Audio/Audio.h b/Source/Engine/Audio/Audio.h index 5a82a6da8..05ec4c9d2 100644 --- a/Source/Engine/Audio/Audio.h +++ b/Source/Engine/Audio/Audio.h @@ -11,7 +11,7 @@ /// /// The audio service used for music and sound effects playback. /// -API_CLASS(Static) class FLAXENGINE_API Audio +API_CLASS(Static, Attributes="DebugCommand") class FLAXENGINE_API Audio { DECLARE_SCRIPTING_TYPE_NO_SPAWN(Audio); friend class AudioStreamingHandler; diff --git a/Source/Engine/Audio/AudioDevice.h b/Source/Engine/Audio/AudioDevice.h index 1a816f627..1d05e41cf 100644 --- a/Source/Engine/Audio/AudioDevice.h +++ b/Source/Engine/Audio/AudioDevice.h @@ -9,7 +9,7 @@ /// API_CLASS(NoSpawn) class AudioDevice : public ScriptingObject { -DECLARE_SCRIPTING_TYPE_NO_SPAWN(AudioDevice); + DECLARE_SCRIPTING_TYPE_NO_SPAWN(AudioDevice); explicit AudioDevice() : ScriptingObject(SpawnParams(Guid::New(), TypeInitializer)) @@ -31,7 +31,6 @@ DECLARE_SCRIPTING_TYPE_NO_SPAWN(AudioDevice); } public: - /// /// The device name. /// @@ -41,4 +40,9 @@ public: /// The internal device name used by the audio backend. /// StringAnsi InternalName; + + String ToString() const override + { + return Name; + } }; diff --git a/Source/Engine/Engine/Globals.h b/Source/Engine/Engine/Globals.h index 5e58d5039..f204aff29 100644 --- a/Source/Engine/Engine/Globals.h +++ b/Source/Engine/Engine/Globals.h @@ -8,7 +8,7 @@ /// /// Global engine variables container. /// -API_CLASS(Static) class FLAXENGINE_API Globals +API_CLASS(Static, Attributes="DebugCommand") class FLAXENGINE_API Globals { DECLARE_SCRIPTING_TYPE_NO_SPAWN(Globals); diff --git a/Source/Engine/Engine/Screen.h b/Source/Engine/Engine/Screen.h index 7322fa368..be8fef0fb 100644 --- a/Source/Engine/Engine/Screen.h +++ b/Source/Engine/Engine/Screen.h @@ -10,7 +10,7 @@ /// /// Helper class to access display information. /// -API_CLASS(Static) class FLAXENGINE_API Screen +API_CLASS(Static, Attributes="DebugCommand") class FLAXENGINE_API Screen { DECLARE_SCRIPTING_TYPE_NO_SPAWN(Screen); diff --git a/Source/Engine/Engine/Time.h b/Source/Engine/Engine/Time.h index ff81fb93e..e61b0f913 100644 --- a/Source/Engine/Engine/Time.h +++ b/Source/Engine/Engine/Time.h @@ -10,7 +10,7 @@ /// /// Game ticking and timing system. /// -API_CLASS(Static) class FLAXENGINE_API Time +API_CLASS(Static, Attributes="DebugCommand") class FLAXENGINE_API Time { DECLARE_SCRIPTING_TYPE_NO_SPAWN(Time); friend class Engine; diff --git a/Source/Engine/Physics/Physics.h b/Source/Engine/Physics/Physics.h index efd11b184..a2faab2f0 100644 --- a/Source/Engine/Physics/Physics.h +++ b/Source/Engine/Physics/Physics.h @@ -41,7 +41,7 @@ public: /// /// Gets the current gravity force. /// - API_PROPERTY() static Vector3 GetGravity(); + API_PROPERTY(Attributes="DebugCommand") static Vector3 GetGravity(); /// /// Sets the current gravity force. diff --git a/Source/Engine/Profiler/ProfilerGPU.h b/Source/Engine/Profiler/ProfilerGPU.h index c316abb15..7652a03ad 100644 --- a/Source/Engine/Profiler/ProfilerGPU.h +++ b/Source/Engine/Profiler/ProfilerGPU.h @@ -132,12 +132,12 @@ public: /// /// True if GPU profiling is enabled, otherwise false to disable events collecting and GPU timer queries usage. Can be changed during rendering. /// - API_FIELD() static bool Enabled; + API_FIELD(Attributes="DebugCommand") static bool Enabled; /// /// True if GPU events are enabled (see GPUContext::EventBegin), otherwise false. Cannot be changed during rendering. /// - API_FIELD() static bool EventsEnabled; + API_FIELD(Attributes="DebugCommand") static bool EventsEnabled; /// /// The current frame buffer to collect events. diff --git a/Source/Engine/Profiler/ProfilingTools.h b/Source/Engine/Profiler/ProfilingTools.h index 7969cca55..43242baf2 100644 --- a/Source/Engine/Profiler/ProfilingTools.h +++ b/Source/Engine/Profiler/ProfilingTools.h @@ -127,7 +127,7 @@ public: /// /// Controls the engine profiler (CPU, GPU, etc.) usage. /// - API_PROPERTY() static bool GetEnabled(); + API_PROPERTY(Attributes="DebugCommand") static bool GetEnabled(); /// /// Controls the engine profiler (CPU, GPU, etc.) usage. diff --git a/Source/Engine/Streaming/Streaming.h b/Source/Engine/Streaming/Streaming.h index d492d74e9..7a83f7e8e 100644 --- a/Source/Engine/Streaming/Streaming.h +++ b/Source/Engine/Streaming/Streaming.h @@ -33,7 +33,7 @@ DECLARE_SCRIPTING_TYPE_NO_SPAWN(Streaming); /// /// Gets streaming statistics. /// - API_PROPERTY() static StreamingStats GetStats(); + API_PROPERTY(Attributes="DebugCommand") static StreamingStats GetStats(); /// /// Requests the streaming update for all the loaded resources. Use it to refresh content streaming after changing configuration. diff --git a/Source/Engine/Utilities/Screenshot.h b/Source/Engine/Utilities/Screenshot.h index 82882f707..976865062 100644 --- a/Source/Engine/Utilities/Screenshot.h +++ b/Source/Engine/Utilities/Screenshot.h @@ -38,5 +38,5 @@ API_CLASS(Static) class FLAXENGINE_API Screenshot /// Remember that downloading data from the GPU may take a while so screenshot may be taken one or more frames later due to latency. /// /// The custom file location. Use null or empty to use default one. - API_FUNCTION() static void Capture(const StringView& path = StringView::Empty); + API_FUNCTION(Attributes="DebugCommand") static void Capture(const StringView& path = StringView::Empty); };