bugfix: adjust 'limits' on upper/lower X value to be dynamic, rather than static
This commit is contained in:
@@ -67,7 +67,7 @@ func _process(delta: float) -> void:
|
||||
if bounce:
|
||||
velocity = -(velocity)/2
|
||||
print("velocity negated, bouncing")
|
||||
global_position.x = 999
|
||||
global_position.x = max_x - 1
|
||||
time_since_first_location = -1
|
||||
draggable = true
|
||||
return
|
||||
@@ -76,7 +76,7 @@ func _process(delta: float) -> void:
|
||||
if bounce:
|
||||
velocity = -(velocity)/2
|
||||
print("velocity negated, bouncing")
|
||||
global_position.x = 1
|
||||
global_position.x = min_x + 1
|
||||
time_since_first_location = -1
|
||||
draggable = true
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user