I have no idea how would i do it HELP ME! thanks!
✓ ANSWER ACCEPTED
How can i make it so if the player touches a GUI button it's HumanoidRootPart gets referenced?
1 answer
✓ Accepted answer
What I think you're trying to do is get a player's HumanoidRootPart when they click a GUI button. To do this, we can put a LocalScript (this is important) in the button with the following code:
--Get the player
local player = game:GetService("Players").LocalPlayer
--When the button is pressed
script.Parent.Activated:Connect(function()
local humanoidRootPart = player.Character.HumanoidRootPart
end)
Hope this helps.
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
Can it be instead of activated, MouseButton1Click? is it the same?
Yes it can be. MouseButton1Click, however, is slowly less commonly being used in favor of Activated, so I suggest you use Activated now before MouseButton1Click gets deprecated.