players = game.Players:GetChildren()
local randomp = players[math.random(1,#players)]
print(randomp.Name .. " is murderer")
local randoms = players[math.random(1,#players)]
print(randoms.Name .. " is sheriff")
for i,v in pairs(players) do
if v.Name ~= randomp.Name or randoms.Name then
print(v.Name .. " is innocent")
end
end
Why dosent this work? It should pick 1 murder, 1 sheriff and the rest innocent, and print in the output "Player 1 is sheriff" or something like that

4 comments
I'm only making it to learn on how to script. I'm just trying to make as much as I can to learn so I can make my own one day
Working, thanks :D
Wait, 1 more thing, how can I get a script to check if a player is innocnet, so a gui can tell the player whether their innocent, murderer, sheriff, etc?
I'd use a remote event in that script to return the role.