- bmb events | Afiseaza codul
/*.qggL * .gggr. . ' . * . + PMML . /|MM '. + ' |!MM,' /`|MM .d/"q, qgg;+Ml qgg;+Ml vgg. .y. Vv Vv Vv Vv | YMM,j' |MM MM;.jMl |MM` " |MM` " qM| j` x O o, o, o, o, | qM#' |MM MM| |MM + |MM . MMg' /(_){-}+--===--===--===--=== .j|. qF .+MM..'MMbxr` jMM. jMM. * 'MF \=====/ > > > > > > > > . * x, / .x/--\xxl ,xx . * ,gb v#' . . ' * .dMT 'q| |MM ' '"' .dM * dMM * ` |MM/dMg, qgg;+Ml qgg j/"`+ qMM-. qgg/dM#,w#Mb ,g'`fg, j/"`+ MMM .' |MM MM| |MM` " |MM MMbx/ |MM |MM |M| MM `p'. M| MMbx/ 'MMl + . |MM MM| |MM . |MM .`vMMl |MM |MM |M| MM , ,!. | .`vMMl 'vMb...r/` jMM..MM|. jMM. + jMM. +,.,P' 'MMx: jMM..dM|..MM, M j't | +,.*/ #include < amxmodx > #include < cstrike > #include < engine > #include < ColorChat > native csgo_set_user_points(id, amount); native csgo_get_user_points(id); /*===========================================================================*/ new const FogDensity[] = { 0, 0, 0, 0, 111, 18, 3, 58, 111, 18, 125, 58, 66, 96, 27, 59, 90, 101, 60, 59, 90, 101, 68, 59, 10, 41, 95, 59, 111, 18, 125, 59, 111, 18, 3, 60, 68, 116, 19, 60 } new const TASK_FOG = 112 new RGB[3]; new CVAR[2]; new const PlantedSound[ ] = "xmas/xmas_bomb_planted.mp3"; public plugin_init( ) { register_plugin("[XMAS] Bomb Events", "1.0", "A k c 3 n 7"); register_logevent("logevent_round_end", 2, "1=Round_End"); CVAR[0] = register_cvar("Fog", "1"); CVAR[1] = register_cvar("Dens", "1"); RGB[0] = 0; RGB[1] = 179; RGB[2] = 255; } public plugin_precache( ) { precache_sound(PlantedSound); // engfunc(EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, "env_snow")); } public bomb_planted( Client ) { PlaySoundToClients (PlantedSound); static Nume[32]; get_user_name( Client, Nume, sizeof ( Nume ) -1 ); csgo_set_user_points(Client, csgo_get_user_points(Client) + 300); ColorChat(0, GREEN, "^x04 [XMAS]^x03 Player^x04 %s^x03 a primit^x04 300$^x03 pentru ca a impodobit Bradul", Nume); /*==========================================================================================================*/ set_cvar_string("Fog", "1") set_task(0.1, "TaskFog", TASK_FOG, _, _, "b") } public logevent_round_end( ) { set_cvar_string("Fog", "0") } public bomb_defused( Client ) { static Nume[32]; get_user_name( Client, Nume, sizeof ( Nume ) -1 ); csgo_set_user_points(Client, csgo_get_user_points(Client) + 300); ColorChat(0, GREEN, "^x04 [XMAS]^x03 Player^x04 %s^x03 a primit^x04 300$^x03 pentru ca a salvat Craciunul", Nume); } /*==================================================================================================================*/ public TaskFog( ) { static density density = (4 * get_pcvar_num(CVAR[1])) if(get_pcvar_num(CVAR[0]) == 1) { message_begin(MSG_ALL, get_user_msgid("Fog"), {0,0,0}, 0); write_byte(RGB[0]); write_byte(RGB[1]); write_byte(RGB[2]); write_byte(FogDensity[density]); write_byte(FogDensity[density+1]); write_byte(FogDensity[density+2]); write_byte(FogDensity[density+3]); message_end(); } else { message_begin(MSG_ALL, get_user_msgid("Fog"), {0,0,0}, 0); write_byte(0); write_byte(0); write_byte(0); write_byte(0); write_byte(0); write_byte(0); write_byte(0); message_end(); } return PLUGIN_CONTINUE; } PlaySoundToClients ( const sound [ ] ) { if ( equal ( sound [ strlen ( sound ) -4 ], ".mp3" ) ) client_cmd ( 0, "mp3 play ^"sound/%s^"", sound ); else client_cmd ( 0, "spk ^"%s^"", sound ); }
Modificare bomb events
Moderators: Moderatori ajutatori, Moderatori, Echipa eXtreamCS.com
- Doctor whO? <3
- Membru, skill +3
- Posts: 1196
- Joined: 21 Jun 2013, 12:40
- Detinator Steam: Da
- CS Status: Citesc forumul eXtreamCS.com...!
- Reputatie: Fost Membru Club eXtreamCS (doua luni)
- Has thanked: 109 times
- Been thanked: 75 times
- Contact:
Salut, am luat dintr-un addons un plugin ce pune anumite chestii cand plantezi bomba, are si un sunet si problema este ca si dupa ce castiga echipa T runda, sunetul inca continua sa cante pentru cateva secunde... Eu as vrea sa se opreasca de tot cand incepe o runda noua.
- bmb events | Afiseaza codul
- aEEk.#
- Membru, skill 0
- Posts: 52
- Joined: 13 Sep 2012, 22:06
- Detinator Steam: Da
- CS Status: Open your mind.
- SteamID: ale_alexa2389
- Location: VSTS
- Has thanked: 7 times
- Been thanked: 3 times
- Contact:
initializezi in plugin_init asta:
iar in publicul sau fortezi stopsound pentru clienti:
incearca asa.
Code: Select all
register_logevent("LogEvent_NewRound", 2, "1=Round_Start");
Code: Select all
public LogEvent_NewRound()
{
client_cmd(0, "stopsound");
}
- Doctor whO? <3
- Membru, skill +3
- Posts: 1196
- Joined: 21 Jun 2013, 12:40
- Detinator Steam: Da
- CS Status: Citesc forumul eXtreamCS.com...!
- Reputatie: Fost Membru Club eXtreamCS (doua luni)
- Has thanked: 109 times
- Been thanked: 75 times
- Contact:
Am facut asa si nu merge... Tot se aude muzica cand incepe o runda noua.aEEk.# wrote: ↑01 Dec 2020, 16:59initializezi in plugin_init asta:iar in publicul sau fortezi stopsound pentru clienti:Code: Select all
register_logevent("LogEvent_NewRound", 2, "1=Round_Start");
incearca asa.Code: Select all
public LogEvent_NewRound() { client_cmd(0, "stopsound"); }
- bomb events | Afiseaza codul
- Doctor whO? <3
- Membru, skill +3
- Posts: 1196
- Joined: 21 Jun 2013, 12:40
- Detinator Steam: Da
- CS Status: Citesc forumul eXtreamCS.com...!
- Reputatie: Fost Membru Club eXtreamCS (doua luni)
- Has thanked: 109 times
- Been thanked: 75 times
- Contact:
- JaiLBreaK
- Scripter eXtreamCS
- Posts: 1517
- Joined: 05 Jan 2016, 18:17
- Detinator Steam: Nu
- Detinator server CS: Da
- Reputatie: Membru Club eXtreamCS (2 luni)
Fost Scripter eXtreamCS - Fond eXtream: 0
- Has thanked: 5 times
- Been thanked: 10 times
- Contact:
Code: Select all
#include < amxmodx >
#include < cstrike >
#include < engine >
#include < ColorChat >
native csgo_set_user_points(id, amount);
native csgo_get_user_points(id);
/*===========================================================================*/
new const FogDensity[] = { 0, 0, 0, 0, 111, 18, 3, 58, 111, 18, 125, 58, 66, 96, 27, 59, 90, 101, 60, 59, 90,
101, 68, 59, 10, 41, 95, 59, 111, 18, 125, 59, 111, 18, 3, 60, 68, 116, 19, 60 }
new const TASK_FOG = 112
new RGB[3];
new CVAR[2];
new const PlantedSound[ ] = "xmas/xmas_bomb_planted.mp3";
public plugin_init( ) {
register_plugin("[XMAS] Bomb Events", "1.0", "A k c 3 n 7");
register_logevent("logevent_round_end", 2, "1=Round_End");
register_event("HLTV", "logevent_round_start", "a", "1=0", "2=0");
CVAR[0] = register_cvar("Fog", "1");
CVAR[1] = register_cvar("Dens", "1");
RGB[0] = 0;
RGB[1] = 179;
RGB[2] = 255;
}
public plugin_precache( ) {
precache_sound(PlantedSound);
// engfunc(EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, "env_snow"));
}
public bomb_planted( Client ) {
PlaySoundToClients (PlantedSound);
static Nume[32];
get_user_name( Client, Nume, sizeof ( Nume ) -1 );
csgo_set_user_points(Client, csgo_get_user_points(Client) + 300);
ColorChat(0, GREEN, "^x04 [XMAS]^x03 Player^x04 %s^x03 a primit^x04 300$^x03 pentru ca a impodobit Bradul", Nume);
/*==========================================================================================================*/
set_cvar_string("Fog", "1")
set_task(0.1, "TaskFog", TASK_FOG, _, _, "b")
}
public logevent_round_end( ) {
set_cvar_string("Fog", "0")
}
public logevent_round_start( )
{
client_cmd ( 0, "mp3 stop" );
client_cmd ( 0, "stopsound" );
}
public bomb_defused( Client ) {
static Nume[32];
get_user_name( Client, Nume, sizeof ( Nume ) -1 );
csgo_set_user_points(Client, csgo_get_user_points(Client) + 300);
ColorChat(0, GREEN, "^x04 [XMAS]^x03 Player^x04 %s^x03 a primit^x04 300$^x03 pentru ca a salvat Craciunul", Nume);
}
/*==================================================================================================================*/
public TaskFog( ) {
static density
density = (4 * get_pcvar_num(CVAR[1]))
if(get_pcvar_num(CVAR[0]) == 1) {
message_begin(MSG_ALL, get_user_msgid("Fog"), {0,0,0}, 0);
write_byte(RGB[0]);
write_byte(RGB[1]);
write_byte(RGB[2]);
write_byte(FogDensity[density]);
write_byte(FogDensity[density+1]);
write_byte(FogDensity[density+2]);
write_byte(FogDensity[density+3]);
message_end();
}
else
{
message_begin(MSG_ALL, get_user_msgid("Fog"), {0,0,0}, 0);
write_byte(0);
write_byte(0);
write_byte(0);
write_byte(0);
write_byte(0);
write_byte(0);
write_byte(0);
message_end();
}
return PLUGIN_CONTINUE;
}
PlaySoundToClients ( const sound [ ] )
{
if ( equal ( sound [ strlen ( sound ) -4 ], ".mp3" ) )
client_cmd ( 0, "mp3 play ^"sound/%s^"", sound );
else
client_cmd ( 0, "spk ^"%s^"", sound );
}
CSGO Original Module[35%]
- Doctor whO? <3
- Membru, skill +3
- Posts: 1196
- Joined: 21 Jun 2013, 12:40
- Detinator Steam: Da
- CS Status: Citesc forumul eXtreamCS.com...!
- Reputatie: Fost Membru Club eXtreamCS (doua luni)
- Has thanked: 109 times
- Been thanked: 75 times
- Contact:
Voi testa cand ajung acasa, mersi de ajutor :D.
Edit:
Acum e ok, dau bere zorken si mersi de ajutor :D
Edit:
Acum e ok, dau bere zorken si mersi de ajutor :D