So I’m having trouble making a part face the same direction as the players head. The part gets placed into the players head but doesn’t face the head’s direction. I’ve tried looking for info on the dev hub, but nothing… What should I do?
local debounce = false
local ReplicatedStorage = game.ReplicatedStorage
function FireBreath(direction)
local FirePart = ReplicatedStorage.FirePart:Clone()
FirePart.Parent = game.Workspace
local TargetPosition = Head.FaceFrontAttachment.WorldPosition
FirePart.Attachment.WorldCFrame = CFrame.new(TargetPosition)
local Weld = Instance.new("WeldConstraint")
Weld.Parent = Head
Weld.Part1 = FirePart
Weld.Part0 = Head
Weld.Enabled = true
end
script.Parent.Touched:Connect(function(touch)
local character = touch.Parent
if character:FindFirstChild("Humanoid") and debounce == false then
Head = character:FindFirstChild("Head")
FireBreath()
debounce = true
wait(2)
debounce = false
end
end)