r4mzya |
Дата: Воскресенье, 02.07.2017, 17:12 | Сообщение # 1
|
Новичок
Сообщений: 1
Статус: Offline
|
Когда я показываю паспорт, он показывается не мне, а другому игроку. Вот код
Код else if(strcmp(cmd,"/showpass",true) == 0 || strcmp(cmd,"/pass",true) == 0) { tmp = strcharsplit(cmdtext, idx); if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_WHITE, "Ââåäèòå: /showpass [id] èëè /pass [id]"); giveplayerid = ReturnUser(tmp); if(!IsPlayerConnected(giveplayerid)) return SendClientMessage(playerid, COLOR_RED, "[Îøèáêà] ×åëîâåê íå íàéäåí!"); { if(giveplayerid != INVALID_PLAYER_ID) { if (!ProxDetectorS(8.0, playerid, giveplayerid)) return SendClientMessage(playerid, COLOR_RED, "×åëîâåê ñëèøêîì äàëåêî!"); { new ttext[32]; switch(PlayerInfo[playerid][pMember]) { case 1: { ttext = "LSPD"; } case 2: { ttext = "FBI"; } case 3: { ttext = "Army SF"; } case 4: { ttext = "Ìèí.Çäðàâ"; } case 5: { ttext = "La Cosa Nostra"; } case 6: { ttext = "Yakuza"; } case 7: { ttext = "Ìýðèÿ"; } case 8: { ttext = "Casino"; } case 10: { ttext = "SFPD"; } case 11: { ttext = "Èíñòðóêòîðû"; } case 12: { ttext = "Ballas Gang"; } case 13: { ttext = "Vagos Gang"; } case 14: { ttext = "Russian Mafia"; } case 15: { ttext = "Grove Street Gang"; } case 16: { ttext = "San News"; } case 17: { ttext = "Aztecas Gang"; } case 18: { ttext = "Rifa Gang"; } case 19: { ttext = "Army LV"; } case 21: { ttext = "LVPD"; } case 23: { ttext = "Hitmans"; } case 24: { ttext = "Street Racers"; } case 25: { ttext = "S.W.A.T"; } case 26: { ttext = "Ïðàâèòåëüñòâî"; } default: { ttext = "Ãðàæäàíèí"; } } new jtext[32]; switch(PlayerInfo[playerid][pJob]) { case 2: { jtext = "Ìåõàíèê"; } case 3: { jtext = "Ïðîäàâåö ÕîòÄîãîâ"; } case 4: { jtext = "Òàêñèñò"; } case 5: { jtext = "Ðàçâîç÷èê ïðîäóêòîâ"; } case 6: { jtext = "Òðåíåð"; } case 7: { jtext = "Íåèçâåñòíî"; } case 8: { jtext = "Èíêàñàòîð"; } case 9: { jtext = "Íåèçâåñòíî"; } case 10: { jtext = "Ìóñîðîâîç"; } case 13: { jtext = "Àâòîóãîíùèê"; } case 14: { jtext = "Áîêñ¸ð"; } case 15: { jtext = "Ìåñòíûé DJ"; } default: { jtext = "Áåçðàáîòíûé"; } } new shltext[32]; if(PlayerInfo[playerid][pGunLic]) { shltext = "Åñòü"; } else { shltext = "Íåò"; } new level = PlayerInfo[playerid][pLevel]; format(stringer, sizeof(stringer), "{00CED1}Èìÿ: {FFFFFF}%s\n{00CED1}Âîçðàñò: {FFFFFF}%d\n{00CED1}Òåëåôîí: {FFFFFF}%d\n{00CED1}Ôðàêöèÿ: {FFFFFF}%s\n{00CED1}Ðàáîòà: {FFFFFF}%s\n{00CED1}Ðàçðåøåíèå íà îðóæèå: {FFFFFF}%s\n{00CED1}Ïðåñòóïëåíèé: {FFFFFF}%d\n{00CED1}Çàêîíîïîñëóøíîñòü: {FFFFFF}%d", PlayerInfo[playerid][pNames],level,PlayerInfo[playerid][pPnumber],ttext,jtext,shltext,PlayerInfo[playerid][pKills],PlayerInfo[playerid][pZakonp]); SPD(playerid,156,DIALOG_STYLE_MSGBOX,"Passport",stringer,"Âûõîä",""); /*SendClientMessage(playerid,COLOR_GREY, "-----------===[ PASSPORT ]===----------"); SendMes(giveplayerid, COLOR_YELLOW2, "Èìÿ: %s ",PlayerInfo[playerid][pNames]); SendMes(giveplayerid, COLOR_YELLOW2, "Âîçðàñò: %d Òåëåôîí: %d",level,PlayerInfo[playerid][pPnumber]); SendMes(giveplayerid, COLOR_YELLOW2, "Ôðàêöèÿ: %s",ttext); SendMes(giveplayerid, COLOR_YELLOW2, "Ðàáîòà: %s Ðàçðåøåíèå íà îðóæèå: %s",jtext,shltext); SendMes(giveplayerid, COLOR_YELLOW2, "Ïðåñòóïëåíèé: %d",PlayerInfo[playerid][pKills]); SendMes(giveplayerid, COLOR_YELLOW2, "Çàêîíîïîñëóøíîñòü: %d",PlayerInfo[playerid][pZakonp]); SendClientMessage(playerid,COLOR_GREY, "=============================");*/ if(PlayerInfo[playerid][pWanted] > 0) SendClientMessage(giveplayerid, COLOR_REDD, "Âíèìàíèå! Ýòî ÷åëîâåê â ðîçûñêå!"); SendClientMessage(giveplayerid, COLOR_YELLOW, stringer); format(stringer,sizeof(stringer), "%s ïîêàçàë(à) ñâîé ïàñïîðò %s'ó", PlayerInfo[playerid][pNames], PlayerInfo[giveplayerid][pNames]); SetPlayerChatBubble(playerid,stringer,COLOR_PURPLE,30.0,10000); format(stringer, sizeof(stringer), "%s ïîêàçàë(a) ñâîé ïàñïîðò", PlayerInfo[playerid][pNames]); ProxDetector(10.0, playerid, stringer, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); } } } return true; }
|
|
|
|
=) |
Дата: Воскресенье, 02.07.2017, 20:39 | Сообщение # 2
|
Боец
Сообщений: 271
Статус: Offline
|
Он должен показываться тебе только в том случае, если ты укажешь свой ID. У тебя половина показывается тебе, половина другому игроку. Отредактируй нормально.
playerid - твой айди. giveplayerid - айди того, кому показываешь.
|
|
|
|