Expand description

Curated re-exports of common items.

Modules

User-data attributes from export::user_data module.

Macros

Prints and returns the value of a given expression for quick and dirty debugging, using the engine’s logging system (visible in the editor).
Print an error using the engine’s logging system (visible in the editor).
Declare all the API endpoints necessary to initialize a NativeScript library.
Print a message using the engine’s logging system (visible in the editor).
Print a warning using the engine’s logging system (visible in the editor).

Structs

Axis-aligned bounding box.
A 3x3 matrix, typically used as an orthogonal basis for Transform.
core class Button inherits BaseButton (manually managed).
core class CanvasItem inherits Node (manually managed).
core class CanvasLayer inherits Node (manually managed).
Allows registration of exported properties, methods and signals.
RGBA color with 32-bit floating point components.
core class ColorRect inherits Control (manually managed).
core class Control inherits CanvasItem (manually managed).
A reference-counted Dictionary of Variant key-value pairs.
Metadata about the exported property.
Godot’s reference-counted string type.
core class Image inherits Resource (reference-counted).
A handle that can register new classes to the engine during initialization.
core singleton class Input inherits Object (manually managed).
core class InputEvent inherits Resource (reference-counted).
core class InputEventKey inherits InputEventWithModifiers (reference-counted).
A persistent reference to a GodotObject with a rust NativeClass attached.
core class KinematicBody inherits PhysicsBody (manually managed).
core class KinematicBody2D inherits PhysicsBody2D (manually managed).
core class Label inherits Control (manually managed).
Builder type used to register a method on a NativeClass.
core class Node inherits Object (manually managed).
core class Node2D inherits CanvasItem (manually managed).
A reference-counted relative or absolute path in a scene tree, for use with Node.get_node() and similar functions. It can reference a node, a resource within a node, or a property of a node or resource.
Represents an explicit null reference in method arguments. This works around type inference issues with Option. You may create Nulls with Null::null or GodotObject::null.
The base class of all classes in the Godot hierarchy.
core class PackedScene inherits Resource (reference-counted).
3D plane in Hessian form: a*b + b*y + c*z + d = 0
A reference-counted CoW typed vector using Godot’s pool allocator, generic over possible element types.
Placeholder type for exported properties with no backing field.
Quaternion, used to represent 3D rotations.
2D axis-aligned bounding box.
A polymorphic smart pointer for Godot objects whose behavior changes depending on the memory management method of the underlying type and the thread access status.
Base class of all reference-counted types. Inherits Object.
core singleton class ResourceLoader inherits Object (manually managed).
A RID (“resource ID”) is an opaque handle that refers to a Godot Resource.
core class SceneTree inherits MainLoop (manually managed).
core class Shader inherits Resource (reference-counted).
Marker that indicates that a value currently might be shared in the same or over multiple threads.
Class to construct a signal. Make sure to call Self::done() in the end.
Parameter in a signal declaration.
core class Spatial inherits Node (manually managed).
core class Sprite inherits Node2D (manually managed).
Interned string.
A reference to a GodotObject with a rust NativeClass attached that is assumed safe during a certain lifetime.
A temporary safe pointer to Godot objects that tracks thread access status. TRef can be coerced into bare references with Deref.
core class Texture inherits Resource (reference-counted).
Marker that indicates that a value can currently only be shared in the same thread.
core class Timer inherits Node (manually managed).
Affine 3D transform (3x4 matrix).
Affine 2D transform (2x3 matrix).
core class Tween inherits Node (manually managed).
Marker that indicates that a value currently only has a single unique reference.
A Variant can represent all Godot values (core types or Object class instances).
A reference-counted Variant vector. Godot’s generic array data type. Negative indices can be used to count from the right.
2D vector class.
3D vector class.
core class Viewport inherits Node (manually managed).

Enums

Error type returned by FromVariant::from_variant.
Error codes used in various Godot APIs.
Marker that indicates that a type is manually managed.
Marker that indicates that a type is reference-counted.
Rust enum associating each primitive variant type to its value.
Godot variant operator kind.

Traits

Trait for safe conversion from Godot object references into API method arguments. This is a sealed trait with no public interface.
Types that can be converted from a Variant. Conversions are performed in Rust, and can be implemented for custom types.
Trait for Godot API objects. This trait is sealed, and implemented for generated wrapper types.
GodotObjects that have a zero argument constructor.
Safe low-level trait for stateful, variadic methods that can be called on a native script type.
Trait used for describing and initializing a Godot script class.
Trait used to provide information of Godot-exposed methods of a script class.
A trait for incrementing the reference count to a Godot object.
Types that can only be safely converted to a Variant as owned values. Such types cannot implement ToVariant in general, but can still be passed to API methods as arguments, or used as return values. Notably, this includes Unique arrays, dictionaries, and references to Godot objects and instances.
Manually managed Godot classes implementing queue_free. This trait has no public interface. See Ref::queue_free.
Marker trait for API types that are subclasses of another type. This trait is implemented by the bindings generator, and has no public interface. Users should not attempt to implement this trait.
Types that can be converted to a Variant.
Trait for types whose ToVariant implementations preserve equivalence.

Functions

Convenience method to obtain a reference to an “auto-load” node, that is a child of the root node.
Loads a resource from the filesystem located at path.

Type Definitions

A reference-counted vector of u8 that uses Godot’s pool allocator.
A reference-counted vector of Color that uses Godot’s pool allocator.
A reference-counted vector of f32 that uses Godot’s pool allocator.
A reference-counted vector of i32 that uses Godot’s pool allocator.
A reference-counted vector of GodotString that uses Godot’s pool allocator.
A reference-counted vector of Vector2 that uses Godot’s pool allocator.
A reference-counted vector of Vector3 that uses Godot’s pool allocator.

Attribute Macros

Collects method signatures of all functions in a NativeClass that have the #[method] attribute and registers them with Godot.
Makes a function profiled in Godot’s built-in profiler. This macro automatically creates a tag using the name of the current module and the function by default.

Derive Macros

Enable struct types to be parsed as argument lists.
Makes it possible to use a type as a NativeScript.