View Single Post
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 08-10-2012 , 19:34   Re: Disable vote command when Admin is Connected.
Reply With Quote #5

Quote:
Originally Posted by lucas_7_94 View Post
I think you can use bits , its better and dont need to do a loop , only a suggerestion.
No, it is fine as it is.
I would suggest that instead of is_user_admin you would check ( ADMIN_MAP | ADMIN_VOTE | ADMIN_RCON ) flag, because i don't think you want to disable wotes if there is only an admin with ADMIN_CHAT flag online.

Edit : my bad, but check against flags that allow admins to kick players, so, in plugin_cfg forward, check dynamically access level of amx_votekick, amx_voteban, amx_kick, amx_ban, amx_banip, make a bitsum of all flags and add ADMIN_RCON in it, or if you are lazy just do ADMIN_KICK | ADMIN_BAN | ADMIN_VOTE | ADMIN_RCON
__________________
- tired and retired -

- my plugins -

Last edited by ConnorMcLeod; 08-10-2012 at 19:47.
ConnorMcLeod is offline