From DarkRP
Jump to navigation Jump to search
Hook name canDemote(Player ply, Player target, string reason)
Whether a player can demote another player.
Returns: boolean canDemote, string message
Realm: NewerServer.png
BBCode Link: [b][url=http://wiki.darkrp.com/index.php?title=Hooks/Server/canDemote]canDemote hook[/url][/b]


  1. ply (Player)
  2. The player who wants to demote.

  3. target (Player)
  4. The player whom is to be demoted.

  5. reason (string)
  6. The reason provided for the demote.

Return values[edit]

  1. canDemote (boolean)
  2. Whether the player can change demote the target.

  3. message (string)
  4. The message to show when the player cannot demote the other player. Only useful when canDemote is false.