Exports
Permissions
isPlayerIdAllowed
exports.lc_adminmenu:isPlayerIdAllowed(targetId, permission)-- Command that checks if player has permission to revive
-- Example Input: isPlayerIdAllowedToRevive 2
-- Example Output:
-- Check passed! Player with ID 2 is administrator
-- This administrator has permission to revive.
RegisterCommand('isPlayerIdAllowedToRevive', function(source, args)
if source ~= 0 then return end -- Command can be only used from console
if not args[1] or not tonumber(args[1]) then return end -- Argument validation
local allowed = exports.lc_adminmenu:isPlayerIdAllowed(args[1])
if not allowed then
print('This player is not an admin.')
return
end
print(('Check passed! Player with ID %s is administrator'):format(args[1]))
-- You can also check if player has any permission from data/permissions.lua
local revive_allowed = exports.lc_adminmenu:isPlayerIdAllowed(args[1], 'revive')
if revive_allowed then
print('This administrator has permission to revive.')
else
print('This administrator DOES NOT have permission to revive.')
end
end)Ban System
banPlayer
checkIsPlayerBanned
unbanIdentifier
Dashboard Feed
addFeedMessage

Trust Score
getTrustScoreById
setTrustScoreById
addTrustScoreById
removeTrustScoreById
Last updated