Module builtin

Module builtin 

Expand description

Built-in types like Vector2, GString and Variant.

Please read the book chapter about builtin types.

§API design

API design behind the builtin types (and some wider parts of the library) is elaborated in the extended documentation page.

Modules§

gstring
Manual symbols and default extenders for builtin type GString.
iter
Iterator types for arrays and dictionaries.
math
Math-related functions and traits like ApproxEq.
string_name
Manual symbols and default extenders for builtin type StringName.

Macros§

array
Constructs Array literals, similar to Rust’s standard vec! macro.
dictDeprecated
real
A macro to coerce float-literals into the real type.
reals
Array of reals.
swizzle
Access vector components in different order.
varray
Constructs VarArray literals, similar to Rust’s standard vec! macro.
vdict
Constructs VarDictionary literals, close to Godot’s own syntax.
vslice
Constructs a slice of Variant literals, useful for passing to vararg functions.

Structs§

Aabb
Axis-aligned bounding box in 3D space.
AnyArray
Covariant Array that can be either typed or untyped.
Array
Godot’s Array type.
Basis
A 3x3 matrix, typically used as an orthogonal basis for Transform3D.
Callable
A Callable represents a function in Godot.
Color
Color built-in type, in floating-point RGBA format.
ColorHsv
HSVA floating-number Color representation.
GString
Godot’s reference counted string type.
NodePath
A pre-parsed scene tree path.
PackedArray
Space-efficient array of T elements.
Plane
3D plane in Hessian normal form.
Projection
A 4x4 matrix used for 3D projective transformations.
Quaternion
Unit quaternion to represent 3D rotations.
Rect2
2D axis-aligned bounding box.
Rect2i
2D axis-aligned integer bounding box.
Signal
Untyped Godot signal.
StringName
A string optimized for unique names.
Transform2D
Affine 2D transform (2x3 matrix).
Transform3D
Affine 3D transform (3x4 matrix).
VarDictionary
Godot’s Dictionary type.
Variant
Godot variant type, able to store a variety of different types.
VariantOperator
Godot enum name: Variant.Operator.
VariantType
Godot enum name: Variant.Type.
Vector2
Vector used for 2D math using floating point coordinates.
Vector3
Vector used for 3D math using floating point coordinates.
Vector4
Vector used for 4D math using floating point coordinates.
Vector2i
Vector used for 2D math using integer coordinates.
Vector3i
Vector used for 3D math using integer coordinates.
Vector4i
Vector used for 4D math using integer coordinates.

Enums§

ColorChannelOrder
Defines how individual color channels are laid out in memory.
Corner
This enum is exhaustive; you should not expect future Godot versions to add new enumerators.
Encoding
Specifies string encoding.
EulerOrder
This enum is exhaustive; you should not expect future Godot versions to add new enumerators.
ProjectionEye
The eye to create a projection for, when creating a projection adjusted for head-mounted displays.
ProjectionPlane
A projection’s clipping plane.
Rid
A RID (“resource ID”) is an opaque handle that refers to a Godot Resource.
Side
This enum is exhaustive; you should not expect future Godot versions to add new enumerators.
Vector2Axis
Enumerates the axes in a Vector2.
Vector3Axis
Enumerates the axes in a Vector3.
Vector4Axis
Enumerates the axes in a Vector4.

Traits§

RealConv
Convenience conversion between real and f32/f64.
RustCallable
Represents a custom callable object defined in Rust.
XformInv
Applying inverse transforms.

Type Aliases§

DictionaryDeprecated
PackedByteArray
General-purpose byte buffer.
PackedColorArray
PackedFloat32Array
PackedFloat64Array
PackedInt32Array
PackedInt64Array
PackedStringArray
PackedVector2Array
PackedVector3Array
PackedVector4Arraysince_api=4.3
VarArray
Untyped Godot Array.
VariantArrayDeprecated
real
Floating point type used for many structs and functions in Godot.