Ver Fonte

Apply gravity to Red Robot while idle (#145)

Aidan Rhoden há 2 anos atrás
pai
commit
fab68bcd7e
1 ficheiros alterados com 1 adições e 0 exclusões
  1. 1 0
      enemies/red_robot/red_robot.gd

+ 1 - 0
enemies/red_robot/red_robot.gd

@@ -143,6 +143,7 @@ func _physics_process(delta):
 
 	if not player:
 		animation_tree["parameters/state/current"] = 0 # Go idle.
+		velocity = move_and_slide(gravity * delta, Vector3.UP)
 		return
 
 	if state == State.APPROACH: