From 9155752f861ae43e3534cdfa833d8c644cb0e5d3 Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Sat, 18 May 2024 15:49:24 +0200 Subject: save/load --- Objects/BuilderObject.gd | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Objects') diff --git a/Objects/BuilderObject.gd b/Objects/BuilderObject.gd index 91465bc..fde2660 100644 --- a/Objects/BuilderObject.gd +++ b/Objects/BuilderObject.gd @@ -30,7 +30,7 @@ func _process(_delta): func _on_area_2d_input_event(_viewport, event: InputEvent, _shape_idx): if event.is_action_pressed("drag_start"): drag_start() - if event.is_action_released("drag_start"): + if is_dragging and event.is_action_released("drag_start"): drag_end() @@ -79,6 +79,6 @@ func _on_area_2d_area_entered(_area): func _on_area_2d_area_exited(_area): - #if $Area2D.get_overlapping_areas().size() == 0: - is_colliding = false - modulate = Color("fff") + if $Area2D.get_overlapping_areas().size() == 0: + is_colliding = false + modulate = Color("fff") -- cgit v1.2.3