General > Off-Topic
Prophunt Custom Made Commands Error
James Aitchison:
My ULib/ULX versions (run "ulx version" in console):
ULib v2.61d (10/27/16)
ULX v3.70d (02/28/16)
Game mode(s) I am having this problem on: PropHunt
Lua errors shown in console, if any:
--- Code: ---[ERROR] addons/ulx-master/lua/ulx/modules/sh/owencommands.lua:138: attempt to index local 'target_plys' (a nil value)
1. afk - addons/ulx-master/lua/ulx/modules/sh/owencommands.lua:138
2. unknown - addons/ulx-master/lua/ulx/modules/sh/owencommands.lua:147
3. include - [C]:-1
4. unknown - addons/ulx-master/lua/ulx/init.lua:34
5. include - [C]:-1
6. unknown - addons/ulx-master/lua/ulib/modules/ulx_init.lua:2
7. include - [C]:-1
8. unknown - addons/ulib-master/lua/ulib/init.lua:74
9. include - [C]:-1
10. unknown - addons/ulib-master/lua/autorun/ulib_init.lua:3
--- End code ---
The file it's refering too:
http://pastebin.com/vzK8JiFS
Please help as i have been spending hours trying to get this to work. I have googled the error as well as used a previous code released on facepunch, but that was back in january 2014 so the code doesnt want to work with the gmod updates since then.
Thank you in advance to anyone who can help me solve this,
James
iViscosity:
First of all, your ulx and ulib are slightly outdated, you can get the latest here.
As far as I know, the "Team()" function can only be called on one person (I could be wrong). Also, SetTeam() can only be called on the client, so you'd need a check for that.
So, really, I don't think this can be a multi target thing, just try it with one, it would probably be easier anyways.
James Aitchison:
--- Quote from: iViscosity on October 29, 2016, 11:39:17 AM ---First of all, your ulx and ulib are slightly outdated, you can get the latest here.
As far as I know, the "Team()" function can only be called on one person (I could be wrong). Also, SetTeam() can only be called on the client, so you'd need a check for that.
So, really, I don't think this can be a multi target thing, just try it with one, it would probably be easier anyways.
--- End quote ---
Ah I see, that you for the update.
My LUA skills are next to none, so when you say the "Team()" function, would that be in replacement of "target_ply:Team()"? And the same goes for the "SetTeam()" function?
An Error Has Occurred!
array_keys(): Argument #1 ($array) must be of type array, null given
[0] Board index
Go to full version