Ei pessoal o King Fighter tentou me ajuda com o som do ovo de packs
mas nao conseguiu, eu tou querendo que quando eu pego o ovo faz um som
ai quem tiver perto de mim faz ouvir tbm o som
eu vi ali em um plugin mas nao consegui colocar só sei que é esse negocio aki
tentem colocar o som nesse plugin aki !
tentem ai gente pf eu preciso desse som
mas nao conseguiu, eu tou querendo que quando eu pego o ovo faz um som
ai quem tiver perto de mim faz ouvir tbm o som
eu vi ali em um plugin mas nao consegui colocar só sei que é esse negocio aki
Código:
new g_sound[] = { "zombie_plague/egg_pick_up.wav" }
tentem colocar o som nesse plugin aki !
Código:
#include <amxmodx>
#include <fakemeta>
#include <zombieplague>
#define PLUGIN "[ZP] Dropar Ovos"
#define VERSION "1.0"
#define AUTHOR "Neukasano | Wilian | [P]erfec[T] [S]cr[@]s[H]"
new cvar_ap
new model[] = "models/Hwk/ZP2014/w_boladacopa_brazuka.mdl"
public plugin_precache()
{
precache_model(model)
}
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
register_event("HLTV", "event_round_start", "a", "1=0", "2=0")
register_forward(FM_Touch, "fwd_Touch")
register_event("DeathMsg","event_deathmsg","a")
cvar_ap = register_cvar("zp_give_ovo", "2")
}
public event_round_start()
{
new ent = FM_NULLENT
static string_class[] = "classname"
while ((ent = engfunc(EngFunc_FindEntityByString, ent, string_class, "ammo")))
set_pev(ent, pev_flags, FL_KILLME)
}
public fwd_Touch(toucher, touched)
{
if (!is_user_alive(toucher) || !pev_valid(touched))
return FMRES_IGNORED
new classname[32]
pev(touched, pev_classname, classname, 31)
if (!equal(classname, "ammo"))
return FMRES_IGNORED
zp_set_user_ammo_packs(toucher, zp_get_user_ammo_packs(toucher) + get_pcvar_num(cvar_ap))
client_printcolor(toucher, "!g[Hawk's GaMes]!y Voce pegou um!g ovo!y e Ganhou!g 2!y Ammo Pack(s).")
set_pev(touched, pev_effects, EF_NODRAW)
set_pev(touched, pev_solid, SOLID_NOT)
return FMRES_IGNORED
}
public event_deathmsg()
{
new origin[3]; get_user_origin(read_data(2) , origin)
addItem(origin)
}
public addItem(origin[3])
{
new ent = engfunc(EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, "info_target"))
set_pev(ent, pev_classname, "ammo")
engfunc(EngFunc_SetModel,ent, model)
set_pev(ent, pev_mins, Float:{-10.0,-10.0,0.0})
set_pev(ent, pev_maxs, Float:{10.0,10.0,25.0})
set_pev(ent, pev_size, Float:{-10.0,-10.0,0.0,10.0,10.0,25.0})
engfunc(EngFunc_SetSize, ent, Float:{-10.0,-10.0,0.0},Float:{10.0,10.0,25.0})
set_pev(ent, pev_solid, SOLID_BBOX)
set_pev(ent, pev_movetype, MOVETYPE_TOSS)
new Float:fOrigin[3]
ivecfvec(origin, fOrigin)
set_pev(ent, pev_origin, fOrigin)
set_pev(ent,pev_renderfx,kRenderFxGlowShell)
set_pev(ent,pev_rendercolor,Float:{255.0,0.0,0.0})
new Float:velocity[3];
pev(ent, pev_velocity, velocity);
velocity[2] = random_float(265.0,285.0);
set_pev(ent, pev_velocity, velocity)
}
stock ivecfvec(const IVec[3], Float:FVec[3])
{
FVec[0] = float(IVec[0]);
FVec[1] = float(IVec[1]);
FVec[2] = float(IVec[2]);
return 1;
}
stock client_printcolor(const id,const input[], any:...)
{
new msg[191], players[32], count = 1; vformat(msg,190,input,3);
replace_all(msg,190,"!g","^4"); // green
replace_all(msg,190,"!y","^1"); // normal
replace_all(msg,190,"!t","^3"); // team
if (id) players[0] = id; else get_players(players,count,"ch");
for (new i=0;i<count;i++)
{
if (is_user_connected(players[i]))
{
message_begin(MSG_ONE_UNRELIABLE,get_user_msgid("SayText"),_,players[i]);
write_byte(players[i]);
write_string(msg);
message_end();
}
}
}
tentem ai gente pf eu preciso desse som