Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do you find a players character?

tool = script.Parent
handle = tool.Handle
Player = script.Parent.Parent
rightshoulder = Player.Character.Torso
tool.Equipped:connect(function()
	
end)
tool.Activated:connect(function()
	rightshoulder.C0 = rightshoulder.C0 *CFrame.Angles(0, 0, 0.16)
end)

Tried to make it when you clicked, you would like slay with your sword. However, I'm having trouble finding my character torso!

Keep in mind this is in a tool! Of course, in local scripts im able to easily find them but i dont get it when you use a tool

any soloutions would be appreciated!

2 answers

The tool (when equipped) is placed inside the character. So just do:

local tool = script.Parent
local Char = tool.Parent
local Torso = Char:WaitForChild("Torso")

How to find the character:

local char = script.Parent.Parent

How to find the player:

local plr = game.Players:FindFirstChild(script.Parent.Parent.Name)

This discussion is preserved as it was. New answers, comments, and votes are closed.