Fix "respawn point set" message triggering even if that sarco is already the respawn point.
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
1 parent
775338c4d2
commit
f50b7da9eb
1 file changed
+5
-5
+5
-5
@@ -3,12 +3,12 @@ extends Interactable
|
|||||||
func _on_interacted() -> void:
|
func _on_interacted() -> void:
|
||||||
#%OldComputer.open()
|
#%OldComputer.open()
|
||||||
|
|
||||||
if %Player2D.spawn_point != global_position:
|
|
||||||
%Player2D.spawn_point = global_position
|
|
||||||
%OldComputer.printline(">> Respawn point set.")
|
|
||||||
|
|
||||||
#Accomodate some collision antics.
|
#Accomodate some collision antics.
|
||||||
%Player2D.spawn_point = global_position + Vector2(0,-10)
|
var new_spawn_point = global_position + Vector2(0,-10)
|
||||||
|
|
||||||
|
if %Player2D.spawn_point != new_spawn_point:
|
||||||
|
%Player2D.spawn_point = new_spawn_point
|
||||||
|
%OldComputer.printline(">> Respawn point set to %s" % new_spawn_point)
|
||||||
|
|
||||||
var wanted_disk = %OldComputer.get_next_disk_num()
|
var wanted_disk = %OldComputer.get_next_disk_num()
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user