moveUp method

  1. @override
void moveUp({
  1. double? speed,
})
override

Move player to Up

Implementation

@override
void moveUp({double? speed}) {
  if (_perCellEnabled) {
    if (_perCellMoving) return;
    _perCellMoving = true;
    add(
      MoveEffect.by(
        Vector2(0, -cellSize.x),
        EffectController(
          duration: _pushPerCellDuration,
          curve: _pushPerCellCurve,
        ),
        onComplete: _perCeelMovecomplete,
      ),
    );
  } else {
    super.moveUp(speed: speed);
  }
}