|
| 18 Jan 2015 03:16 PM |
Umm... I can't script it right to make the hiders lose when it says the hiders win. I experimented a lot since yesterday, hours of experimenting, and I still can't script it.
Here is the script:
local hiders = contestants ~= seeker and contestants ~= assistant local gameresult = "HidersWin" if seekeractive then if #hiders < 1 then event:FireAllClients("Result", "HidersWin") else gameresult = "Seeker and Assistant Win" event:FireAllClients("Result", "Seeker and Assistant Win") end else event:FireAllClients("Result", "HidersWin") end for _, v in pairs(game.Workspace:GetChildren()) do if v then if v.Name == v.className == "Hat" then v:remove() end end end for _, player in pairs(contestants) do if player then if gameresult == "Seeker and Assistant Win" and player == seeker and assistant then awardpoints(player, 25) elseif gameresult ~= "Seeker and Assistant Win" and player ~= seeker and assistant then awardpoints(player, 10) end end end
Can anyone help me fix my mistake? |
|
|
| Report Abuse |
|
|
| 18 Jan 2015 03:48 PM |
Maybe this will help you understand better?
local hiders = contestants ~= seeker and contestants ~= assistant local gameresult = "HidersWin" if seekeractive then if #hiders < 1 then event:FireAllClients("Result", "HidersWin") else gameresult = "Seeker and Assistant Win" event:FireAllClients("Result", "Seeker and Assistant Win") end else event:FireAllClients("Result", "HidersWin") end |
|
|
| Report Abuse |
|