Raised This Month: $12 Target: $400
 3% 

Super Admin Update* 4.1


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   Admin Commands        Approver:   Arkshine (91)
rak
Veteran Member
Join Date: Oct 2011
Location: banned country
Old 02-23-2012 , 21:43   Super Admin Update* 4.1
Reply With Quote #1

  • Description
SuperAdmin 1.1 = Any admin with the FLAG ADMIN_RCON >> "L" he can kick, ban, slap and slay any user and admin with immunity
SuperAdmin 2.2 = Any player with SteamID added in SuperAdmin.ini(File location: $moddir/addons/amxmodx/configs/SuperAdmin.ini) has the possibility to kick, ban, slap and slay any user and admin with immunity
SuperAdmin 3.1 = Menu added
SuperAdmin 4.1 = New command and auto create .ini File
  • Commands
Code:
amx_super_kick <name|#userid> <reason>
amx_super_ban <name|#userid> <time> <reason>
amx_super_banip <name|#userid> <time> <reason>
amx_super_slap <name|#userid> <damage>
amx_super_slay <name|#userid>
amx_addsuperadmin <name|#userid|steamid> |*NEW*|

amxsupermenu
amx_addsuperadmin_menu |*NEW*|
amx_super_kickmenu
amx_super_banmenu
amx_super_banipmenu
amx_super_slapmenu
amx_super_slaymenu
  • Additional Info
Admins can't ban Admins with Immunity or Super Admins, but to users. On the other side, Admins with Immunity must be able to ban Admins and users, but not to Staff Admins. Super Admins ban everybody. This is the primary function for this plugin.
  • Credits
  • Changelog
  • Super Admin 1.0 - First release
  • Super Admin 1.1 - Fix amx_super_slay
  • Super Admin 2.0 - SuperAdmin by SteamID
  • Super Admin 2.1 - Fix my mistake >> precache >> trim(Data) remove_quotes(Data)
  • Super Admin 2.2 - DinamicArrays >> Tries || Corrects Defines CMD || add charsmax in all string lengths || plugin_precache >> plugin_cfg || Delete file_exists || replace >> trim || Fix amx_super_slay
  • Super Admin 3.0 - Menu added and cmd_target deleted
  • Super Admin 3.1 - Good bye "goto"
  • Super Admin 4.0 - Add SuperAdmin by command || AutoCreate .ini File || add USAGE info
  • Super Admin 4.1 - Bug Super_Ban
Attached Files
File Type: ini SuperAdmin.ini (192 Bytes, 2436 views)
File Type: sma Get Plugin or Get Source (Super_Admin_1.1.sma - 2573 views - 5.5 KB)
File Type: sma Get Plugin or Get Source (Super_Admin_2.2.sma - 2408 views - 6.1 KB)
File Type: sma Get Plugin or Get Source (Super_Admin_3.1.sma - 2213 views - 10.8 KB)
File Type: sma Get Plugin or Get Source (Super_Admin_4.1.sma - 3644 views - 12.8 KB)
__________________

www.amxmodx-es.com

Steam: Luchokoldo

Last edited by rak; 03-31-2013 at 22:04. Reason: Update*
rak is offline
Send a message via MSN to rak Send a message via Skype™ to rak
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 02-23-2012 , 21:45   Re: Super Admin By [R]ak
Reply With Quote #2

Why should you give someone immunity if you want to kick or ban someone? This can be usefull but imo, it's pretty useless..
__________________
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
rak
Veteran Member
Join Date: Oct 2011
Location: banned country
Old 02-23-2012 , 21:54   Re: Super Admin By [R]ak
Reply With Quote #3

Quote:
Originally Posted by Napoleon_be View Post
Why should you give someone immunity if you want to kick or ban someone? This can be usefull but imo, it's pretty useless..
Only a few have access to FLAG ADMIN_RCON >> "L". It could be useful just for fun or supervision.
__________________

www.amxmodx-es.com

Steam: Luchokoldo

Last edited by rak; 02-23-2012 at 21:54.
rak is offline
Send a message via MSN to rak Send a message via Skype™ to rak
Neeeeeeeeeel.-
Some Guy Yellin'
Join Date: Jul 2010
Location: Argentina
Old 02-23-2012 , 23:23   Re: Super Admin By [R]ak
Reply With Quote #4

Good job

PHP Code:
new Authid[32]
get_user_authid(playerAuthid31
Should be
PHP Code:
new Authid[19]
get_user_authid(playerAuthid18
Code:
STEAM_X:X:XXXXXXXX
:B
__________________
Neeeeeeeeeel.- is offline
Send a message via Skype™ to Neeeeeeeeeel.-
rak
Veteran Member
Join Date: Oct 2011
Location: banned country
Old 02-23-2012 , 23:38   Re: Super Admin By [R]ak
Reply With Quote #5

Quote:
Originally Posted by Neeeeeeeeeel.- View Post
Good job

PHP Code:
new Authid[32]
get_user_authid(playerAuthid31
Should be
PHP Code:
new Authid[19]
get_user_authid(playerAuthid18
Code:
STEAM_X:X:XXXXXXXX
:B
yes but.. i use 32 because in the original plugin(admincmd) use 32.. but in get_user_authid
Code:
The max lenght of a STEAM`id is 34 bytes.
... i don't know if is better use 18 or 32 or 34 xD
Thanks you

[ES]
en el plugin original usa 32 de lenght.. pero en wiki aparece 34... no se que seria mejor.. quien los entiende xD... gracias
__________________

www.amxmodx-es.com

Steam: Luchokoldo

Last edited by rak; 02-23-2012 at 23:40.
rak is offline
Send a message via MSN to rak Send a message via Skype™ to rak
Devil259
Veteran Member
Join Date: Dec 2009
Location: France (59)
Old 02-24-2012 , 05:21   Re: Super Admin By [R]ak
Reply With Quote #6

new AuthID[ 35 ];
get_user_authid( player , Authid , charsmax( Authid ) );

Don't hardcode authid's lenght.

Also, you should use custom flag instead of rcon flag.

Another suggestion: add a *.ini file to get Super Admin by SteamID.
__________________
You can do anything you set your mind to, man.

Devil259 is offline
rak
Veteran Member
Join Date: Oct 2011
Location: banned country
Old 02-24-2012 , 05:42   Re: Super Admin By [R]ak
Reply With Quote #7

Quote:
Originally Posted by Devil259 View Post
new AuthID[ 35 ];
get_user_authid( player , Authid , charsmax( Authid ) );

Don't hardcode authid's lenght.

Also, you should use custom flag instead of rcon flag.

Another suggestion: add a *.ini file to get Super Admin by SteamID.
thanks! nice idea... i do this quickly
__________________

www.amxmodx-es.com

Steam: Luchokoldo
rak is offline
Send a message via MSN to rak Send a message via Skype™ to rak
rak
Veteran Member
Join Date: Oct 2011
Location: banned country
Old 02-24-2012 , 09:04   Re: Super Admin Update* 2.0
Reply With Quote #8

Update
__________________

www.amxmodx-es.com

Steam: Luchokoldo
rak is offline
Send a message via MSN to rak Send a message via Skype™ to rak
Moody92
Veteran Member
Join Date: May 2011
Location: Oman
Old 02-24-2012 , 09:45   Re: Super Admin Update* 2.0
Reply With Quote #9

I wonder if you can make
the admins ( Without immunity ) can't ban/kick/slap another admins ( Without immunity )

Last edited by Moody92; 02-24-2012 at 09:46.
Moody92 is offline
rak
Veteran Member
Join Date: Oct 2011
Location: banned country
Old 02-24-2012 , 10:00   Re: Super Admin Update* 2.0
Reply With Quote #10

Quote:
Originally Posted by Moody92 View Post
I wonder if you can make
the admins ( Without immunity ) can't ban/kick/slap another admins ( Without immunity )
try this

PHP Code:
#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Block Admins Without Immunity"
#define VERSION "1.0"
#define AUTHOR "[R]ak"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_concmd("amx_ban""Check")
    
register_concmd("amx_kick""Check")
    
register_concmd("amx_slap""Check")
    
register_concmd("amx_slay""Check")
}

public 
Check(id) {
    new 
Victim[32]
    
    
read_argv(1Victim31)
    
    new 
player cmd_target(idVictim8)
    
    if(!
player)
        return 
PLUGIN_HANDLED
    
    
if(get_user_flags(id) & ADMIN_IMMUNITY || !is_user_admin(player))
        return 
PLUGIN_CONTINUE
        
    
return PLUGIN_HANDLED

EDIT: put this plugin first in plugin.ini
__________________

www.amxmodx-es.com

Steam: Luchokoldo

Last edited by rak; 02-24-2012 at 10:01.
rak is offline
Send a message via MSN to rak Send a message via Skype™ to rak
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 13:05.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode