I wanted to add a homing projectile to my 3d Godot 4.5.1 game and thought what I could do is give it a z positive velocity and make it look at the player. That would cause the issue of it being impossible to dodge so I want to lerp the look at so it more slowly targets the player. How’d I go about this?
You could try using Basis.looking_at towards the direction of your player, then you can slerp the basis. You can also slerp quaternions.
var direction := player.global_position - projectile.global_position
var new_basis := Basis.looking_at(direction)
projectile.basis = projectile.basis.slerp(new_basis, 0.05)