fix lvel display
This commit is contained in:
parent
7c6aced9ca
commit
156bb0d941
1 changed files with 1 additions and 1 deletions
2
piece.gd
2
piece.gd
|
|
@ -28,6 +28,7 @@ func tween_to_target(tween := get_tree().create_tween(), anim_time: float = get_
|
|||
last_move_tween.custom_step(413)
|
||||
last_move_tween.kill()
|
||||
tween.tween_property(self, "position", target_pos(), anim_time)
|
||||
tween.tween_callback(func(): lvel_displayed = lvel)
|
||||
last_move_tween = tween
|
||||
|
||||
func lpos_of_pos(pos: Vector3) -> Vector2i:
|
||||
|
|
@ -68,7 +69,6 @@ func do_step(board: Board, tween: Tween):
|
|||
var on_ice := !!board.type_at(lpos, Piece.Type.FloorIce)
|
||||
if not on_ice:
|
||||
lvel -= move
|
||||
lvel_displayed = lvel
|
||||
tween_to_target(tween)
|
||||
|
||||
func undo_step() -> Callable:
|
||||
|
|
|
|||
Loading…
Reference in a new issue