Trying to make a character that can shoot bombs

A base-type variable like Vector3 is copied. so when you form the equation global_position.direction_to(mouse_position), it runs once, and copies that value to the variable. Like writing down a number, direction will never change.

By putting this equation inside _physics_process it will update every frame.


How are you spawning the bombs? May it be that they aren’t “teleporting” but are always spawned at 0,0?


Make sure to paste scripts instead of screen shots

1 Like