Frakcje mam takie że dodaje w cod_frakcje.ini
a dla każdej klasy osobne amxx[klasa]Agent[frakcja]Polacy
Oto mój kod SMA:
#include <amxmodx> #include <amxmisc> #include <codmod> #include <fakemeta> #include <fun> new const nazwa[] = "Agent"; new const opis[] = "uzi 160 hp 50 kond. ubranie wroga"; new const bronie = (1<<CSW_HEGRENADE)|(1<<CSW_MAC10)|(1<<CSW_SMOKEGRENADE)|(1<<CSW_FLASHBANG); new const zdrowie = 160; new const kondycja = 50; new const inteligencja = 0; new const wytrzymalosc = 10; new skoki[33]; new ma_klase[33]; new Ubrania_CT[4][]={"sas","gsg9","urban","gign"}; new Ubrania_Terro[4][]={"arctic","leet","guerilla","terror"}; public plugin_init() { register_plugin(nazwa, "1.0", "amxx.pl"); cod_register_class(nazwa, opis, bronie, zdrowie, kondycja, inteligencja, wytrzymalosc); register_forward(FM_CmdStart, "fwCmdStart_MultiJump"); } public ZmienUbranie(id,reset) { if (id<1 || id>32 || !is_user_connected(id)) return PLUGIN_CONTINUE; if (reset) cs_reset_user_model(id); else { new num = random_num(0,3); switch(get_user_team(id)) { case 1: cs_set_user_model(id, Ubrania_CT[num]); case 2:cs_set_user_model(id, Ubrania_Terro[num]); } } return PLUGIN_CONTINUE; } public cod_class_enabled(id) { give_item(id, "weapon_hegrenade"); give_item(id, "weapon_flashbang"); give_item(id, "weapon_flashbang"); give_item(id, "weapon_smokegrenade"); ZmienUbranie(id, 0); ma_klase[id] = true; } public cod_class_disabled(id) { ma_klase[id] = false; } public fwCmdStart_MultiJump(id, uc_handle) { if(!is_user_alive(id) || !ma_klase[id]) return FMRES_IGNORED; new flags = pev(id, pev_flags); if((get_uc(uc_handle, UC_Buttons) & IN_JUMP) && !(flags & FL_ONGROUND) && !(pev(id, pev_oldbuttons) & IN_JUMP) && skoki[id]) { skoki[id]--; new Float:velocity[3]; pev(id, pev_velocity,velocity); velocity[2] = random_float(265.0,285.0); set_pev(id, pev_velocity,velocity); } else if(flags & FL_ONGROUND) skoki[id] = 1; return FMRES_IGNORED; }Chciałbym się dowiedzieć co jest źle i jak to naprawić/ zrobić
Użytkownik ozoku edytował ten post 21.11.2011 21:02