#[Solved] Fallowing Dummy Head
1 messages · Page 1 of 1 (latest)
local dummy = script.Parent
local head = dummy:FindFirstChild("Head")
local torso = dummy:FindFirstChild("Torso")
local neck = torso:FindFirstChild("Neck") -- The Motor6D connecting Torso and Head
-- Anchor all BaseParts except Head (optional for stability)
for _, part in pairs(dummy:GetChildren()) do
if part:IsA("BasePart") and part ~= head then
part.Anchored = true
end
end
local function trackPlayer()
while true do
local player = game.Players:GetPlayers()[1]
if player then
local character = player.Character
if character then
local humanoidRootPart = character:FindFirstChild("HumanoidRootPart")
if humanoidRootPart and neck then
local lookAtPos = humanoidRootPart.Position
local headPos = head.Position
local direction = (lookAtPos - headPos).Unit
-- Calculate only the rotation needed
local newCFrame = CFrame.lookAt(headPos, headPos + Vector3.new(direction.X, 0, direction.Z))
-- Update Neck.C0 to rotate the head
neck.C0 = torso.CFrame:ToObjectSpace(newCFrame)
end
end
end
task.wait(0.1)
end
end
task.spawn(trackPlayer)
** You are now Level 2! **
Do you want it to just look at one person or like each person who sees it it’s looking at them
If that then it’s better if you do a local script and modify it
Yeah just one person
So to change the script to local
Inside the dummy
Local script version
local dummy = workspace:WaitForChild("Dummy") -- Replace with your dummy's name
local head = dummy:WaitForChild("Head")
local torso = dummy:WaitForChild("Torso")
local neck = torso:FindFirstChild("Neck")
local player = game.Players.LocalPlayer
local function trackLocalPlayer()
while true do
local character = player.Character or player.CharacterAdded:Wait()
local humanoidRootPart = character:FindFirstChild("HumanoidRootPart")
if humanoidRootPart and neck then
local lookAtPos = humanoidRootPart.Position
local headPos = head.Position
local direction = (lookAtPos - headPos).Unit
local newCFrame = CFrame.lookAt(headPos, headPos + Vector3.new(direction.X, 0, direction.Z))
neck.C0 = torso.CFrame:ToObjectSpace(newCFrame)
end
task.wait(0.1)
end
end
task.spawn(trackLocalPlayer)
Yeah
For local dummy you could do script.parent instead
I think
I’m on my phone rn
This first script is even more worse i don't even know what happened
Ok hold on
Ok don't worry
Watcha making it for?
Horror game important detail
i did it
Oo
Will you show it?
** You are now Level 11! **
np can i get sum commision lol
** You are now Level 3! **
What? 😭
[Solved] Fallowing Dummy Head
Lemme get $2 💀👀