Witam , mój problem polega na wywołaniu pewnej funkcji przy pomocy drugiej. Otóż kod wygląda następująco:
RegisterHam(Ham_TakeDamage, "player", "GraczGracz", 1);
public GraczGracz(id, idinflictor, idattacker, Float:damage, damagebits) { new data[1]; data[0]=id; new name[32]; get_user_name(idattacker, name, 31); new knife = get_user_weapon(idattacker); if ( (cs_get_user_team(idattacker) == CS_TEAM_CT) || ( is_user_alive(id) )) { switch ( knife ) { case CSW_KNIFE: { set_task(1.0, "BlokGracz", .parameter=data, .len=1); } } } return PLUGIN_CONTINUE; }
public BlokGracz(ent, data[1]) { new id=data[0]; if ( !( 1 <= id <= g_max_players ) || !g_alive[id] || !IsKlocek(ent) ) return PLUGIN_CONTINUE; new blok = pev(ent, pev_body); new flags = pev(id, pev_flags); new groundentity = pev(id, pev_groundentity); if ( ( flags & FL_ONGROUND ) && groundentity == ent ) { switch ( blok ) { case klocek: client_Print(0, print_chat, "Cos Tam"); } } return PLUGIN_CONTINUE; }
Proszę o szybką pomoc i wyjaśnienie z góry Dziękuje i Pozdrawiam.