/truckfrisk help - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: /truckfrisk help (
/showthread.php?tid=408564)
/truckfrisk help -
kepa333 - 18.01.2013
Hello there can any one fix it?
ERROR:
Код HTML:
(63692) : warning 202: number of arguments does not match definition
Код:
if (strcmp(cmd, "/frisktruck", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 12 || PlayerInfo[playerid][pMember] == 12 || IsAFreecop(playerid))
{
for(new car=0; car<MAX_VEHICLES; car++)
{
new Float: X, Float: Y, Float: Z;
GetPlayerPos(playerid, X, Y, Z);
new vehicle;
vehicle = GetPlayerVehicleID(car);
if(IsPlayerInRangeOfPoint(car, 3.5, X, Y, Z))
{
|63692| SendClientMessage(playerid,COLOR_GRAD1,"Heroin: %d/100!",CarInfo[vehicle][Heroin]);
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " There is no truck near you.");
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " You are not an Law");
}
}
return 1;
}
Re: /truckfrisk help -
Infinity90 - 18.01.2013
pawn Код:
if (strcmp(cmd, "/frisktruck", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 12 || PlayerInfo[playerid][pMember] == 12 || IsAFreecop(playerid))
{
for(new car=0; car<MAX_VEHICLES; car++)
{
new Float: X, Float: Y, Float: Z, stringx[128];
GetPlayerPos(playerid, X, Y, Z);
new vehicle;
vehicle = GetPlayerVehicleID(car);
if(IsPlayerInRangeOfPoint(car, 3.5, X, Y, Z))
{
format(stringx,sizeof(stringx),"Heroin: %d/100!",CarInfo[vehicle][Heroin]);
SendClientMessage(playerid,COLOR_GRAD1,stringx);
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " There is no truck near you.");
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " You are not an Law");
}
}
return 1;
}
Re: /truckfrisk help -
Infinity90 - 18.01.2013
It's strange how you used the exact same string (stringx) as me. -_- Anyways I cba to argue over something silly.
@Kepa333 did it work?
Re : /truckfrisk help -
kepa333 - 18.01.2013
it works... ty