Skip to content
MilkGames edited this page Aug 26, 2020 · 7 revisions

These are all the hooks included:

Loading

xAdminPostInit

Desc: Used to load addon extensions for xAdmin

Events

xAdminUsergroupUpdated

Desc: Called when a users usergroup is updated

Arguments Type
targetID string
rank string

xAdminPlayerKicked

Desc: Called when a user is kicked with the !kick command

Arguments Type
target ply
admin ply
reason string

xAdminPlayerBanned

Desc: Called when a user is banned with the !ban command

Arguments Type
target ply or string
admin ply
reason string
time int
archiveEntryId int

xAdminPlayerUnBanned

Desc: Called when a user is unbanned with the !unban command

Arguments Type
target string
admin ply

Blockers

xAdminCanRunCommand

Desc: Used to block commands being run. Return true/false to block

Arguments Type
admin ply
command string
args table
isConCommand bool

xAdminCanUnBan

Desc: Used to block an unban. Return false, "string" to block

Arguments Type
admin ply
target string