Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local gui = script.Parent
- local prisonerFrame = gui:FindFirstChild("Prisoner")
- local guardFrame = gui:FindFirstChild("Guard")
- local changeRemote = game.ReplicatedStorage:FindFirstChild("ChangeTeam")
- function changeTeam(team)
- changeRemote:FireServer(team)
- end
- prisonerFrame.ChangeTeam.Activated:Connect(function()
- changeTeam("Prisoner")
- end)
- guardFrame.ChangeTeam.Activated:Connect(function()
- changeTeam("Guard")
- end)
- changeRemote.OnClientEvent:Connect(function(guiEnabled)
- gui.Enabled = guiEnabled
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement