Hello,
i make a command that opens a GUI. If you run the Command it copy the GUI into the PlayerGui Folder. It works in Studio, but not online! I use a normal Script and NOT a LocalScript. Here is my Code:
function onChatted(message, player)
if message == "/registerplayer" and tableContains(admins, player.Name) then
print("GUI opening")
game.ServerStorage.registerPlayer:Clone().Parent = game.Players.LocalPlayer.PlayerGui
end
end
Can it be that LocalPlayer only works with a LocalScript? And if LocalPlayer only works in a LocalScript, what Code do i need to use in a normal Script?
