#include <amxmodx> // AMX Mod X
#include <amxmisc>
new czas = 45
new resety=3
new noze=0
new restart_title[1][] = {
"Frag-Game.pl" //SPAM
}
new misc[3][]={"misc/one.wav","misc/two.wav","misc/three.wav"}
new texty[3][]={"Jeden","Dwa","Trzy"}
public plugin_init()
{
register_plugin("ROund STart REstart","1.1","Edited by Miczu") //cos mi sie nalezy
set_task(5.0,"restart_odlicz", 0)
return PLUGIN_CONTINUE
}
public client_PreThink ( id )
{
if(noze) client_cmd(id,"weapon_knife")
}
public restart_odlicz(){
new players[32],num,num2
get_players(players,num,"ae","TERRORIST")
get_players(players,num2,"ae","CT")
if((num)&&(num2))
{
noze=1
set_task(5.0,"muza_on", 0)
set_task(1.0,"wyswietl_res",8188,"",0,"b")
}
else set_task(5.0,"restart_odlicz", 0)
}
public muza_on(){
client_cmd(0,"stopsound")
client_cmd(0,"mp3 play sound/misc/muza2")
}
public wyswietl_res(){
new jac1=random_num(0,255)
new jac2=random_num(0,255)
new jac3=random_num(0,255)
set_hudmessage(jac1, jac2, jac3, 0.65, 0.75, 2, 0.02, 1.0, 0.01, 0.1, 10)
show_hudmessage(0,"==================^n%s^n Restart za %i sec^n==================", restart_title, czas)
czas--
if(czas==0){
set_task(0.2,"restart_rundy_0", 0)
remove_task(8188)
}
}
public restart_rundy_play(){
set_hudmessage(10, 255, 40, -1.0, 0.30, 0, 6.0, 6.0, 0.5, 0.15, 4)
show_hudmessage(0,"Milego fragowania i dobrej zabawy !")
}
public restart_rundy(){
noze=0
client_cmd(0,"stopsound")
client_cmd(0,"mp3 play sound/misc/reset")
server_cmd("sv_restart 1")
set_task(2.0,"restart_rundy_play", 0)
}
public restart_rundy_0(){
set_hudmessage(10, 255, 40, -1.0, 0.30, 0, 6.0, 6.0, 0.5, 0.15, 4)
show_hudmessage(0,texty[resety-1])
client_cmd(0,"stopsound")
client_cmd(0,"spk %s",misc[resety-1])
resety--
if(resety==0) set_task(0.5,"restart_rundy", 0)
else set_task(1.5,"restart_rundy_0", 0)
}
public plugin_precache()
{
precache_generic("sound/misc/muza2.mp3")
precache_generic("sound/misc/reset.mp3")
precache_sound(misc[0])
precache_sound(misc[1])
precache_sound(misc[2])
return PLUGIN_CONTINUE
}
}
Użytkownik Kamyk345D edytował ten post 04.04.2012 22:22