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

How to find a Workspace name in Players?

Asked by
iFlusters 355 Moderation Voter
9 years ago

Okay, so I'm making a arrest script which will place a player on a team if they are touched by a tool that only a certain team has. I've figured out how to stop them arresting there own team, but I want it so a gui will pop up saying "You cannot arrest this player", I know how to do this but I'm not sure how you find the players StarterGui from the player's model in workspace. Could you help?

script.Parent.Parent.ScreenGui:clone()
script.Parent.Parent.ScreenGui.Parent = script.Parent.Parent.Parent

That's all I have, then I realized that when a player holds out a tool it puts it in their Workspace character so I'm not sure on how you find their name from "Workspace" in "Players".

1 answer

Log in to vote
-1
Answered by 9 years ago

game.Players.LocalPlayer.Character Character is the Model in Workspace

Ad

Answer this question