DeathRun sPE - V0.1

In jos

descarca DeathRun sPE - V0.1

Mesaj Scris de DarkArms la data de Lun Noi 14, 2016 6:52 pm

Descriere: Este baza lui xPaw doar ca am adaugat,sters eu din ea.

Descarcare:
Spoiler:
//////////////////////////////////////////////////////////////////////////
//////////////////////Credits/////////////////////////////////////////////
//////////////////////xPaw////////////////////////////////////////////////
//////////////////////HamletEagle/////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
//////////////////////V 0.1://////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
//////////////////////Delete Life system//////////////////////////////////
//////////////////////Add points system///////////////////////////////////
//////////////////////Add Knife Menu//////////////////////////////////////
//////////////////////Add hud information/////////////////////////////////
//////////////////////Add chat protection/////////////////////////////////
//////////////////////////////////////////////////////////////////////////

#include < amxmodx >
#include < engine >
#include < cstrike >
#include < fun >
#include < fakemeta >
#include < hamsandwich >
#include < nvault >

#pragma semicolon 1

new const g_szPrefix[ ] = "[ DeathRun sPE ]";

new bool:g_bHauntedHouse, bool:g_bGamerFun, bool:g_bRandromized, bool:g_bStarting, bool:g_bFirstRound;
new bool:g_bEnabled, bool:g_bRestart, bool:g_bConnected[ 33 ];

new g_pRemoveBuyZone, g_pHideHuds, g_pBlockMoney, g_pSvRestart, g_pAutoBalance, g_pLimitTeams;
new g_pNoFallDmg, g_pGameName, g_pToggle, g_pBlockSpray, g_pBlockRadio, g_pSemiclip, g_pGiveUsp, g_pBlockKill;

new g_iMsgHideWeapon, g_iMsgCrosshair, g_iMsgMoney, g_iMsgTeamInfo, g_iMsgSayText;
new g_iMaxplayers, g_iHudSync, g_iLastTerr, g_iThinker, g_pPoints, savepoints;
new g_iSemiClip[ 33 ], points[ 33 ];
new bool:bChat[33] = false;

#if cellbits == 32
#define OFFSET_BZ 235
#else
#define OFFSET_BZ 268
#endif

#define CHAT_PROT
#define KNIFE_MOD
#define SHOWHUD2

#if defined KNIFE_MOD
new const v_butcher [ 66 ] = "models/v_butcher.mdl";
new const p_butcher [ 66 ] = "models/p_butcher.mdl";

new bool: Knife [ 3 ];
new gravity_pointer;
new cvar_gravity;
new gravity1;
#endif

enum Color {
NORMAL = 1,
GREEN,
RED,
BLUE
};

new TeamName[ ][ ] = {
"",
"TERRORIST",
"CT",
"SPECTATOR"
};

public plugin_init( ) {
new const VERSION[ ] = "3.0.3";

register_plugin( "Deathrun Manager", VERSION, "xPaw" );

g_pToggle = register_cvar( "deathrun_toggle", "1" );
g_pBlockSpray = register_cvar( "deathrun_spray", "1" );
g_pBlockRadio = register_cvar( "deathrun_radio", "1" );
g_pBlockKill = register_cvar( "deathrun_blockkill", "1" );
g_pBlockMoney = register_cvar( "deathrun_blockmoney", "1" );
g_pSemiclip = register_cvar( "deathrun_semiclip", "1" );
g_pGiveUsp = register_cvar( "deathrun_giveusp", "1" );
g_pHideHuds = register_cvar( "deathrun_hidehud", "1" );
g_pGameName = register_cvar( "deathrun_gamename", "1" );
g_pNoFallDmg = register_cvar( "deathrun_terrnfd", "1" );
g_pRemoveBuyZone = register_cvar( "deathrun_removebz", "1" );
g_pPoints = register_cvar( "deathrun_points" , "5" );


new szMapName[ 64 ];
get_mapname( szMapName, 63 );

if( contain( szMapName, "deathrun_" ) != -1 ) {
set_pcvar_num( g_pToggle, 1 );

if( contain( szMapName, "hauntedhouse" ) != -1 )
g_bHauntedHouse = true;
else {
g_bHauntedHouse = false;

if( equal( szMapName, "deathrun_gamerfun" ) )
g_bGamerFun = true;
else
g_bGamerFun = false;
}
} else
set_pcvar_num( g_pToggle, 0 );

g_pSvRestart = get_cvar_pointer( "sv_restart" );
g_pAutoBalance = get_cvar_pointer( "mp_autoteambalance" );
g_pLimitTeams = get_cvar_pointer( "mp_limitteams" );

register_cvar( "deathrun_version", VERSION, FCVAR_SERVER | FCVAR_SPONLY );
set_cvar_string( "deathrun_version", VERSION );

register_dictionary( "deathrun.txt" );

register_logevent( "EventRoundStart", 2, "1=Round_Start" );
register_logevent( "EventRandromize", 2, "1=Round_End" );
register_event( "SendAudio", "EventTerrsWin", "a", "2&%!MRAD_terwin" );
register_event( "TextMsg", "EventRandromize", "a", "2&#Game_w" );
register_event( "Money", "EventMoney", "b" );
register_event( "ResetHUD", "EventResetHud", "be" );

g_bFirstRound = true;
g_iMaxplayers = get_maxplayers( );
g_iMsgHideWeapon = get_user_msgid( "HideWeapon" );
g_iMsgCrosshair = get_user_msgid( "Crosshair" );
g_iMsgMoney = get_user_msgid( "Money" );
g_iMsgSayText = get_user_msgid( "SayText" );
g_iMsgTeamInfo = get_user_msgid( "TeamInfo" );
//Points System
RegisterHam(Ham_Spawn, "player", "PointsKill", 1);
//
register_forward( FM_ClientKill, "FwdClientKill" );
register_impulse( 201, "FwdImpulse_201" );
//Points System
register_clcmd("say /points","PointsCmd");
register_clcmd("say_team /points","PointsCmd");
savepoints = nvault_open("pointsvalut");
//
#if defined KNIFE_MOD
register_clcmd ("say /knife","ShowMenu");
register_event ("CurWeapon","KnifeModelSet","be","1=1");
RegisterHam( Ham_Spawn, "player", "Remove_Knife", 1 ) ;

gravity_pointer = get_cvar_pointer ( "sv_gravity" );
cvar_gravity = get_pcvar_num ( gravity_pointer );
gravity1 = register_cvar ( "gravity_1","400.0" );
#endif
#if defined CHAT_PROT
register_clcmd("say /chat","cmdChat");
register_clcmd("say","cmdSay");
register_clcmd("say_team","cmdSay");
#endif

g_iHudSync = CreateHudSyncObj( );

if( get_pcvar_num( g_pToggle ) ) {
RegisterHam( Ham_TakeDamage, "player", "FwdHamPlayerDamage" );
RegisterHam( Ham_Spawn, "player", "FwdHamPlayerSpawn", 1 );
if( get_pcvar_num( g_pGameName ) )
register_forward( FM_GetGameDescription, "FwdGameDesc" );

register_clcmd( "radio1", "CmdRadio" );
register_clcmd( "radio2", "CmdRadio" );
register_clcmd( "radio3", "CmdRadio" );

g_iThinker= create_entity( "info_target" );

if( is_valid_ent( g_iThinker ) ) {
entity_set_string( g_iThinker, EV_SZ_classname, "DeathrunThinker" );
entity_set_float( g_iThinker, EV_FL_nextthink, get_gametime( ) + 20.0 );

g_bRestart = true;

register_think( "DeathrunThinker", "FwdThinker" );
} else {
set_task( 15.0, "CheckTerrorists", _, _, _, "b" );

set_task( 20.0, "RestartRound" );
}

if( get_pcvar_num( g_pRemoveBuyZone ) ) {
register_message( get_user_msgid( "StatusIcon" ), "MsgStatusIcon" );

remove_entity_name( "info_map_parameters" );
remove_entity_name( "func_buyzone" );

new iEntity = create_entity( "info_map_parameters" );

DispatchKeyValue( iEntity, "buying", "3" );
DispatchSpawn( iEntity );
}

if( get_pcvar_num( g_pSemiclip ) ) {
register_forward( FM_StartFrame, "FwdStartFrame", 0 );
register_forward( FM_AddToFullPack, "FwdFullPack", 1 );
}

g_bEnabled = true;

} else
g_bEnabled = false;
}
#if defined KNIFE_MOD
public plugin_precache() {

precache_model ( v_butcher );
precache_model ( p_butcher );

}
#endif
public plugin_natives( ){

register_native( "get_user_points", "_get_points" );
register_native( "set_user_points", "_set_points" );
}

public _get_points( plugin, params ){

return points[ get_param( 1 ) ];
}

public _set_points( plugin, params ){

new client = get_param( 1 );
points[ client ] = max( 0, get_param( 2 ) );
return points[ client ];
}

public SavePoints( id ){

new PlayerName[ 35 ];
get_user_authid( id, PlayerName, 34 );
new vaultkey[ 64 ], vaultdata[ 256 ];
format( vaultkey, 63, "%s",PlayerName );
format( vaultdata, 255, "%i",points[ id ] );
nvault_set( savepoints, vaultkey, vaultdata );
return PLUGIN_CONTINUE;
}

public LoadPoints( id )
{
new PlayerName[ 35 ];
get_user_authid( id, PlayerName, 34 );

new vaultkey[ 64 ],vaultdata[ 256 ];
format( vaultkey, 63, "%s", PlayerName );
nvault_get( savepoints, vaultkey, vaultdata, 255 );

replace_all( vaultdata, 255, " ", " " );

new playerlives[ 33 ];

parse( vaultdata, playerlives, 31 );

points[ id ] = str_to_num( playerlives );

return PLUGIN_CONTINUE;
}

public PointsKill( victim, attacker, shouldgib )
{
if( !attacker || attacker == victim )
return PLUGIN_HANDLED;

points[ attacker ] += get_pcvar_num( g_pPoints );
return PLUGIN_CONTINUE;
}

public PointsCmd( id )
{
ColorChat( id, RED, "[ Points ] ^4You have %i points !",points[ id ]);
return;
}

#if defined KNIFE_MOD
public KnifeModelSet(id) {

if( get_user_weapon( id )== CSW_KNIFE ) {

if( Knife [ 1 ] == true ) {


}

if( Knife [ 2 ] == true ) {

set_pev ( id, pev_viewmodel2, v_butcher );
set_pev ( id, pev_weaponmodel2, p_butcher );
set_user_gravity( id, get_pcvar_float(gravity1) / cvar_gravity);
}

}

else set_user_gravity(id,float(cvar_gravity)/float(cvar_gravity));


}

public ShowMenu( id )
{
new menu = menu_create( "Knife Menu", "knife_handler" );

menu_additem( menu, "\wExpert Knife", "", 0 );
menu_additem( menu, "\wButcher Knife \y[ \r400 Gravity \y]", "", 0 );

menu_setprop( menu, MPROP_EXIT, MEXIT_ALL );
menu_setprop( menu, MPROP_NOCOLORS, 1 );

menu_display( id, menu, 0 );

return PLUGIN_HANDLED;
}

public knife_handler(id, menu, item)
{
if(item == MENU_EXIT)
{
menu_cancel(id);
return PLUGIN_HANDLED;
}

new command[6], name[64], access, callback;

menu_item_getinfo(menu, item, access, command, sizeof command - 1, name, sizeof name - 1, callback);

switch(item)
{
case 0: {

Knife[ 1 ] = true;
Knife[ 2 ] = false;


}
case 1: {

Knife[ 2 ] = true;
Knife[ 1 ] = false;


set_pev ( id, pev_viewmodel2, v_butcher );
set_pev ( id, pev_weaponmodel2, p_butcher );

}

}

menu_destroy( menu );

return PLUGIN_HANDLED;
}

public Remove_Knife( id ) {

Knife [ 1 ] = false;
Knife [ 2 ] = false;

}
#endif
#if defined CHAT_PROT
public cmdSay(id) {
if(bChat[ id ] )
return 0;
else
{
client_print( id, print_chat, "Scrie /chat pentru a putea scrie" );
return 1;
}
return 0;
}
public cmdChat(id) {
if(bChat[ id ] )
return 1;
bChat[ id ] = true;
client_print( id, print_chat, "Chat-ul a fost deblocat cu succes!" );
return 0;
}
#endif
public EventRandromize( ) {
if( !g_bEnabled || g_bFirstRound || g_bRandromized )
return PLUGIN_CONTINUE;

g_bRandromized = true;

new i, iPlayers[ 32 ], iNum, iPlayer;
get_players( iPlayers, iNum, "c" );

if( iNum <= 1 )
return PLUGIN_CONTINUE;

for( i = 0; i < iNum; i++ ) {
iPlayer = iPlayers[ i ];

if( cs_get_user_team( iPlayer ) == CS_TEAM_T )
cs_set_user_team( iPlayer, CS_TEAM_CT );
}

new iRandomPlayer, CsTeams:iTeam;

while( ( iRandomPlayer = iPlayers[ random_num( 0, iNum - 1 ) ] ) == g_iLastTerr ) { }

g_iLastTerr = iRandomPlayer;

iTeam = cs_get_user_team( iRandomPlayer );

if( iTeam == CS_TEAM_T || iTeam == CS_TEAM_CT ) {
cs_set_user_team(iRandomPlayer, CS_TEAM_T);

new szName[ 32 ];
get_user_name( iRandomPlayer, szName, 31 );

for( i = 0; i < iNum; i++ )
ColorChat(iPlayers[ i ], RED, "%s^4 %L", g_szPrefix, iPlayers[ i ], "DR_NOW_TERR", szName);

if( !g_bRestart && is_valid_ent( g_iThinker ) )
entity_set_float( g_iThinker, EV_FL_nextthink, get_gametime( ) + 15.0 );
} else {
g_bRandromized = false;
EventRandromize( );
}

return PLUGIN_CONTINUE;
}

public EventRoundStart( ) {
if( !g_bEnabled )
return PLUGIN_CONTINUE;

g_bRandromized = false;
g_bStarting = false;

new i, iPlayers[ 32 ], iNum, iRealPlayers, CsTeams:iTeam;
get_players( iPlayers, iNum, "c" );

if( iNum <= 1 )
return PLUGIN_CONTINUE;

for( i = 0; i < iNum; i++ ) {
iTeam = cs_get_user_team( iPlayers[ i ] );

if( iTeam == CS_TEAM_T || iTeam == CS_TEAM_CT )
iRealPlayers++;
}

if( iRealPlayers <= 1 ) {
set_hudmessage( 0, 128, 0, -1.0, 0.1, 0, 4.0, 4.0, 0.5, 0.5, 4 );

for( i = 0; i < iNum; i++ )
ShowSyncHudMsg( iPlayers[ i ], g_iHudSync, "%L", iPlayers[ i ], "DR_NOT_ENOUGH" );

return PLUGIN_CONTINUE;
}

set_pcvar_num( g_pAutoBalance, 0 );
set_pcvar_num( g_pLimitTeams, 0 );

if( g_bFirstRound ) {
set_hudmessage( 0, 128, 0, -1.0, 0.1, 0, 4.0, 4.0, 0.5, 0.5, 4 );

for( i = 0; i < iNum; i++ ) {
ShowSyncHudMsg( iPlayers[ i ], g_iHudSync, "%L", iPlayers[ i ], "DR_STARTING" );

ColorChat( iPlayers[ i ], RED, "%s^1 %L", g_szPrefix, iPlayers[ i ], "DR_STARTING_CC" );
}

if( is_valid_ent( g_iThinker ) ) {
g_bRestart = true;

entity_set_float( g_iThinker, EV_FL_nextthink, get_gametime( ) + 9.0 );
} else
set_task( 9.0, "RestartRound" );

g_bStarting = true;
g_bFirstRound = false;
}

return PLUGIN_CONTINUE;
}

public FwdThinker( iEntity ) {
if( g_bRestart ) {
g_bRestart = false;

RestartRound( );
} else
CheckTerrorists( );

entity_set_float( iEntity, EV_FL_nextthink, get_gametime( ) + 15.0 );
}

public CheckTerrorists( ) {
if( !g_bEnabled || g_bFirstRound || g_bStarting )
return PLUGIN_CONTINUE;

new i, iPlayers[ 32 ], iTerrors, iNum, iRealPlayers, CsTeams:iTeam;
get_players( iPlayers, iNum, "c" );

if( iNum <= 1 )
return PLUGIN_CONTINUE;

for( i = 0; i < iNum; i++ ) {
iTeam = cs_get_user_team( iPlayers[ i ] );

if( iTeam == CS_TEAM_T )
iTerrors++;

if( iTeam == CS_TEAM_T || iTeam == CS_TEAM_CT )
iRealPlayers++;
}

if( iRealPlayers <= 1 ) {
set_hudmessage( 0, 128, 0, -1.0, 0.1, 0, 4.0, 4.0, 0.5, 0.5, 4 );

for( i = 0; i < iNum; i++ )
ShowSyncHudMsg( iPlayers[ i ], g_iHudSync, "%L", iPlayers[ i ], "DR_NOT_ENOUGH" );

return PLUGIN_CONTINUE;
}

if( iTerrors == 0 ) {
for( i = 0; i < iNum; i++ ) {
ColorChat(iPlayers[ i ], RED, "%s^1 %L", g_szPrefix, iPlayers[ i ], "DR_NO_DETECT");

if( is_user_alive( iPlayers[ i ] ) && cs_get_user_team( iPlayers[ i ] ) == CS_TEAM_CT )
user_silentkill( iPlayers[ i ] );
}

set_task( 0.5, "EventRandromize" );
}

return PLUGIN_CONTINUE;
}

public EventTerrsWin( ) {
if( !g_bEnabled || g_bFirstRound )
return PLUGIN_CONTINUE;

new iPlayers[ 32 ], iNum, iPlayer;
get_players( iPlayers, iNum, "c" );

if( iNum <= 1 )
return PLUGIN_CONTINUE;

for( new i = 0; i < iNum; i++ ) {
iPlayer = iPlayers[ i ];

if( cs_get_user_team( iPlayer ) == CS_TEAM_T ) {
set_user_frags( iPlayer, get_user_frags( iPlayer ) + 3 );

}
}

return PLUGIN_CONTINUE;
}

public EventResetHud( id ) {
if( g_bEnabled && get_pcvar_num( g_pHideHuds ) && !is_user_bot( id ) ) {
message_begin( MSG_ONE_UNRELIABLE, g_iMsgHideWeapon, _, id );
write_byte( ( 1<<4 | 1<<5 ) );
message_end( );

message_begin( MSG_ONE_UNRELIABLE, g_iMsgCrosshair, _, id );
write_byte( 0 );
message_end( );
}
}

public EventMoney( id ) {
if( g_bEnabled && get_pcvar_num( g_pBlockMoney ) ) {
set_pdata_int( id, 115, 0 );

message_begin( MSG_ONE_UNRELIABLE, g_iMsgMoney, _, id );
write_long ( 0 );
write_byte ( 1 );
message_end( );
}
}

public client_putinserver( id ) {
g_bConnected[ id ] = true;
#if defined CHAT_PROT
bChat[ id ] = false;
set_task( 2.0, "chat_exec", id );
#endif
#if defined SHOWHUD2
ShowHudDet( id );
#endif
}
#if defined SHOWHUD2
public ShowHudDet( id )
{
if(is_user_alive( id ) )
{
set_hudmessage(0, 255, 255, 0.01, 0.90, 0, 6.0, 3600.0);
show_hudmessage(id, "HP: %d | Armor: %d | Credits: %i", get_user_health(id), get_user_armor(id),points[ id ]);
}

else
{
set_hudmessage(0, 255, 255, 0.01, 0.90, 0, 6.0, 3600.0);
show_hudmessage(id, "HP: %d | Armor: %d | Credits: %i", get_user_health(id), get_user_armor(id),points[ id ]);
}
}
#endif
#if defined CHAT_PROT
public chat_exec( id ){

if( is_user_connected( id ) )
client_print( id, print_chat, "Pentru a debloca chat-ul scrie /chat" );

}
#endif

public client_disconnect( id ) {
SavePoints( id );
remove_task(id);
g_bConnected[ id ] = false;
CheckTerrorists( );

if( !g_bRestart && is_valid_ent( g_iThinker ) )
entity_set_float( g_iThinker, EV_FL_nextthink, get_gametime( ) + 15.0 );
}

public client_authorized( id )
{
LoadPoints( id );
}

public FwdFullPack( es, e, ent, host, flags, player, pSet ) {
if( !g_bEnabled )
return FMRES_IGNORED;

if( player && g_iSemiClip[ ent ] && g_iSemiClip[ host ] ) {
set_es( es, ES_Solid, SOLID_NOT );
set_es( es, ES_RenderMode, kRenderTransAlpha );
set_es( es, ES_RenderAmt, 85 );
}

return FMRES_IGNORED;
}

public FwdStartFrame( ) {
if( !g_bEnabled )
return FMRES_IGNORED;

static iPlayers[ 32 ], iNum, iPlayer, iPlayer2, i, j;
get_players( iPlayers, iNum, "ache", "CT" );

arrayset( g_iSemiClip, 0, 32 );

if( iNum <= 1 )
return FMRES_IGNORED;

for( i = 0; i < iNum; i++ ) {
iPlayer = iPlayers[ i ];

for( j = 0; j < iNum; j++ ) {
iPlayer2 = iPlayers[ j ];

if( iPlayer == iPlayer2 )
continue;

if( g_iSemiClip[ iPlayer ] && g_iSemiClip[ iPlayer2 ] )
continue;

if( entity_range( iPlayer, iPlayer2 ) < 128 ) {
g_iSemiClip[ iPlayer ] = true;
g_iSemiClip[ iPlayer2 ] = true;
}
}
}

for( i = 0; i < iNum; i++ ) {
iPlayer = iPlayers[ i ];

set_pev( iPlayer, pev_solid, g_iSemiClip[ iPlayer ] ? SOLID_NOT : SOLID_SLIDEBOX );
}

return FMRES_IGNORED;
}

public FwdHamPlayerSpawn( id ) {
if( !g_bEnabled || !is_user_alive( id ) )
return HAM_IGNORED;

if( get_pcvar_num( g_pBlockRadio ) )
set_pdata_int( id, 192, 0 );

new CsTeams:iTeam = cs_get_user_team( id );

strip_user_weapons( id );
give_item( id, "weapon_knife" );

set_pdata_int( id, 116, 0 );

if( g_bGamerFun && iTeam == CS_TEAM_CT )
give_item( id, "weapon_smokegrenade" );

if( get_pcvar_num( g_pGiveUsp ) && iTeam == CS_TEAM_CT && !g_bHauntedHouse )
set_task( 1.0, "GiveUsp", id );

return HAM_IGNORED;
}

public GiveUsp( const id ) {
if( is_user_alive( id ) ) {
give_item( id, "weapon_usp" );
cs_set_user_bpammo( id, CSW_USP, 100 );
}
}

public FwdGameDesc( ) {
static const GameName[ ] = "Deathrun v3.0";

forward_return( FMV_STRING, GameName );

return FMRES_SUPERCEDE;
}

public FwdClientKill( const id ) {
if( !g_bEnabled || !is_user_alive(id) )
return FMRES_IGNORED;

if( get_pcvar_num( g_pBlockKill ) || cs_get_user_team( id ) == CS_TEAM_T ) {
client_print( id, print_center, "%L", id, "DR_BLOCK_KILL" );
client_print( id, print_console, "%L", id, "DR_BLOCK_KILL" );

return FMRES_SUPERCEDE;
}

return FMRES_IGNORED;
}

public FwdImpulse_201( const id ) {
if( g_bEnabled && get_pcvar_num( g_pBlockSpray ) ) {
if( is_user_alive( id ) )
client_print( id, print_center, "%L", id, "DR_BLOCK_SPRAY" );

return PLUGIN_HANDLED_MAIN;
}

return PLUGIN_CONTINUE;
}

public FwdHamPlayerDamage( id, idInflictor, idAttacker, Float:flDamage, iDamageBits ) {
if( get_pcvar_num( g_pNoFallDmg ) )
if( iDamageBits & DMG_FALL )
if( get_user_team( id ) == 1 )
return HAM_SUPERCEDE;

return HAM_IGNORED;
}

public MsgStatusIcon( msg_id, msg_dest, id ) {
new szIcon[ 8 ];
get_msg_arg_string( 2, szIcon, 7 );

static const BuyZone[ ] = "buyzone";

if( equal( szIcon, BuyZone ) ) {
set_pdata_int( id, OFFSET_BZ, get_pdata_int( id, OFFSET_BZ, 5 ) & ~( 1 << 0 ), 5 );

return PLUGIN_HANDLED;
}

return PLUGIN_CONTINUE;
}

public CmdRadio( id ) {
if( get_pcvar_num( g_pBlockRadio ) )
return PLUGIN_HANDLED_MAIN;

return PLUGIN_CONTINUE;
}

public RestartRound( )
set_pcvar_num( g_pSvRestart, 1 );

ColorChat( id, Color:type, const szMessage[], {Float,Sql,Result,_}:... ) {
if( !get_playersnum( ) ) return;

new message[ 256 ];

switch( type ) {
case NORMAL: message[0] = 0x01;
case GREEN: message[0] = 0x04;
default: message[0] = 0x03;
}

vformat( message[ 1 ], 251, szMessage, 4 );

message[ 192 ] = '^0';

replace_all( message, 191, "\YEL", "^1" );
replace_all( message, 191, "\GRN", "^4" );
replace_all( message, 191, "\TEM", "^3" );

new iTeam, ColorChange, index, MSG_Type;

if( id ) {
MSG_Type = MSG_ONE_UNRELIABLE;
index = id;
} else {
index = CC_FindPlayer();
MSG_Type = MSG_BROADCAST;
}

iTeam = get_user_team( index );
ColorChange = CC_ColorSelection(index, MSG_Type, type);

CC_ShowColorMessage(index, MSG_Type, message);

if( ColorChange )
CC_Team_Info(index, MSG_Type, TeamName[iTeam]);
}

CC_ShowColorMessage( id, type, message[] ) {
message_begin( type, g_iMsgSayText, _, id );
write_byte( id );
write_string( message );
message_end( );
}

CC_Team_Info( id, type, team[] ) {
message_begin( type, g_iMsgTeamInfo, _, id );
write_byte( id );
write_string( team );
message_end( );

return 1;
}

CC_ColorSelection( index, type, Color:Type ) {
switch( Type ) {
case RED: return CC_Team_Info( index, type, TeamName[ 1 ] );
case BLUE: return CC_Team_Info( index, type, TeamName[ 2 ] );
}

return 0;
}

CC_FindPlayer( ) {
for( new i = 1; i <= g_iMaxplayers; i++ )
if( g_bConnected[ i ] )
return i;

return -1;
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/

Nume: DeathRun sPE
Versiune: 0.1
Link oficial:

Instalare:
1. Fisierul nume_plugin.sma il puneti in addons/amxmodx/scripting
2. Fisierul nume_plugin.amxx il puneti in addons/amxmodx/plugins
3. Intrati in fisierul addons/amxmodx/configs/plugins.ini si adaugati la urma:
Cod:
nume_plugin.amxx
4. Alti pasi necesari....

Module necesare (se sterge ; din fata modulului de mai jos; acestea le gasiti in fisierul amxmodx\configs\modules.ini):
In sma.

Imagini: -

DarkArms
Founders
Founders

Mesaje : 226
Data de inscriere : 23/09/2016
Varsta : 16
Localizare : Terra

http://lowgamers.forumgratuit.ro

Sus In jos

descarca Re: DeathRun sPE - V0.1

Mesaj Scris de Dracu la data de Lun Noi 14, 2016 10:43 pm

Good Job!
avatar
Dracu
Moderators
Moderators

Mesaje : 193
Data de inscriere : 11/11/2016

Sus In jos

descarca Re: DeathRun sPE - V0.1

Mesaj Scris de Tipu la data de Mier Noi 23, 2016 1:26 pm

Good Job!
avatar
Tipu
Administrators
Administrators

Mesaje : 151
Data de inscriere : 22/11/2016

Sus In jos

descarca Re: DeathRun sPE - V0.1

Mesaj Scris de CelRau la data de Dum Noi 27, 2016 7:55 pm

Good Job!
avatar
CelRau
Registered user
Registered user

Mesaje : 184
Data de inscriere : 26/11/2016

Sus In jos

descarca Re: DeathRun sPE - V0.1

Mesaj Scris de Continut sponsorizat


Continut sponsorizat


Sus In jos

Sus


 
Permisiunile acestui forum:
Nu puteti raspunde la subiectele acestui forum