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: I require help with a simple script.

Previous Thread :: Next Thread 
RoboticI is not online. RoboticI
Joined: 23 Apr 2011
Total Posts: 917
31 Jul 2014 09:47 PM
I watched the roblox tutorial on scripting basics and saw the "for" loops. I tried it out myself. I copied everything he had exactly to get a feel for it. For some reason in the output I got 1 1 1 instead of 1 2 3. Here is my script
for i = 1, 3 do
print(1)
end
I don't understand why it is wrong. If someone would please tell me what is wrong I would appreciate it. Thank you.
Report Abuse
ROBLOXTHEMOVIEs is not online. ROBLOXTHEMOVIEs
Joined: 11 Jun 2012
Total Posts: 5895
31 Jul 2014 09:49 PM
for i = 1, 3 do
print(i)
end
Report Abuse
smiley599 is not online. smiley599
Joined: 23 Jan 2010
Total Posts: 21869
31 Jul 2014 09:49 PM
You're just printing (1) three times.

for i = 1, 3 do
print(i) --print i which changes from 1 to 2 to 3
end
Report Abuse
RoboticI is not online. RoboticI
Joined: 23 Apr 2011
Total Posts: 917
31 Jul 2014 09:50 PM
Thank you for the help. I see what happened, the i was hard to distinguish from the 1.
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