String value? Because I can't seem to add a space when searching Right leg Right arm, etc.
✓ ANSWER ACCEPTED
What's the prefix for Right arm or left arm?
1 answer
✓ Accepted answer
So, from the comments I assume that this is fired when something is hit.
if hit.Parent:FindFirstChild("Humanoid") then
local arms = { hit.Parent["Left Arm"], hit.Parent["Right Arm"] } -- Put the arms in a table
for i,v in pairs(arms) do -- Loop through the arms
if hit.Name == v.Name then -- Check which arm is hit
script.Parent.CFrame = CFrame.new(arms[i].Position) * CFrame.new() -- Set the CFrame position to the current arm
end
end
end
Edit: OffTopic: What's up with all these random down voters?
This discussion is preserved as it was. New answers, comments, and votes are closed.

3 comments
How would I put ["Right Arm"] in this Welding script? rarm = hit.Parent.???? script.Parent.CFrame = rarm.CFrame * CFrame.new(0,0,0)
Create some locals defining the arms. Local rarm = hit.Parent["Right Arm"]
THANKS!