Mam problem. czy mógłby ktoś dodać ten action do tego bm'a żeby działał ? razem z menu
ActionBron(id, ent)
{
set_hudmessage(0, 255, 0, 0.01, 0.18, 0, 0.0, 1.0, 0.25, 0.25, 2);
if (cs_get_user_team(id) == CS_TEAM_CT)
{
show_hudmessage(id, "Nie mozesz brac broni bedąc w CT");
return PLUGIN_HANDLED;
}
static property[5];
GetProperty(ent, 1, property);
static property2[5];
GetProperty(ent, 2, property2);
new numer = str_to_num(property);
new szWeapon[32];
format(szWeapon, 31, "weapon_%s", g_bronie[numer]);
new iWeapons[32], iNum;
if(!WzialBron[id][numer])
{
if(!(get_user_weapons(id, iWeapons, iNum) & (1<<get_weaponid(szWeapon))))
{
give_item(id, szWeapon);
new ammo = str_to_num(property2);
cs_set_weapon_ammo(find_ent_by_owner(-1, szWeapon, id), ammo);
BCM_Print(id, "Dostales Bron:^4 %s^3 z^4 %i^3 naboj%s", g_bronie[numer], ammo, ammo == 1 ? "em" : "ami");
WzialBron[id][numer] = true;
}
}
else
show_hudmessage(id, "Juz raz wziales %s!", g_bronie[numer]);
return PLUGIN_HANDLED;
}
Załączone pliki
Użytkownik GabrieL edytował ten post 27.12.2012 00:27