// Copyright (c) 2012-2023 Wojciech Figat. All rights reserved. #pragma once #include "PluginDescription.h" #include "Engine/Scripting/ScriptingObject.h" /// /// Base class for game engine editor plugins. /// API_CLASS(Abstract) class FLAXENGINE_API Plugin : public ScriptingObject { DECLARE_SCRIPTING_TYPE(Plugin); private: friend class PluginManagerService; bool _initialized = false; protected: /// /// Plugin description. Should be a constant part of the plugin created in constructor and valid before calling . /// API_FIELD() PluginDescription _description; public: /// /// Gets the description. /// API_PROPERTY() const PluginDescription& GetDescription() const { return _description; } /// /// Initialization method called when this plugin is loaded to the memory and can be used. /// API_FUNCTION() virtual void Initialize() { } /// /// Cleanup method called when this plugin is being unloaded or reloaded or engine is closing. /// API_FUNCTION() virtual void Deinitialize() { } };