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
 

Script not Looping

Previous Thread :: Next Thread 
SuperSkateboy is not online. SuperSkateboy
Joined: 20 Oct 2010
Total Posts: 602
07 Sep 2012 11:44 AM
I am a beginner scripter, and I'm scripting my own base, and I have come with this problem making a message loop. It works, however when it gets to the last message, it does not loop. This is what I mean:



if true then
script.Parent.Message1.Visible = true
wait(3)
script.Parent.Message1.Visible = false
wait(1)
script.Parent.Message2.Visible = true
wait(4)
script.Parent.Message2.Visible = false
wait(1)
script.Parent.Message3.Visible = true
wait(4)
script.Parent.Message3.Visible = false
wait(1)
end


Report Abuse
AgentFirefox is not online. AgentFirefox
Top 100 Poster
Joined: 20 Jun 2008
Total Posts: 22404
07 Sep 2012 11:53 AM
while true do
script.Parent.Message1.Visible = true
wait(3)
script.Parent.Message1.Visible = false
wait(1)
script.Parent.Message2.Visible = true
wait(4)
script.Parent.Message2.Visible = false
wait(1)
script.Parent.Message3.Visible = true
wait(4)
script.Parent.Message3.Visible = false
wait(1)
end


A while loop is what you want. It makes sense, too. While something is true, run this code over and over again.
Report Abuse
SuperSkateboy is not online. SuperSkateboy
Joined: 20 Oct 2010
Total Posts: 602
07 Sep 2012 11:57 AM
Thanks, I diddn't notice that.
-SSB
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