Glued Follow
Mimics the positional movement of the target.
This is the simplest of the follow modes and is useful for cases where you just want a camera to follow a target without any additional complications.
Properties
Follow Target
Type: Node2D
Default: null
Determines which Node
should be followed. The Camera
will follow the position of the Follow Target
based on the Follow Mode
type and its parameters.
Note: During runtime, properties should be modified and read via their setters & getters respectively.
Setter
void
set_follow_target_node(Node2D
target_node)
Example
pcam.set_follow_target_node(player_node)
Damping
Type: bool
Default: false
Applies a damping effect on the Camera
's movement. Leading to heavier / slower camera movement as the targeted node moves around.
This is useful to avoid sharp and rapid camera movement.
Note: During runtime, properties should be modified and read via their setters & getters respectively.
Damping Value
Type: float
Default: 10
Defines the damping amount.
Lower value = slower / heavier camera movement.
Higher value = faster / sharper camera movement.
Note: During runtime, properties should be modified and read via their setters & getters respectively.
Setter
void
set_follow_damping_value(float
damping_value)
Example
pcam.set_follow_damping_value(5)