From 4bde1cbd5c87f1779a1026a83a7c83399247f1ce Mon Sep 17 00:00:00 2001 From: Petr Ohlidal Date: Sat, 12 Mar 2022 19:11:41 +0100 Subject: [PATCH] :books: Doxygen: added module 'Scripting'. --- doc/doxygen/Modules.h | 3 +++ source/main/scripting/GameScript.h | 9 ++++----- source/main/scripting/LocalStorage.h | 4 ++++ source/main/scripting/OgreScriptBuilder.h | 4 ++++ source/main/scripting/ScriptEngine.h | 5 +++++ 5 files changed, 20 insertions(+), 5 deletions(-) diff --git a/doc/doxygen/Modules.h b/doc/doxygen/Modules.h index c16d4cf9a5..98e598aae5 100644 --- a/doc/doxygen/Modules.h +++ b/doc/doxygen/Modules.h @@ -34,4 +34,7 @@ /// @defgroup ConsoleCmd Console commmands /// Built-in console commands. +/// @defgroup Scripting Scripting +/// Game scripting subsystem using AngelScript. + diff --git a/source/main/scripting/GameScript.h b/source/main/scripting/GameScript.h index 0fb9a4bb90..141bae344c 100644 --- a/source/main/scripting/GameScript.h +++ b/source/main/scripting/GameScript.h @@ -32,11 +32,8 @@ namespace RoR { -struct curlMemoryStruct -{ - char* memory; - size_t size; -}; +/// @addtogroup Scripting +/// @{ /** * @brief Proxy class that can be called by script functions @@ -379,4 +376,6 @@ class GameScript : public ZeroedMemoryAllocator bool HaveMainCamera(const char* func_name); //!< Helper; Check if main camera exists, log warning if not. }; +/// @} //addtogroup Scripting + } // namespace RoR diff --git a/source/main/scripting/LocalStorage.h b/source/main/scripting/LocalStorage.h index 4b8e7eb61e..cabc639abe 100644 --- a/source/main/scripting/LocalStorage.h +++ b/source/main/scripting/LocalStorage.h @@ -25,6 +25,9 @@ #include #include "ImprovedConfigFile.h" +/// @addtogroup Scripting +/// @{ + void registerLocalStorage(AngelScript::asIScriptEngine* engine); void scriptLocalStorageFactory_Generic(AngelScript::asIScriptGeneric* gen); void scriptLocalStorageFactory2_Generic(AngelScript::asIScriptGeneric* gen); @@ -108,3 +111,4 @@ class LocalStorage : public ImprovedConfigFile bool cgflag; }; +/// @} //addtogroup Scripting diff --git a/source/main/scripting/OgreScriptBuilder.h b/source/main/scripting/OgreScriptBuilder.h index bede61247f..06dc8a4660 100644 --- a/source/main/scripting/OgreScriptBuilder.h +++ b/source/main/scripting/OgreScriptBuilder.h @@ -31,6 +31,9 @@ #include +/// @addtogroup Scripting +/// @{ + // our own class that wraps the CScriptBuilder and just overwrites the file loading parts // to use the ogre resource system class OgreScriptBuilder : public AngelScript::CScriptBuilder, public ZeroedMemoryAllocator @@ -42,3 +45,4 @@ class OgreScriptBuilder : public AngelScript::CScriptBuilder, public ZeroedMemor int LoadScriptSection(const char* filename); }; +/// @} //addtogroup Scripting diff --git a/source/main/scripting/ScriptEngine.h b/source/main/scripting/ScriptEngine.h index 06133db579..8210795304 100644 --- a/source/main/scripting/ScriptEngine.h +++ b/source/main/scripting/ScriptEngine.h @@ -42,6 +42,9 @@ namespace RoR { +/// @addtogroup Scripting +/// @{ + enum class ScriptCategory { INVALID, @@ -213,6 +216,8 @@ void RegisterImGuiBindings(AngelScript::asIScriptEngine* engine); /// Registers RoR::InputEngine, defined in InputEngineAngelscript.cpp void registerInputEngine(AngelScript::asIScriptEngine* engine); +/// @} //addtogroup Scripting + } // namespace RoR #else // USE_ANGELSCRIPT