public fala_odepch(id)
{
if(ilosc_fal[id] == 0 || !is_user_alive(id))
return PLUGIN_CONTINUE
ilosc_fal[id]--;
new origin[3], dist = 350
get_user_origin(id, origin)
emit_sound(id, CHAN_STATIC, "diablo/warcry.wav", 1.0, ATTN_NORM, 0, PITCH_NORM)
message_begin( MSG_BROADCAST, SVC_TEMPENTITY, origin )
write_byte(TE_BEAMCYLINDER)
write_coord( origin[0])
write_coord( origin[1])
write_coord( origin[2])
write_coord( origin[0])
write_coord( origin[1])
write_coord( origin[2] + dist)
write_short( sprite_white )
write_byte( 0 ) // startframe
write_byte( 0 ) // framerate
write_byte( 6 ) // life
write_byte( 80 ) // width
write_byte( 0 ) // noise
write_byte( 0 ) //kolor rgb
write_byte( 255 ) //kolor rgb
write_byte( 255 ) //kolor rgb
write_byte( 255 ) //brightness
write_byte( 0 ) // speed
message_end()
new entlist[33], Float:forigin[3]
IVecFVec( origin, forigin );
new numfound = find_sphere_class(id,"player", float(dist),entlist, 32,forigin);
for (new i=0; i < numfound; i++)
{
new pid = entlist[i]
if (pid == id || !is_user_alive(pid))
continue
if (get_user_team(id) == get_user_team(pid))
continue
new vOrigin[3];
new Float:gfOrigin[2][3], b;
entity_get_vector(pid, EV_VEC_origin, gfOrigin[1]);
entity_get_vector(0, EV_VEC_origin, gfOrigin[0]);
get_user_origin(pid, vOrigin); ///
for(b = 0; b <= 2; b ++)
{
gfOrigin[1][b] -= gfOrigin[0][b];
gfOrigin[1][b] +=30;
gfOrigin[1][b] *=7+player_intelligence[id]/25;
}
entity_set_vector(pid, EV_VEC_velocity, gfOrigin[1]);
change_health(pid,-40,id,"")
message_begin(MSG_BROADCAST,SVC_TEMPENTITY);
write_byte(0);
write_coord(origin[0]);
write_coord(origin[1]);
write_coord(origin[2]);
write_coord(vOrigin[0]);
write_coord(vOrigin[1]);
write_coord(vOrigin[2]);
write_short(sprite_lgt);
write_byte(1);
write_byte(5);
write_byte(2);
write_byte(20);
write_byte(30);
write_byte(200);
write_byte(200);
write_byte(200);
write_byte(200);
write_byte(200);
message_end();
}
return PLUGIN_HANDLED;
}