General > Developers Corner
Ulx has permission.
blackfire88:
Hello,
How do I check if a player has a specific permission?
For example if the user can use ulx slay, then a certain toolgun lets them autokill people.
Just as an example.
Stickly Man!:
<player>:query( "accesstag" )
So for example, you would have something like this:
--- Code: ---local ply = LocalPlayer()
if ply:query( "ulx slay" ) then
--Kill all the peoples!
end
--- End code ---
blackfire88:
wow thanks stickly man!
blackfire88:
Could I modify the darkrp code to use that? OR is it a ulx-only based thing.
JamminR:
Technically, it's ULib. You could design any ULib.ucl table query you wanted, as long as you stored permissions/flags in a Ulib table.
That particular example just shows the particular use of how we do the ulx storage for most commands.
See http://ulyssesmod.net/docs/files/lua/ulib/shared/sh_ucl-lua.html#ucl (lots of other Ulib documentation there too of course)
Navigation
[0] Message Index
[#] Next page
Go to full version