Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How would I go about making a model face a player?

Asked by 2 years ago

How would I make a model face a player? I made a script that moves the model to the humanoid root part and moves back a little so it's out of the players face. I now need the model to also face the player as well. Thank you for your time. - VSP

1 answer

Log in to vote
0
Answered by
mikurx 15
2 years ago

Give your model a PrimaryPart, then

local runService = game:GetService("RunService")

while true do
    model:SetPrimaryPartCFrame(CFrame.new(
        model.PrimaryPart.Position, -- position
        player.Character.HumanoidRootPart.Position -- look at
    ))

    runService.Stepped:Wait()
end

This makes the model look at the player's HumanoidRootPart

Ad

Answer this question