Node2D
Inherits: CanvasItem < Node < ObjectDescription
A 2D game object with a transform (position, rotation, and scale). All 2D nodes, including physics objects and sprites, inherit from Node2D.Properties
Vector2
default:"Vector2(0, 0)"
Position, relative to the node’s parent.
float
default:"0.0"
Rotation in radians, relative to the node’s parent.
Vector2
default:"Vector2(1, 1)"
The node’s scale. Unscaled value: (1, 1).
Vector2
Global position. See also position.
Methods
rotate
translate
look_at
get_angle_to
Example Usage
- GDScript
- C#