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 » Scripters
Home Search
 

Can explain how tables/variables work?

Previous Thread :: Next Thread 
Dark_Legacy is not online. Dark_Legacy
Joined: 15 Jun 2013
Total Posts: 6333
03 Mar 2016 06:57 PM
I'm trying to make a MaxExp system and I dont want the MaxExp to increase by the same number each time like 7*Level

This is just a example (not really what im using)

I tried doing this, but it only works when it hits 1,4, and 7. I really just need help with the tables tbh because i dont really understand them that much. A is the level and C is the MaxExp.


local Beginner = 1,2,3
local Advancing = 4,3,5,6
local Elite = 7,8,9,10

if A == Beginner then
C = A*7
elseif A == Advancing then
C = A*12
elseif A == Elite then
C = A*16
end


How would I make this work? (Reminder: Only works with 1,4,7)




Report Abuse
Dark_Legacy is not online. Dark_Legacy
Joined: 15 Jun 2013
Total Posts: 6333
03 Mar 2016 06:58 PM
I messed up on the title sorry, what I meant was

Can someone explain how table/variables work?



Report Abuse
Dark_Legacy is not online. Dark_Legacy
Joined: 15 Jun 2013
Total Posts: 6333
03 Mar 2016 07:09 PM
Nvm I need to rewrite my question



Report Abuse
killerbot29003 is not online. killerbot29003
Joined: 04 Oct 2014
Total Posts: 3054
03 Mar 2016 07:33 PM
Tables: You can store multiple values in here, for example:
tab = {1,"hello!",game.Workspace}


I won't explain in depth, but you can look at peaspod's tutorial here:
https://www.youtube.com/watch?v=nRS255_y8rM


This siggy is copyrighted ©



Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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