From b2d679c0353ff2e9de31a524ca2bfe8bd1d72281 Mon Sep 17 00:00:00 2001
From: richard
(Docs incomplete.)
+ +Zombie:Reloaded use SourceMod to authenticate players. There are two ways to do this; flag based +or group based. With flag authentication a certain admin flag is required to be set, and with group +authentication the player must be member of a certain group to do certain types of operations.
+ +The reason to use group authentication could be to let admins have full access in SourceMod so +they get access to configure all plugins, but still limit access to commands in Zombie:Reloaded. +When using flag authentication the permissions will be global across all plugins, including +Zombie:Reloaded.
+ +Admins must have the appropriate +SourceMod admin flags to +do certain types of operations. Below is a list of all flags used in Zombie:Reloaded and what type +of operation they grant:
+ ++ ++
+ + +Flag: +Operation type: ++ + +generic +Access to generic operations like infecting, teleporting, and spawning players. ++ +config +Access to operations that change settings in Zombie:Reloaded. +
If group authentication is used, admins must be member of one of these +SourceMod groups to do the +following operations:
+ ++ ++
+ + +Group: +Operation type: ++ + +zr_admins +Full access to all commands in Zombie:Reloaded. ++ + +zr_moderators +Access to generic operations like infecting, teleporting, and spawning players. ++ +zr_configurators +Access to operations that change settings in Zombie:Reloaded. +
+ ++
+ + +Console variable: +Default: ++ +zr_permissions_use_groups +0 ++ ++ +Use group authentication instead of flags to access admin features. Generic admin + flag is still required on some features.
+Options:
+
+ 0 or 1
(Incomplete) Feel free to contribute to this section. Make a new thread with suggestions in the diff --git a/src/zr/admintools.inc b/src/zr/admintools.inc index e767679..725f7c4 100644 --- a/src/zr/admintools.inc +++ b/src/zr/admintools.inc @@ -55,6 +55,13 @@ enum OperationTypes */ stock bool:ZRIsClientPrivileged(client, OperationTypes:operationType = OperationType_Generic) { + // Check if console. + if (client == 0) + { + // Console always has full access no matter what. + return true; + } + // Validate client index. if (!ZRIsClientValid(client)) {