JoystickAction class

Constructors

JoystickAction({required dynamic actionId, Future<Sprite>? sprite, Future<Sprite>? spritePressed, Future<Sprite>? spriteBackgroundDirection, bool enableDirection = false, double size = 50, double sizeFactorBackgroundDirection = 1.5, EdgeInsets margin = EdgeInsets.zero, Color color = Colors.blueGrey, JoystickActionAlign align = JoystickActionAlign.BOTTOM_RIGHT, double opacityBackground = 0.5, double opacityKnob = 0.8})

Properties

actionId → dynamic
final
align JoystickActionAlign
final
color Color
final
enableDirection bool
final
hashCode int
The hash code for this object.
no setterinherited
isPressed bool
getter/setter pair
margin EdgeInsets
final
opacityBackground double
final
opacityKnob double
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
size double
final
sizeFactorBackgroundDirection double
final
sprite Sprite?
getter/setter pair
spriteBackgroundDirection Sprite?
getter/setter pair
spritePressed Sprite?
getter/setter pair

Methods

actionDown(int pointer, Offset localPosition) → void
actionMove(int pointer, Offset localPosition) → void
actionUp(int pointer) → void
initialize(Vector2 _screenSize, JoystickController joystickController) → void
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onLoad() Future<void>
pressed() → void
render(Canvas c) → void
toString() String
A string representation of this object.
inherited
unPressed() → void
update(double dt) → void

Operators

operator ==(Object other) bool
The equality operator.
inherited