Skip to content

AcceleratedMoveEffect ​

Inherits: MoveDirectionalEffect < CompositeEffect < Effect < DatabaseResource < Resource

AcceleratedMoveEffect: Acceleration and curve-based movement Combines acceleration curves with custom curves for advanced movement patterns Perfect for charge-up abilities, momentum building, wind-up attacks, and cinematic movement

Properties ​

floatmax_speed15.0
floatmovement_duration1.0
AccelerationTypeacceleration_typeAccelerationType.QUADRATIC
Curvemovement_curve

Methods ​

voidapply_movement( effect_instance: EffectInstance, entity: Entity, direction: Vector3 )
voidhandle_movement_collision( effect_instance: EffectInstance, collision: KinematicCollision3D )
floatget_acceleration_factor( progress: float )
Stringget_effect_description()
Stringget_editor_description()

Enumerations ​

enum AccelerationType ​

The options of acceleration type: linear, quadratic, cubic, smooth, custom.

  • LINEAR = 0
  • QUADRATIC = 1
  • CUBIC = 2
  • SMOOTH = 3
  • CUSTOM = 4

Property descriptions ​

Acceleration Settings

float max_speed = 15.0 ​

Maximum speed reached during movement

float movement_duration = 1.0 ​

Time for the complete movement in seconds

AccelerationType acceleration_type = AccelerationType.QUADRATIC ​

Type of acceleration curve (Custom uses movement_curve)

Curve movement_curve ​

Custom curve defining velocity over time (only used when acceleration_type is Custom)

Method descriptions ​

void apply_movement( effect_instance: EffectInstance, entity: Entity, direction: Vector3 ) ​

Moves the entity one step in the direction of the movement.

void handle_movement_collision( effect_instance: EffectInstance, collision: KinematicCollision3D ) ​

Called when the moving entity hits something: it bounces or stops, by the settings of the effect.

float get_acceleration_factor( progress: float ) ​

Calculate acceleration factor based on progress and curve type

String get_effect_description() ​

The text of the effect for tooltips, with its values filled in.

String get_editor_description() ​

A short text for the effect editor that says what the effect does.