Pt raportari probleme add : geany_ronaldo13 !!!!
AcasaAcasa  PortalPortal  CalendarCalendar  FAQFAQ  CautareCautare  MembriMembri  GrupuriGrupuri  InregistrareInregistrare  ConectareConectare  
Welcome to UnicZone Community!!!
Cautam DESIGNERI priceputi!!!
Gazduim servere de Orice TIP!! Cu Sau fara HAMACHI!!!

Distribuiţi | 
 

 Santa Hat 1.3 + Snow

Vezi subiectul anterior Vezi subiectul urmator In jos 
AutorMesaj
avatar
Scatter


Mesaje : 36
Puncte : 107
Data de inscriere : 25/10/2011

MesajSubiect: Santa Hat 1.3 + Snow   Dum Dec 04, 2011 9:23 pm

Autor: xPaw
Versiune: 1.3

Download:
SMA :
Cod:
#include < amxmodx >
#include < engine >
#include < cstrike >
#include < hamsandwich >

new const g_szHatModel[ CsTeams ][ ] = {
    "",
    "models/santahat.mdl",
    "models/santahat_blue.mdl",
    ""
};

new g_iHats[ 33 ];

public plugin_init( ) {
    register_plugin( "Santa Hat + Snow", "1.3", "xPaw" );
   
    register_cvar( "santa_hat", "1.3", FCVAR_SERVER );
   
    register_event( "TeamInfo", "EventTeamInfo", "a" );
   
    RegisterHam( Ham_Spawn, "player", "FwdHamPlayerSpawn", 1 );
}

public plugin_precache( ) {
//  create_entity( "env_snow" );
   
    precache_model( g_szHatModel[ CS_TEAM_T ] );
    precache_model( g_szHatModel[ CS_TEAM_CT ] );
}

public client_disconnect( id )
    if( is_valid_ent( g_iHats[ id ] ) )
        remove_entity( g_iHats[ id ] );

public FwdHamPlayerSpawn( const id ) {
    if( is_user_alive( id ) ) {
        new iEntity = g_iHats[ id ];
       
        if( !is_valid_ent( iEntity ) ) {
            if( !( iEntity = g_iHats[ id ] = create_entity( "info_target" ) ) )
                return;
           
            new CsTeams:iTeam = cs_get_user_team( id );
           
            if( iTeam != CS_TEAM_T && iTeam != CS_TEAM_CT )
                iTeam = CS_TEAM_T;
           
            entity_set_model( iEntity, g_szHatModel[ iTeam ] );
            entity_set_int( iEntity, EV_INT_movetype, MOVETYPE_FOLLOW );
            entity_set_edict( iEntity, EV_ENT_aiment, id );
        }
    }
}

public EventTeamInfo( ) {
    new id = read_data( 1 ), iEntity = g_iHats[ id ];
   
    if( !is_valid_ent( iEntity ) ) {
        if( iEntity > 0 )
            g_iHats[ id ] = 0;
       
        return;
    }
   
    new szTeam[ 2 ];
    read_data( 2, szTeam, 1 );
   
    if( szTeam[ 0 ] == 'C' )
        entity_set_model( iEntity, g_szHatModel[ CS_TEAM_CT ] );
    else
        entity_set_model( iEntity, g_szHatModel[ CS_TEAM_T ] );
}
AMXX : http://www.girlshare.ro/1809943.3
Resurse : http://www.girlshare.ro/1809945.5

Descriere: Adauga la toti o caciula de Mos Craciun, echipa ct are caciulita albastra , iar t are caciulita rosie + ninge!
Instalare:
1. Adaugati fisierul santa_hat_snow.amxx in cstrike/addons/amxmodx/plugins
2. Adaugati fisierul santa_hat_snow.sma in cstrike/addons/amxmodx/scripting
3. Deschideti fisierul plugins.ini din cstrike/addons/amxmodx/configs si adaugati ;a urma.

Cod:
santa_hat_snow.amxx

4. Copiati modelele in in cstrike/models.

Module Necesare:

Cod:
engine
cstrike
hamsandwich

Imagine::
- http://img20.imageshack.us/img20/2422/26985167.png ( Acelasi model e si pentru tero, insa pe rosu.)
Sus In jos
 

Santa Hat 1.3 + Snow

Vezi subiectul anterior Vezi subiectul urmator Sus 
Pagina 1 din 1

Permisiunile acestui forum:Nu puteti raspunde la subiectele acestui forum
 :: CsZone :: Pluginuri AmxX & AdminMod-
Parteneri Forum
Cine este conectat?
top 90
creează un forum | © phpBB | Forum gratuit de suport | Contact | Semnaleaza un abuz | Creeaza-ti propriul blog
ForumGratuit