Inheritance #

Table of contents

GDExtensionManager #

core, not_builtin_classes, singleton

Provides access to GDExtension functionality.

The GDExtensionManager loads, initializes, and keeps track of all available GDExtension libraries in the project.

Note: Do not worry about GDExtension unless you know what you are doing.

Members #

Methods #

func get_extension(path: String) -> GDExtension#

Returns the GDExtension at the given file path, or null if it has not been loaded or does not exist.

const func get_loaded_extensions() -> PackedStringArray#

Returns the file paths of all currently loaded extensions.

const func is_extension_loaded(path: String) -> bool#

Returns true if the extension at the given file path has already been loaded successfully. See also get_loaded_extensions.

func load_extension(path: String) -> intGDExtensionManager.LoadStatus#

Loads an extension by absolute file path. The path needs to point to a valid GDExtension. Returns LOAD_STATUS_OK if successful.

func reload_extension(path: String) -> intGDExtensionManager.LoadStatus#

Reloads the extension at the given file path. The path needs to point to a valid GDExtension, otherwise this method may return either LOAD_STATUS_NOT_LOADED or LOAD_STATUS_FAILED.

Note: You can only reload extensions in the editor. In release builds, this method always fails and returns LOAD_STATUS_FAILED.

func unload_extension(path: String) -> intGDExtensionManager.LoadStatus#

Unloads an extension by file path. The path needs to point to an already loaded GDExtension, otherwise this method returns LOAD_STATUS_NOT_LOADED.

Annotations #

Constants #

const LOAD_STATUS_OK = 0 enum LoadStatus#

The extension has loaded successfully.

const LOAD_STATUS_FAILED = 1 enum LoadStatus#

The extension has failed to load, possibly because it does not exist or has missing dependencies.

const LOAD_STATUS_ALREADY_LOADED = 2 enum LoadStatus#

The extension has already been loaded.

const LOAD_STATUS_NOT_LOADED = 3 enum LoadStatus#

The extension has not been loaded.

const LOAD_STATUS_NEEDS_RESTART = 4 enum LoadStatus#

The extension requires the application to restart to fully load.

Constructors #

Enums #

LoadStatus#

enum LoadStatus { LOAD_STATUS_OK = 0, LOAD_STATUS_FAILED = 1, LOAD_STATUS_ALREADY_LOADED = 2, LOAD_STATUS_NOT_LOADED = 3, LOAD_STATUS_NEEDS_RESTART = 4, }

Operators #

Signals #

signal extension_loaded(extension: GDExtension)#

Emitted after the editor has finished loading a new extension.

Note: This signal is only emitted in editor builds.

signal extension_unloading(extension: GDExtension)#

Emitted before the editor starts unloading an extension.

Note: This signal is only emitted in editor builds.

signal extensions_reloaded()#

Emitted after the editor has finished reloading one or more extensions.

Theme Items #

Tutorials #