ResourcePreloader

Resource Preloader Node.

This node is used to preload sub-resources inside a scene, so when the scene is loaded, all the resources are ready to use and can be retrieved from the preloader. GDScript has a simplified @GDScript.preload built-in method which can be used in most situations, leaving the use of ResourcePreloader for more advanced scenarios.

Members

Aliases

BaseClasses
alias BaseClasses = AliasSeq!(typeof(_GODOT_base), typeof(_GODOT_base).BaseClasses)
Undocumented in source.

Functions

_getResources
Array _getResources()
_setResources
void _setResources(Array arg0)
addResource
void addResource(String name, Resource resource)

Adds a resource to the preloader with the given name. If a resource with the given name already exists, the new resource will be renamed to "name N" where N is an incrementing number starting from 2.

getResource
Ref!Resource getResource(String name)

Returns the resource associated to name.

getResourceList
PoolStringArray getResourceList()

Returns the list of resources inside the preloader.

hasResource
bool hasResource(String name)

Returns true if the preloader contains a resource associated to name.

opAssign
typeof(null) opAssign(typeof(null) n)
opEquals
bool opEquals(ResourcePreloader other)
opEquals
bool opEquals(typeof(null) n)
removeResource
void removeResource(String name)

Removes the resource associated to name from the preloader.

renameResource
void renameResource(String name, String newname)

Renames a resource inside the preloader from name to newname.

toHash
size_t toHash()

Mixins

__anonymous
mixin baseCasts
Undocumented in source.

Properties

resources
Array resources [@property getter]
Array resources [@property setter]

Static functions

_new
ResourcePreloader _new()

Construct a new instance of ResourcePreloader. Note: use memnew!ResourcePreloader instead.

Static variables

_classBindingInitialized
bool _classBindingInitialized;
Undocumented in source.

Structs

GDNativeClassBinding
struct GDNativeClassBinding
Undocumented in source.

Unions

__anonymous
union __anonymous
Undocumented in source.

Variables

_GODOT_internal_name
enum string _GODOT_internal_name;
Undocumented in source.

Mixed In Members

From mixin baseCasts

as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(ToRef) as()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(ToRef)
Undocumented in source.
opCast
void* opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
godot_object opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
bool opCast()
Undocumented in source. Be warned that the author may not have intended to support it.

Meta