Nao estou conseguindo compila a sma do ultimate sounds Obvio que eu fiz alguma coisa errada na sma alguem pode me ajudar a arruma esse erro ?
Última edição por gaah101 em 7/5/2014, 4:10 am, editado 1 vez(es)
SMA. :
/* Ultimtate KillStreak Advanced BETA */
#include
#include
#include
#define PLUGIN "Ultimate KillStreak Advanced BETA"
#define VERSION "0.7beta"
#define AUTHOR "SAMURAI"
new LEVELS
/*#define TASK_CLEAR_KILL 100
#define LEVELS 10
new kill[33][24];*/
new kills[33] = {0,...};
new deaths[33] = {0,...};
new hsenable, knifeenable, firstbloodenable, nadecvar, suicidecvar, cvardouble, rnstartcvar, killstreaktype;
new firstblood;
new hsmessages[][] =
{
"%s ^nRemoveu a cabeça de %s headShot !!",
"%s ^nUm lindo HeadShot em %s !",
"%s ^nFez um Lindo Headshot no %s!",
"%s ^nAcertou %s com um tiro na cabeca HeadShot !"
};
new hslist[][] =
{
"SorocabaCS_Misc/headshot1",
"SorocabaCS_Misc/headshot2"
};
new knmessages[][] =
{
"%s ^nFatiado e Picado %s",
"%s ^nPuxou da faca e Enfiou em %s",
"%s ^nEsfaqueado %s"
};
new knlist[][] =
{
"SorocabaCS_Misc/knife1",
"SorocabaCS_Misc/knife2"
};
new fbmessages[][] =
{
"%s : ^nFirst Blood !",
"%s ^nExtraiu o primeiro sangue!"
};
new fblist[][] =
{
"SorocabaCS_Misc/firstblood1",
"SorocabaCS_Misc/firstblood2"
};
new nademessages[][] =
{
"%s ^ntenho uma grande explosao de %s",
"%s ^nfez uma precisao para jogar %s",
"%s ^nGranadeiro e bom! eu acho que ele voltar da guerra ..."
};
new suicidemess[][] =
{
"%s ^nsabe como funciona o comando kill!",
"%s ^npreferem se matar ... em vez de morrer de HeadShot"
};
new suicidelist[][] =
{
"SorocabaCS_Misc/suicide1",
"SorocabaCS_Misc/suicide2",
"SorocabaCS_Misc/suicide3",
"SorocabaCS_Misc/suicide4"
};
/*new doublelist[][] =
{
"SorocabaCS_Misc/doublekill1",
"SorocabaCS_Misc/doublekill2"
};*/
new levels[10] = {3, 4, 6, 8, 10, 12,14,15,16,18};
new sounds[10][] =
{
"SorocabaCS_Misc/triplekill",
"SorocabaCS_Misc/multikill",
"SorocabaCS_Misc/ultrakill",
"SorocabaCS_Misc/killingspree",
"SorocabaCS_Misc/megakill",
"SorocabaCS_Misc/holyshit",
"SorocabaCS_Misc/ludicrouskill",
"SorocabaCS_Misc/rampage",
"SorocabaCS_Misc/unstoppable",
"SorocabaCS_Misc/monsterkill"
};
new messages[10][] =
{
"%s: ^n[Triple Kill] !",
"%s: ^n[Multi Kill!]",
"%s: ^n[Ultra Kill!]",
"%s: ^n[Killing Spree!]",
"%s: ^n[Mega Kill!]",
"%s: ^n[Holy Shit!]",
"%s: ^n[Ludicrous Kill!]",
"%s: ^n[Rampage!]",
"%s: ^n[Unstoppable!]",
"%s: ^n[MonsteRKiLL!]"
};
new preplist[][] =
{
"Evolution_MicStats/prepare1",
"Evolution_MicStats/prepare2",
"Evolution_MicStats/prepare3"
};
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
register_event("ResetHUD", "reset_hud", "b");
register_event("HLTV","rnstart","a", "1=0", "2=0");
killstreaktype = register_cvar("ut_killstreak_advanced", "3");
hsenable = register_cvar("ut_killstreak_hs","1");
knifeenable = register_cvar("ut_killstreak_knife","1");
firstbloodenable = register_cvar("ut_firstblood","1");
nadecvar = register_cvar("ut_nade_events","1");
suicidecvar = register_cvar("ut_suicide_events","1");
/*cvardouble = register_cvar("ut_doublekill_events","1");*/
rnstartcvar = register_cvar("ut_roundcout_sounds","1");
}
public client_death(killer,victim,weapon,hitplace,TK)
{
if(!killer || !victim)
return;
static kname[32], vname[32];
get_user_name(killer,kname,31);
get_user_name(victim,vname,31);
if(hitplace == HIT_HEAD && get_pcvar_num(hsenable) == 1 )
{
set_hudmessage(0, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, hsmessages[random(sizeof hsmessages)], kname, vname);
client_cmd(0,"spk %s",hslist[random(sizeof hslist)]);
}
if(weapon == CSW_KNIFE && get_pcvar_num(knifeenable) == 1 )
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, knmessages[random(sizeof knmessages)], kname, vname);
client_cmd(0,"spk %s",knlist[random(sizeof knlist)]);
}
if(firstblood && killer != victim && get_pcvar_num(firstbloodenable) ==1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, fbmessages[random(sizeof fbmessages)], kname);
client_cmd(0,"spk %s",fblist[random(sizeof fblist)]);
}
if(weapon == CSW_HEGRENADE && get_pcvar_num(nadecvar) == 1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0,nademessages[random(sizeof nademessages)],kname,vname);
client_cmd(0,"spk SorocabaCS_Misc/nade");
}
if(killer == victim && get_pcvar_num(suicidecvar) ==1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0,suicidemess[random(sizeof suicidemess)], vname);
client_cmd(0,"spk %s",suicidelist[random(sizeof suicidelist)]);
}
/*if(kill[killer][0] && equal(kill[killer],weapon) && killer != victim && get_pcvar_num(cvardouble) == 1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0,"Wow %s made a double kill", kname);
kill[killer][0] = 0;
client_cmd(0,"spk %s",doublelist[random(sizeof doublelist)]);
}
else
{
kill[killer] = weapon;
set_task(0.1,"clear_kill",TASK_CLEAR_KILL+killer);
}*/
kills[killer] += 1;
kills[victim] = 0;
deaths[killer] = 0;
deaths[victim] += 1;
for (new i = 0; i < LEVELS; i++)
{
if (kills[killer] == levels[i])
{
announce(killer, i);
return;
}
}
}
announce(killer, level)
{
static name[33];
new r = random(256);
new g = random(256);
new b = random(256);
get_user_name(killer, name, 32);
set_hudmessage(r,g,b, 0.05, 0.65, 2, 0.02, 6.0, 0.01, 0.1, 2);
if( (get_pcvar_num(killstreaktype) <= 0 ) || get_pcvar_num(killstreaktype) > 3)
return 0;
switch(get_pcvar_num(killstreaktype))
{
case 1:
{
show_hudmessage(0, messages[level], name);
return 0;
}
case 2:
{
client_cmd(0, "spk %s", sounds[level]);
return 0;
}
case 3:
{
show_hudmessage(0, messages[level], name);
client_cmd(0, "spk %s", sounds[level]);
return 0;
}
}
return 0;
}
public reset_hud(id)
{
firstblood = 1;
if (is_mode_set(16))
if (kills[id] > levels[0])
client_print(id, print_chat, "* You are on a killstreak with %d kills.", kills[id]);
else if (deaths[id] > 1)
client_print(id, print_chat, "* Take care, you are on a deathstreak with %d deaths in a row.", deaths[id]);
}
public rnstart(id)
{
if(get_pcvar_num(rnstartcvar) == 1)
{
firstblood = 1;
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, "[ FirsT Team ] ^nComecou o combate gogo");
client_cmd(0,"spk %s",preplist[random(sizeof preplist)]);
}
}
public client_connect(id)
{
kills[id] = 0;
deaths[id] = 0;
}
/*public clear_kill(taskid)
{
new id = taskid-TASK_CLEAR_KILL;
kill[id][0] = 0;
}*/
is_mode_set(bits)
{
new mode[9];
get_cvar_string("ut_killstreak_advanced", mode, ;
return read_flags(mode) & bits;
}
public plugin_precache()
{
precache_sound("SorocabaCS_Misc/triplekill.wav");
precache_sound("SorocabaCS_Misc/multikill.wav");
precache_sound("SorocabaCS_Misc/ultrakill.wav");
precache_sound("SorocabaCS_Misc/killingspree.wav");
precache_sound("SorocabaCS_Misc/megakill.wav");
precache_sound("SorocabaCS_Misc/holyshit.wav");
precache_sound("SorocabaCS_Misc/ludicrouskill.wav");
precache_sound("SorocabaCS_Misc/rampage.wav");
precache_sound("SorocabaCS_Misc/unstoppable.wav");
precache_sound("SorocabaCS_Misc/monsterkill.wav");
precache_sound("SorocabaCS_Misc/headshot1.wav");
precache_sound("SorocabaCS_Misc/headshot2.wav");
precache_sound("SorocabaCS_Misc/knife1.wav");
precache_sound("SorocabaCS_Misc/knife2.wav");
precache_sound("SorocabaCS_Misc/firstblood1.wav");
precache_sound("SorocabaCS_Misc/firstblood2.wav");
precache_sound("SorocabaCS_Misc/prepare1.wav");
precache_sound("SorocabaCS_Misc/prepare2.wav");
precache_sound("SorocabaCS_Misc/prepare3.wav");
precache_sound("SorocabaCS_Misc/nade.wav");
precache_sound("SorocabaCS_Misc/suicide1.wav");
precache_sound("SorocabaCS_Misc/suicide2.wav");
precache_sound("SorocabaCS_Misc/suicide3.wav");
precache_sound("SorocabaCS_Misc/suicide4.wav");
precache_sound("SorocabaCS_Misc/doublekill1.wav");
precache_sound("SorocabaCS_Misc/doublekill2.wav");
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/
#include
#include
#include
#define PLUGIN "Ultimate KillStreak Advanced BETA"
#define VERSION "0.7beta"
#define AUTHOR "SAMURAI"
new LEVELS
/*#define TASK_CLEAR_KILL 100
#define LEVELS 10
new kill[33][24];*/
new kills[33] = {0,...};
new deaths[33] = {0,...};
new hsenable, knifeenable, firstbloodenable, nadecvar, suicidecvar, cvardouble, rnstartcvar, killstreaktype;
new firstblood;
new hsmessages[][] =
{
"%s ^nRemoveu a cabeça de %s headShot !!",
"%s ^nUm lindo HeadShot em %s !",
"%s ^nFez um Lindo Headshot no %s!",
"%s ^nAcertou %s com um tiro na cabeca HeadShot !"
};
new hslist[][] =
{
"SorocabaCS_Misc/headshot1",
"SorocabaCS_Misc/headshot2"
};
new knmessages[][] =
{
"%s ^nFatiado e Picado %s",
"%s ^nPuxou da faca e Enfiou em %s",
"%s ^nEsfaqueado %s"
};
new knlist[][] =
{
"SorocabaCS_Misc/knife1",
"SorocabaCS_Misc/knife2"
};
new fbmessages[][] =
{
"%s : ^nFirst Blood !",
"%s ^nExtraiu o primeiro sangue!"
};
new fblist[][] =
{
"SorocabaCS_Misc/firstblood1",
"SorocabaCS_Misc/firstblood2"
};
new nademessages[][] =
{
"%s ^ntenho uma grande explosao de %s",
"%s ^nfez uma precisao para jogar %s",
"%s ^nGranadeiro e bom! eu acho que ele voltar da guerra ..."
};
new suicidemess[][] =
{
"%s ^nsabe como funciona o comando kill!",
"%s ^npreferem se matar ... em vez de morrer de HeadShot"
};
new suicidelist[][] =
{
"SorocabaCS_Misc/suicide1",
"SorocabaCS_Misc/suicide2",
"SorocabaCS_Misc/suicide3",
"SorocabaCS_Misc/suicide4"
};
/*new doublelist[][] =
{
"SorocabaCS_Misc/doublekill1",
"SorocabaCS_Misc/doublekill2"
};*/
new levels[10] = {3, 4, 6, 8, 10, 12,14,15,16,18};
new sounds[10][] =
{
"SorocabaCS_Misc/triplekill",
"SorocabaCS_Misc/multikill",
"SorocabaCS_Misc/ultrakill",
"SorocabaCS_Misc/killingspree",
"SorocabaCS_Misc/megakill",
"SorocabaCS_Misc/holyshit",
"SorocabaCS_Misc/ludicrouskill",
"SorocabaCS_Misc/rampage",
"SorocabaCS_Misc/unstoppable",
"SorocabaCS_Misc/monsterkill"
};
new messages[10][] =
{
"%s: ^n[Triple Kill] !",
"%s: ^n[Multi Kill!]",
"%s: ^n[Ultra Kill!]",
"%s: ^n[Killing Spree!]",
"%s: ^n[Mega Kill!]",
"%s: ^n[Holy Shit!]",
"%s: ^n[Ludicrous Kill!]",
"%s: ^n[Rampage!]",
"%s: ^n[Unstoppable!]",
"%s: ^n[MonsteRKiLL!]"
};
new preplist[][] =
{
"Evolution_MicStats/prepare1",
"Evolution_MicStats/prepare2",
"Evolution_MicStats/prepare3"
};
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
register_event("ResetHUD", "reset_hud", "b");
register_event("HLTV","rnstart","a", "1=0", "2=0");
killstreaktype = register_cvar("ut_killstreak_advanced", "3");
hsenable = register_cvar("ut_killstreak_hs","1");
knifeenable = register_cvar("ut_killstreak_knife","1");
firstbloodenable = register_cvar("ut_firstblood","1");
nadecvar = register_cvar("ut_nade_events","1");
suicidecvar = register_cvar("ut_suicide_events","1");
/*cvardouble = register_cvar("ut_doublekill_events","1");*/
rnstartcvar = register_cvar("ut_roundcout_sounds","1");
}
public client_death(killer,victim,weapon,hitplace,TK)
{
if(!killer || !victim)
return;
static kname[32], vname[32];
get_user_name(killer,kname,31);
get_user_name(victim,vname,31);
if(hitplace == HIT_HEAD && get_pcvar_num(hsenable) == 1 )
{
set_hudmessage(0, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, hsmessages[random(sizeof hsmessages)], kname, vname);
client_cmd(0,"spk %s",hslist[random(sizeof hslist)]);
}
if(weapon == CSW_KNIFE && get_pcvar_num(knifeenable) == 1 )
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, knmessages[random(sizeof knmessages)], kname, vname);
client_cmd(0,"spk %s",knlist[random(sizeof knlist)]);
}
if(firstblood && killer != victim && get_pcvar_num(firstbloodenable) ==1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, fbmessages[random(sizeof fbmessages)], kname);
client_cmd(0,"spk %s",fblist[random(sizeof fblist)]);
}
if(weapon == CSW_HEGRENADE && get_pcvar_num(nadecvar) == 1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0,nademessages[random(sizeof nademessages)],kname,vname);
client_cmd(0,"spk SorocabaCS_Misc/nade");
}
if(killer == victim && get_pcvar_num(suicidecvar) ==1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0,suicidemess[random(sizeof suicidemess)], vname);
client_cmd(0,"spk %s",suicidelist[random(sizeof suicidelist)]);
}
/*if(kill[killer][0] && equal(kill[killer],weapon) && killer != victim && get_pcvar_num(cvardouble) == 1)
{
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0,"Wow %s made a double kill", kname);
kill[killer][0] = 0;
client_cmd(0,"spk %s",doublelist[random(sizeof doublelist)]);
}
else
{
kill[killer] = weapon;
set_task(0.1,"clear_kill",TASK_CLEAR_KILL+killer);
}*/
kills[killer] += 1;
kills[victim] = 0;
deaths[killer] = 0;
deaths[victim] += 1;
for (new i = 0; i < LEVELS; i++)
{
if (kills[killer] == levels[i])
{
announce(killer, i);
return;
}
}
}
announce(killer, level)
{
static name[33];
new r = random(256);
new g = random(256);
new b = random(256);
get_user_name(killer, name, 32);
set_hudmessage(r,g,b, 0.05, 0.65, 2, 0.02, 6.0, 0.01, 0.1, 2);
if( (get_pcvar_num(killstreaktype) <= 0 ) || get_pcvar_num(killstreaktype) > 3)
return 0;
switch(get_pcvar_num(killstreaktype))
{
case 1:
{
show_hudmessage(0, messages[level], name);
return 0;
}
case 2:
{
client_cmd(0, "spk %s", sounds[level]);
return 0;
}
case 3:
{
show_hudmessage(0, messages[level], name);
client_cmd(0, "spk %s", sounds[level]);
return 0;
}
}
return 0;
}
public reset_hud(id)
{
firstblood = 1;
if (is_mode_set(16))
if (kills[id] > levels[0])
client_print(id, print_chat, "* You are on a killstreak with %d kills.", kills[id]);
else if (deaths[id] > 1)
client_print(id, print_chat, "* Take care, you are on a deathstreak with %d deaths in a row.", deaths[id]);
}
public rnstart(id)
{
if(get_pcvar_num(rnstartcvar) == 1)
{
firstblood = 1;
set_hudmessage(255, 0, 255, -1.0, 0.30, 0, 6.0, 6.0);
show_hudmessage(0, "[ FirsT Team ] ^nComecou o combate gogo");
client_cmd(0,"spk %s",preplist[random(sizeof preplist)]);
}
}
public client_connect(id)
{
kills[id] = 0;
deaths[id] = 0;
}
/*public clear_kill(taskid)
{
new id = taskid-TASK_CLEAR_KILL;
kill[id][0] = 0;
}*/
is_mode_set(bits)
{
new mode[9];
get_cvar_string("ut_killstreak_advanced", mode, ;
return read_flags(mode) & bits;
}
public plugin_precache()
{
precache_sound("SorocabaCS_Misc/triplekill.wav");
precache_sound("SorocabaCS_Misc/multikill.wav");
precache_sound("SorocabaCS_Misc/ultrakill.wav");
precache_sound("SorocabaCS_Misc/killingspree.wav");
precache_sound("SorocabaCS_Misc/megakill.wav");
precache_sound("SorocabaCS_Misc/holyshit.wav");
precache_sound("SorocabaCS_Misc/ludicrouskill.wav");
precache_sound("SorocabaCS_Misc/rampage.wav");
precache_sound("SorocabaCS_Misc/unstoppable.wav");
precache_sound("SorocabaCS_Misc/monsterkill.wav");
precache_sound("SorocabaCS_Misc/headshot1.wav");
precache_sound("SorocabaCS_Misc/headshot2.wav");
precache_sound("SorocabaCS_Misc/knife1.wav");
precache_sound("SorocabaCS_Misc/knife2.wav");
precache_sound("SorocabaCS_Misc/firstblood1.wav");
precache_sound("SorocabaCS_Misc/firstblood2.wav");
precache_sound("SorocabaCS_Misc/prepare1.wav");
precache_sound("SorocabaCS_Misc/prepare2.wav");
precache_sound("SorocabaCS_Misc/prepare3.wav");
precache_sound("SorocabaCS_Misc/nade.wav");
precache_sound("SorocabaCS_Misc/suicide1.wav");
precache_sound("SorocabaCS_Misc/suicide2.wav");
precache_sound("SorocabaCS_Misc/suicide3.wav");
precache_sound("SorocabaCS_Misc/suicide4.wav");
precache_sound("SorocabaCS_Misc/doublekill1.wav");
precache_sound("SorocabaCS_Misc/doublekill2.wav");
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/
Última edição por gaah101 em 7/5/2014, 4:10 am, editado 1 vez(es)