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
 

Does using 1-5 select 1,2,3,4,5?

Previous Thread :: Next Thread 
NuclearBlender is not online. NuclearBlender
Joined: 26 Mar 2013
Total Posts: 1799
28 Mar 2013 06:23 PM
I mean if I did

l = math.random(1,100)

if l == 1-5 then


would that work?
Report Abuse
BunnyBoy26 is not online. BunnyBoy26
Joined: 17 Jun 2010
Total Posts: 5674
28 Mar 2013 06:25 PM
if I <= 5 then
Report Abuse
NuclearBlender is not online. NuclearBlender
Joined: 26 Mar 2013
Total Posts: 1799
28 Mar 2013 06:26 PM
That would work, I just want to know if 1-5 would work.
Report Abuse
kert109 is not online. kert109
Joined: 31 Dec 2009
Total Posts: 681
28 Mar 2013 06:28 PM
Or if you want to do something like between 20 and 100 then:

if Num >= 20 and Num <= 100 then

Basicly it checks if its 20 or over, then it checks if its 100 or below.

If you just want it to be 20 - 100 and NOT 20 nor 100 then just remove the '='

~kert109
Report Abuse
kert109 is not online. kert109
Joined: 31 Dec 2009
Total Posts: 681
28 Mar 2013 06:28 PM
Oh sorry, 1-5 will not work.
Report Abuse
dmjoe is not online. dmjoe
Joined: 01 May 2009
Total Posts: 2387
28 Mar 2013 06:28 PM
No, the script would read that as

1 -5
1 minus 5

print(1-5):
-4

~print("pew")~
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