So, I have this script (module)
01 | return { |
02 |
03 | [ 'ClassTypes' ] = { |
04 | [ 'Economy' ] = true ; |
05 | [ 'ECShirt' ] = false ; -- leave false for free |
06 |
07 | [ 'Business' ] = true ; |
08 | [ 'BCShirt' ] = 1087809366 ; -- replace with your Business' class shirt ID |
09 |
10 | [ 'First' ] = true ; |
11 | [ 'FCShirt' ] = 1087809366 ; -- replace with your first class shirt ID |
12 | } ; |
13 | [ 'Group' ] = { -- connect checko to Discord (beta) |
14 | [ 'GroupID' ] = 3013520 ; -- Id OF YOUR GROUP |
15 | [ 'MinGroupRank' ] = 34 ; -- Minimun Rank To Check In People |
But when I run :
print(require(game.Workspace.Checko.Configuration).ClassTypes.BCShirt)
nil
It returns nil
1 | print (require( --[[ ModuleScript location--]] ).ClassTypes.BCShirt) |
That works just fine to me, you might be calling it wrong or something
Try putting the module inside the script like this: click for image then inside the script :
1 | local m = require(script.ModuleScript) |
2 | print (m.ClassTypes.BCShirt) |
this printed
1087809366
You can also put the module script in any place else and just call it in the local m!
Hope this helped!
I think the problem is with your module script. I am not an expert to Lua, but might be able to help.
You're separating each meta-tables with ;
and I think you should be using ,
instead:
01 | return { |
02 |
03 | [ 'ClassTypes' ] = { |
04 | [ 'Economy' ] = true , |
05 | [ 'ECShirt' ] = false , -- leave false for free |
06 |
07 | [ 'Business' ] = true , |
08 | [ 'BCShirt' ] = 1087809366 , -- replace with your Business' class shirt ID |
09 |
10 | [ 'First' ] = true , |
11 | [ 'FCShirt' ] = 1087809366 , -- replace with your first class shirt ID |
12 | } , |
13 | [ 'Group' ] = { -- connect checko to Discord (beta) |
14 | [ 'GroupID' ] = 3013520 , -- Id OF YOUR GROUP |
15 | [ 'MinGroupRank' ] = 34 , -- Minimun Rank To Check In People |