godotengine / tps-demo

Godot Third Person Shooter with high quality assets and lighting
Other
955 stars 166 forks source link

Apply gravity to Red Robot while idle #145

Closed aidan-j-rhoden closed 1 year ago

aidan-j-rhoden commented 1 year ago

When the player first enters a red robot's detection collider, it drops to the floor and then approaches the player. This is because they are placed slightly above the ground in level.tscn, as it is somewhat hard to get just perfect.

I added a line in red_robot.gd to apply gravity while it is idling, so it doesn't just hover there.

Calinou commented 1 year ago

Tested locally, it works. Thanks!