Need help with Specting vehicle !
#1

Hello guys


Code:
Quote:

if(!strcmp(cmd, "/speccar", true) || !strcmp(cmd, "/carspec", true))
{
if(userdata[playerid][userowncar] == 0 && userdata[playerid][userowncar2] == 0 && userdata[playerid][userowncar3] == 0 && userdata[playerid][userowncar4] == 0) return SendClientMessage(playerid,COLOR_KRED,"ERROR: айп ббтмеък шлбйн");
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) return SendClientMessage(playerid, -1, "USAGE: /SpecCar [1-3]");


if(!strcmp(tmp, "1", true))
{
if(userdata[playerid][userowncar] == 0) return SendClientMessage(playerid,COLOR_KRED,"! шлб жд ма ббтмеък");
TogglePlayerSpectating(playerid, 1);
PlayerSpectateVehicle(playerid, vehdata[strval(tmp)][syscarid]);
ShowPlayerDialog(playerid, 66, DIALOG_STYLE_MSGBOX, "{FF9900}Car Spectate", "{FFFFFF}! лтъ аъд цефд бшлбк дшащеп\n{FF9900}/SpecOff{FFFFFF} - тм оръ мцаъ ооцб жд шщен", "Close", "");
InCSpec[playerid] = 1;
}

if(!strcmp(tmp, "2", true))
{
if(userdata[playerid][userowncar2] == 0) return SendClientMessage(playerid,COLOR_KRED,"! шлб жд ма ббтмеък");
TogglePlayerSpectating(playerid, 1);
PlayerSpectateVehicle(playerid, vehdata[strval(tmp)][syscarid]);
ShowPlayerDialog(playerid, 66, DIALOG_STYLE_MSGBOX, "{FF9900}Car Spectate", "{FFFFFF}! лтъ аъд цефд бшлбк дщрй\n{FF9900}/SpecOff{FFFFFF} - тм оръ мцаъ ооцб жд шщен", "Close", "");
InCSpec[playerid] = 1;
}

if(!strcmp(tmp, "3", true))
{
if(userdata[playerid][userowncar3] == 0) return SendClientMessage(playerid,COLOR_KRED,"! шлб жд ма ббтмеък");
TogglePlayerSpectating(playerid, 1);
PlayerSpectateVehicle(playerid, vehdata[strval(tmp)][syscarid]);
ShowPlayerDialog(playerid, 66, DIALOG_STYLE_MSGBOX, "{FF9900}Car Spectate", "{FFFFFF}! лтъ аъд цефд бшлбк дщмйщй\n{FF9900}/SpecOff{FFFFFF} - тм оръ мцаъ ооцб жд шщен", "Close", "");
InCSpec[playerid] = 1;
}

return 1;
}

Well, the problem is, when I am using /SpecCar for example /SpecCar 1 - It will let me to spec different player's vehicle instead mine. another example - My ign is: SaMuRy. and there are an user that called "StorNN".
And when I am using /SpecCar 1 (There are 3 slots for vehicles). as I said "You are watching StroNN Vehicle (#1)" Instead: You're watching SaMuRy Vehicle (#1).
You guys maybe figured out
Reply


Messages In This Thread
Need help with Specting vehicle ! - by SaMuRy - 21.09.2018, 19:11

Forum Jump:


Users browsing this thread: 1 Guest(s)