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 » Scripting Helpers
Home Search
 

Re: Syncing Game Script

Previous Thread :: Next Thread 
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 08:44 PM
How do I sync like Time Guis with all the players in the Server? Will I have to make another coroutine inside a coroutine? But will I have to use wrap for both? Cause I heard using wrap is less buggy. Here's my script just for a reference.

inform = coroutine.wrap(function()
for _, v in pairs(game.Players:GetPlayers()) do
if v.PlayerGui:findFirstChild("Game")~=nil then
local gui = v.PlayerGui.Game
local label = gui.Message.Label
gui.Message.Visible = true
for i = 30,1, -1 do wait(1)
label.Text = "The game will start in "..i.." seconds!"
end
gui.Message.Visible = false
end
end
end)
inform()
Report Abuse
CeaselessSoul is not online. CeaselessSoul
Joined: 03 Jul 2012
Total Posts: 7506
01 Dec 2012 08:46 PM
Wait, what are you trying to do?

Want a script? Send me a PM and we'll work out a deal!
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 08:47 PM
Syncing the Time Text with everyone in the server. I tried it in Test Server with two players, and all it did was play for a single player, and once the routine was over, it played for the other player. So is it necessary for me to use another coroutine? Or is there another method?
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 08:54 PM
Mega Bump.
Report Abuse
crouton04 is not online. crouton04
Joined: 07 Jul 2010
Total Posts: 4459
01 Dec 2012 08:54 PM
Idk what a coroutine is, but I did this without one. :p

players = game.Players:GetChildren()
for i, v in pairs(players) do
gui = players[i].PlayerGui.Announcement
for l = 1, 30, -1 do
gui.text.Text = "Round Starting in "..l.." seconds!"
wait(30)
gui.text.Text = "Round Started!"
wait(4)
gui.text.Text = ""
end
end
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 08:55 PM
Are you cereal?
*FaicPalm*
Thanks anyway.
Report Abuse
CeaselessSoul is not online. CeaselessSoul
Joined: 03 Jul 2012
Total Posts: 7506
01 Dec 2012 08:57 PM
I stepped on a corn flake... Now I'm a cereal killer. XD.

Want a script? Send me a PM and we'll work out a deal!
Report Abuse
crouton04 is not online. crouton04
Joined: 07 Jul 2010
Total Posts: 4459
01 Dec 2012 08:59 PM
Me too, thats why I don't go to farms anymore..
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 09:00 PM
Hah! That joke. xD. But anyways, how do I do this madness! ROBLOX is going to end! asohdaohsdihasiohfdawdlkasfasgf
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 09:20 PM
Bump
Report Abuse
crouton04 is not online. crouton04
Joined: 07 Jul 2010
Total Posts: 4459
01 Dec 2012 09:28 PM
mein no work? Mine needs the guis already there...
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 09:35 PM
Does it sync along with all the players in the game? At the same time?
Report Abuse
crouton04 is not online. crouton04
Joined: 07 Jul 2010
Total Posts: 4459
01 Dec 2012 09:36 PM
Yesh except...

i = 30, 1, -1 didn't do that..
Report Abuse
Raphael7 is not online. Raphael7
Joined: 03 Dec 2008
Total Posts: 2479
01 Dec 2012 09:38 PM
Alright, I'll take care of it.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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