Mój problem jest taki: Gdy wywołuję funkcję EfektRadar(id, pid) - o niej poniżej, w konsoli serwera wyskakuje
Host_Error: WriteDest_Parm: not a client. Wiem, że nie znajduje klienta przy tej funkcji, zatem prośba oczywista - o naprawienie tego buga
Funkcja EfektRadar(id, pid) jest wywoływana przez funkcję:
public RadarOdBytu(ent) { new id = entity_get_edict(ent, EV_ENT_owner); if (entity_get_edict(ent, EV_ENT_euser2) == 1) { new Float:forigin[3], origin[3]; entity_get_vector(ent, EV_VEC_origin, forigin); FVecIVec(forigin,origin); new entlist[33]; new numfound = find_sphere_class(0,"player",200+0.0,entlist, 32,forigin); for (new i=0; i < numfound; i++) { new pid = entlist[i]; if (get_user_team(pid) != get_user_team(id) && is_user_alive(pid)) EfektRadarCzujnik(i, pid); } } }
A sama funkcja wygląda następująco:
public EfektRadar(id, pid) { new pozycja_wroga[33][3]; if (!is_user_connected(pid)) return PLUGIN_CONTINUE; get_user_origin(pid, pozycja_wroga[pid]); message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("HostagePos"), {0,0,0}, id); write_byte(id); write_byte(pid); write_coord(pozycja_wroga[pid][0]); write_coord(pozycja_wroga[pid][1]); write_coord(pozycja_wroga[pid][2]); message_end(); message_begin(MSG_ONE_UNRELIABLE, get_user_msgid("HostageK"), {0,0,0}, id); write_byte(pid); message_end(); return PLUGIN_CONTINUE; }
Z GÓRY WIELKIE DZIĘKI!