Trzymaj sma:
/* Plugin generated by AMXX-Studio */
#include <amxmodx>
#include <codmod>
#include <fakemeta>
new const nazwa[] = "Stagger";
new const opis[] = "Ma Famasa i pelen magazynak za kazde zabojstwo";
new const bronie = 1<<CSW_FAMAS | 1<<CSW_DEAGLE;
new const zdrowie = 10;
new const kondycja = 20;
new const inteligencja = 0;
new const wytrzymalosc = 20;
new bool:ma_klase[33];
new const maxClip[31] = { -1, 13, -1, 10, 1, 7, 1, 30, 30, 1, 30, 20, 25, 30, 35, 25, 12, 20,
10, 30, 100, 8, 30, 30, 20, 2, 7, 30, 30, -1, 50 };
public plugin_init()
{
register_plugin(nazwa, "1.0", "QTM_Peyote");
cod_register_class(nazwa, opis, bronie, zdrowie, kondycja, inteligencja, wytrzymalosc);
register_event("DeathMsg", "DeathMsg", "ade");
}
public cod_class_enabled(id)
ma_klase[id] = true;
public cod_class_disabled(id)
ma_klase[id] = false;
public DeathMsg()
{
new killer = read_data(1);
if(!is_user_connected(killer))
return PLUGIN_CONTINUE;
if(ma_klase[killer])
{
new weapon = get_user_weapon(killer);
if(maxClip[weapon] != -1)
set_user_clip(killer, maxClip[weapon]);
}
return PLUGIN_CONTINUE;
}
stock set_user_clip(id, ammo)
{
new weaponname[32], weaponid = -1, weapon = get_user_weapon(id, _, _);
get_weaponname(weapon, weaponname, 31);
while ((weaponid = engfunc(EngFunc_FindEntityByString, weaponid, "classname", weaponname)) != 0)
if (pev(weaponid, pev_owner) == id) {
set_pdata_int(weaponid, 51, ammo, 4);
return weaponid;
}
return 0;
}
Trzymaj
amxx -
http://amxx.pl/kompi...ass_stagger.sma