diff options
Diffstat (limited to 'godot/scenes/Die.gd')
-rw-r--r-- | godot/scenes/Die.gd | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/godot/scenes/Die.gd b/godot/scenes/Die.gd index 3b3a5e7..c711cee 100644 --- a/godot/scenes/Die.gd +++ b/godot/scenes/Die.gd @@ -54,6 +54,9 @@ func _input(event): if _game.is_post_game(): if event is InputEventMouseButton || event is InputEventKey: _game.next_level() + translation.x = 0 + translation.y = 0 + translation.z = 0 return if event is InputEventKey: @@ -110,10 +113,10 @@ func _physics_process(delta): if dice_is_moving == true and angular_velocity.length() < 0.1 and linear_velocity.length() < 0.1: if curr_buff != buff.ball: dice_is_moving = false + revert_current_buff() if !after_stroke: return after_stroke = false - revert_current_buff() var last_buff = curr_buff curr_buff = get_buff_from_upwards_side() if last_buff == curr_buff && curr_buff == buff.stroke: @@ -195,6 +198,7 @@ func revert_current_buff(): buff.gravity: gravity_scale = default_gravity + func apply_buff(): gravity_scale = default_gravity match curr_buff: |