Suggestion: void Humanoid:LookAt(Vector3 location)

Humanoids are great, I love using them for my mobs!
They have health, walking ability, being able to trip etc. But they do lack a function to make them turn towards a certain direction.

Problem
Many times I got a mob and I want it to face an enemy.
I could do WalkToPoint, so the humanoid will walk a slight distance in order to face the enemy.
This works but theres a chance the humanoid walks off edge, if this humanoid is the boss then it’s an obvious problem.

Yes it can be solved a million ways, but being a frequent issue I’d like to suggest a better solution.

Solution
My suggestion is a new function that will turn the humanoid without moving it.

What you think? :wink:

21 Likes

Rotate the Torso (R6) or LowerTorso (R15) CFrame.
obj.CFrame = CFrame.new(obj.PosVector3,lookAtVector3)

You could also lerp this to make it look smooth.

Def. Could use tween service too. Or just bodygyro.
But point was that a new function would be an easy solution to a frequent problem :slight_smile:

1 Like

It needs to be integrated with the physics pipeline or else the character could rotate inside of a wall.

3 Likes