Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <amxmodx>
- #include <hamsandwich>
- #include <cstrike>
- #define PLUGIN "Player Models"
- #define VERSION "1.0"
- #define AUTHOR "unknown"
- public plugin_init() {
- register_plugin(PLUGIN, VERSION, AUTHOR)
- RegisterHam(Ham_Spawn, "player", "spawn_event", 1)
- }
- new const modellek[][] = {
- "models/player/tmodell/tmodell.mdl",
- "models/player/ctmodell/ctmodell.mdl"
- }
- public plugin_precache() {
- for(new i; i<sizeof(modellek);i++) precache_model(modellek[i]);
- }
- public spawn_event(id) {
- if(!is_user_alive(id)) return HAM_IGNORED;
- static team
- team = get_user_team(id)
- switch(team) {
- case 1: {
- if(get_user_flags(id) & ADMIN_BAN) cs_set_user_model(id, "tmodell");
- //else if((get_user_flags(id) & ADMIN_LEVEL_H) cs_set_user_model(id, "ctvip");
- }
- case 2: {
- if(get_user_flags(id) & ADMIN_BAN) cs_set_user_model(id, "ctmodell");
- //else if((get_user_flags(id) & ADMIN_LEVEL_H) cs_set_user_model(id, "tevip");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement