generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Timer Reset

Previous Thread :: Next Thread 
WafflezExtreme is not online. WafflezExtreme
Joined: 02 Mar 2013
Total Posts: 1162
26 Jan 2015 05:54 PM
Ok, so I was trying to make a script that whenever someone dies on a certain team it resets the clock. (timer)
Wouldnt it need something to do with GetGhildren
Report Abuse
bigbadbob234 is not online. bigbadbob234
Joined: 26 Mar 2009
Total Posts: 64
26 Jan 2015 06:20 PM

function resetTimer()
--reset the timer here. not sure what you're using as a timer, so I can't do this for you.
end

for i,v in ipairs(game.Players:GetPlayers()) do
if v.TeamColor == "Black" then --or White, or Industrial Neon Chartreuse or whatever
v.CharacterAdded:connect(function(char)
char:WaitForChild("Humanoid").Died:connect(resetTimer)
end)
end
end

game.Players.PlayerAdded:connect(function(player)
if player.TeamColor == "Black" then --or Grey, or Some Muavey Shade of Russet
player.CharacterAdded:connect(function(char)
char:WaitForChild("Humanoid").Died:connect(resetTimer)
end)
end
end)

--Hi! I bet you're a cool person. Have a great life!
Report Abuse
WafflezExtreme is not online. WafflezExtreme
Joined: 02 Mar 2013
Total Posts: 1162
26 Jan 2015 06:57 PM
The timer is gonna be at 2:00 and it will countdown and whenever someone dies it will go back to 2:00
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image