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

Make a part attached to the player point towards another part?

Asked by 5 years ago
local LocalPlayer = game:GetService("Players").LocalPlayer
local Character = LocalPlayer.Character or LocalPlayer.CharacterAdded:wait()

local arrow = game.ReplicatedStorage.arrow:Clone()
    arrow.Parent = Character.Head
    arrow.Name = "Arrow"
    arrow.CanCollide = false

local Weld = Instance.new("Weld", arrow)
    Weld.Part0 = Character.Head
    Weld.Part1 = arrow
    Weld.C1 = CFrame.new(0, -4, 0)

while wait() do
    local arrow = arrow
    local door = game.Workspace.House1.Door

    arrow.CFrame = CFrame.new(arrow.Position, door.Position)
end

This is what I currently have however this changes the entire players CFrame.

0
Why is a part parented to another part User#19524 175 — 5y
0
I figured maybe I should parent it to the players head if that's where I needed it to be, but I swear is that fixes the problem I will feel stupid VeryDarkDev 47 — 5y
0
Did it fix it though DinozCreates 1070 — 5y
0
nope VeryDarkDev 47 — 5y

Answer this question