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

[REQ] BASEBUILDER Admin Skins


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
RazerxD
Junior Member
Join Date: Oct 2020
Location: Unknown
Old 10-24-2020 , 09:10   [REQ] BASEBUILDER Admin Skins
Reply With Quote #1

I Wanted A Plugin OF Admin-Skins

Details :
Model1 : ADMIN_LEVEL_H
Model2 : ADMIN_LEVEL_A

Just Wanted Two Skins For CT Only Not For Terrorist Team

THANKS
RazerxD is offline
r0ma
Senior Member
Join Date: Apr 2012
Location: Great Tomb of Nazarick
Old 10-24-2020 , 11:37   Re: [REQ] BASEBUILDER Admin Skins
Reply With Quote #2

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <hamsandwich>
#include <cstrike>

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "r0ma'"


#define mark_bit(%1,%2)    (%1 |= (1 << (%2 & 31)))
#define clear_bit(%1,%2)    (%1 &= ~ (1 << (%2 & 31)))
#define is_bit(%1,%2)    (%1 & ( 1 << (%2 & 31)))

enum AdminModel {
    
MODEL_NAME[33],
    
MODEL_FLAG
}

new const 
g_AdminModel[][AdminModel] = {
    { 
"admin1"ADMIN_LEVEL_H },
    { 
"admin2"ADMIN_LEVEL_A }
}

new 
g_UserChangeModel;

public 
plugin_precache() {
    new 
szBuffer[64];
    
    for(new 
isizeof g_AdminModeli++) {
        
formatex(szBuffercharsmax(szBuffer), "models/player/%s/%s.mdl"g_AdminModel[i][MODEL_NAME], g_AdminModel[i][MODEL_NAME]);
        
        
precache_model(szBuffer);
    }
}

public 
plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
RegisterHam(Ham_Spawn"player""fw_PlayerSpawn_Post"true);
}

public 
client_putinserver(id) {
    
clear_bit(g_UserChangeModelid);
}

public 
fw_PlayerSpawn_Post(id) {
    if(!
is_user_alive(id))
        return;
    
    if(
is_bit(g_UserChangeModelid) && cs_get_user_team(id) != CS_TEAM_CT) {
        
cs_reset_user_model(id);
        
clear_bit(g_UserChangeModelid);
        
        return;
    }
    
    new 
iFlags get_user_flags(id);
    
    for(new 
isizeof g_AdminModeli++) {
        if(
iFlags g_AdminModel[i][MODEL_FLAG]) {
            
cs_set_user_model(idg_AdminModel[i][MODEL_NAME]);
            
mark_bit(g_UserChangeModelid);
            
            break;
        }
    }
    
    

__________________
Discord:FluffyDeveloper#4753
Github: https://github.com/francoromaniello
AMX-ES: https://amxmodx-es.com/r0ma'

Last edited by r0ma; 10-24-2020 at 11:38.
r0ma is offline
Send a message via MSN to r0ma
RazerxD
Junior Member
Join Date: Oct 2020
Location: Unknown
Old 10-24-2020 , 14:54   Re: [REQ] BASEBUILDER Admin Skins
Reply With Quote #3

Thank you it work good
RazerxD is offline
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 09:26.


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