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: Error

Previous Thread :: Next Thread 
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:29 AM
I am getting a error on line 7...Dunno what it is?


Time = 60
players = game.Players:GetChildren()

if Time>=0 then
timemsg = Instance.new("Message")
timemsg.Parent = player.PlayerGui
timemsg.Text = ("Time until you all Die = "...Time)
print "I am Working"
end
Report Abuse
Piedude777 is not online. Piedude777
Joined: 01 Oct 2008
Total Posts: 10017
05 Aug 2011 08:30 AM
Time = 60
players = game.Players:GetChildren()

if Time>=0 then
timemsg = Instance.new("Message")
timemsg.Parent = player.PlayerGui
timemsg.Text = "Time until you all Die = " .. tostring(Time)
print "I am Working"
end
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:35 AM
i'm getting new error now??

')' expected(to close '(' at line 7 near 'print'
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:39 AM
bumpedy Bump
Report Abuse
BloxBuilder900 is not online. BloxBuilder900
Joined: 31 Mar 2009
Total Posts: 2231
05 Aug 2011 08:40 AM
Why did you double post ?

:S

Time = 60
players = game.Players:GetPlayers()
if Time >= 0 then
for _,v in pairs(players) do
Instance.new("Message", v.PlayerGui)
end
print "I am Working"
end
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:45 AM
BloxBuilder

Your Script works but can you either simplify it or tell me what every thing means?

Bit complicated for me.
Report Abuse
BloxBuilder900 is not online. BloxBuilder900
Joined: 31 Mar 2009
Total Posts: 2231
05 Aug 2011 08:45 AM
it just goes through every player (current player = v) and puts a message in their playergui
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:48 AM
ok thanks
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:50 AM
How would you set the message to countdown from 60 saying

"Time until You All Die = 'countdownnum' "
Report Abuse
myrco1001 is not online. myrco1001
Joined: 17 Sep 2010
Total Posts: 2574
05 Aug 2011 08:51 AM
for i = 60, 0, -1 do
print(i)
wait(1)
end

Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:51 AM
thx
Report Abuse
BloxBuilder900 is not online. BloxBuilder900
Joined: 31 Mar 2009
Total Posts: 2231
05 Aug 2011 08:53 AM
Time = 60
players = game.Players:GetPlayers()
if Time >= 0 then
for _,v in pairs(players) do
Instance.new("Message", v.PlayerGui)
v.PlayerGui.Message.Text = coroutine.resume(coroutine.create(function()
for i = Time, 0, -1 do
v.Text = tostring(i).." seconds before you all die !"
wait(1)
end
end))
end
print "I am Working"
end
Report Abuse
myrco1001 is not online. myrco1001
Joined: 17 Sep 2010
Total Posts: 2574
05 Aug 2011 08:54 AM
'tostring(i)'

i is a number....
Report Abuse
BloxBuilder900 is not online. BloxBuilder900
Joined: 31 Mar 2009
Total Posts: 2231
05 Aug 2011 08:55 AM
converting it into a strng, if I didn't it would have caused an error about bad concatenation thingy :P
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 08:59 AM
Just Thought you would like to know but the game I am trying to make a script for is a game where you have to get through a obstacle course, but every 60 seconds everyone dies.So when someone gets to en they click button to stop timer.and go to lobby for next map!!

Interesting EH!
Report Abuse
BloxBuilder900 is not online. BloxBuilder900
Joined: 31 Mar 2009
Total Posts: 2231
05 Aug 2011 09:00 AM
uhm... nice :)
Report Abuse
myrco1001 is not online. myrco1001
Joined: 17 Sep 2010
Total Posts: 2574
05 Aug 2011 09:00 AM
for i = 60, 0, -1 do
print(i.." nothing's wrong")
wait(1)
end
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 09:03 AM
grr..i fail at scripting
Report Abuse
BloxBuilder900 is not online. BloxBuilder900
Joined: 31 Mar 2009
Total Posts: 2231
05 Aug 2011 09:03 AM
Oh ok... Well converting to string it's not a bad thing tough, amirite?
Report Abuse
stuart6854 is not online. stuart6854
Joined: 20 Oct 2008
Total Posts: 913
05 Aug 2011 09:05 AM
i think im gonna give up too hard...
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