Table of Contents

Interface DragGesture.IMotionStrategy

Namespace
Lime
Assembly
Lime.dll

Defines a motion strategy.

public interface DragGesture.IMotionStrategy

Properties

Duration

float Duration { get; }

Property Value

float

Position

Vector2 Position { get; }

Property Value

Vector2

Methods

Start(Vector2, IEnumerable<(Vector2 Distance, float Duration)>)

Start position calculation.

bool Start(Vector2 startPosition, IEnumerable<(Vector2 Distance, float Duration)> touchHistory)

Parameters

startPosition Vector2

The position motion should begin at.

touchHistory IEnumerable<(Vector2 Distance, float Duration)>

Sequence of distance and duration pairs for a couple of last frames.

Returns

bool

Update(float)

Recalculates position.

void Update(float time)

Parameters

time float

Time elapsed from the start.