Resource
Inherits: RefCounted < ObjectDescription
Base class for serializable objects. Resources are reference-counted and freed when no longer in use. They can be nested within other resources and saved on disk.Inheritance
Resource < RefCounted < Object
Properties
If true, the resource is duplicated for each instance of all scenes using it.
An optional name for this resource. Displayed in the Inspector dock.
The unique path to this resource. If saved to disk, the value will be its filepath.
Methods
duplicate
If true, performs a deep copy where nested arrays and resources are also duplicated
emit_changed
take_over_path
Signals
changed()
Emitted when the resource changes, usually when one of its properties is modified.Example Usage
- GDScript
- C#