Choose your operating system:
Windows
macOS
Linux
Module |
|
Header |
/Engine/Source/Runtime/Core/Public/Modules/ModuleInterface.h |
Include |
#include "Modules/ModuleInterface.h" |
class IModuleInterface
Interface class that all module implementations should derive from. This is used to initialize a module after it's been loaded, and also to clean it up before the module is unloaded.
Name | Description | |
---|---|---|
|
~IModuleInterface() |
Even though this is an interface class we need a virtual destructor here because modules are deleted via a pointer to this interface |
Name | Description | ||
---|---|---|---|
|
IsGameModule() |
Returns true if this module hosts gameplay code |
|
|
PostLoadCallback() |
Called after the module has been reloaded |
|
|
PreUnloadCallback() |
Called before the module has been unloaded |
|
|
ShutdownModule() |
Called before the module is unloaded, right before the module object is destroyed. |
|
|
StartupModule() |
Called right after the module DLL has been loaded and the module object has been created Load dependent modules here, and they will be guaranteed to be available during ShutdownModule. |
|
|
SupportsAutomaticShutdown() |
Override this to set whether your module would like cleanup on application shutdown |
|
|
SupportsDynamicReloading() |
Override this to set whether your module is allowed to be unloaded on the fly |