General > Developers Corner

attempt to index global 'ULib' (a nil value) help please

<< < (2/3) > >>

atomic-cruncher:
ERROR:

[ULIB] Loading SHARED module: donationkeys.lua

[ERROR] addons/ulib/lua/ulib/modules/donationkeys.lua:15: attempt to index global 'ply' (a nil value)
1. unknown - addons/ulib/lua/ulib/modules/donationkeys.lua:15
2. include - [C]:-1
3. unknown - addons/ulib/lua/ulib/init.lua:68
4. include - [C]:-1
5. unknown - addons/ulib/lua/autorun/ulib_init.lua:3

[ULIB] Loading SHARED module: ulx_init.lua

using this: ULib.ucl.addUser( ply:SteamID(), nil, nil, "donator" )

EDIT: also when trying this execute command: RunConsoleCommand( "ulx", "adduserid", "" .. ply:SteamID() .. "", "vip")
getting same thnig

JamminR:
Errors are pretty obvious.
During startup, you have the Ulib command running outside of a function...or running before a player is defined in ply.
During run of the command, your not passing the command the right info.
Attach your file for review.

An Error Has Occurred!

array_keys(): Argument #1 ($array) must be of type array, null given

[0] Board index

Go to full version