Vehicle Group Spawner command
#1

Код:
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15361) : error 001: expected token: ";", but found ")"
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15361) : error 029: invalid expression, assumed zero
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15361) : warning 215: expression has no effect
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Код:
CMD:ecar(playerid,params[])  {
	if(PlayerInfo[playerid][Level] >= 1) {
 (error)	new tmp[128], Index; tmp = strtok(params,Index));
  	if(isnull(tmp)) return SendClientMessage(playerid, red, "USAGE: /car [Modelid/Name]");
	new car, string[128];
	if(!IsNumeric(tmp)) car = GetVehicleModelIDFromName(tmp); else car = strval(tmp);
	if(car < 400 || car > 611) return  SendClientMessage(playerid, red, "ERROR: Invalid Vehicle Model");
	new LVehicleID,Float:X,Float:Y,Float:Z,Float:Angle;
	GetPlayerPos(playerid, X,Y,Z);
	GetPlayerFacingAngle(playerid,Angle);
	LVehicleID = CreateVehicle(car, X+3,Y,Z, Angle, -1, -1, -1);
	LVehicleID = CreateVehicle(car, X+3,Y,Z, Angle, -1, -1, -1);
	LVehicleID = CreateVehicle(car, X+3,Y,Z, Angle, -1, -1, -1);
	format(string, sizeof(string), "%s spawned a \"%s\" (Model:%d), at %0.2f, %0.2f, %0.2f", pName(playerid), VehicleNames[car-400], car, X, Y, Z);
 	SaveToFile("CarSpawns",string);
	format(string, sizeof(string), "You have spawned a \"%s\" (Model:%d)", VehicleNames[car-400], car);
	CMDMessageToAdmins(playerid,"CAR");
	VehicleInfo[LVehicleID][Temp] = 1;
	return SendClientMessage(playerid,blue, string);
	} else return SendClientMessage(playerid,red,"ERROR: You need to be level 2 to use this command");
}
Reply
#2

Anyone help about this command?
Reply
#3

Which line is 15361
Reply
#4

change
PHP код:
new tmp[128], Indextmp strtok(params,Index)); 
to
PHP код:
new tmp[128], Index;
tmp strtok(params,Index); 
Reply
#5

Код:
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15317) : error 001: expected token: ";", but found ")"
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15317) : error 029: invalid expression, assumed zero
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15317) : warning 215: expression has no effect
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Reply
#6

Quote:
Originally Posted by tbedy
Посмотреть сообщение
Код:
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15317) : error 001: expected token: ";", but found ")"
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15317) : error 029: invalid expression, assumed zero
C:\Users\Toni\Desktop\aaaaaaaaaaa\gamemodes\ALRPDM.pwn(15317) : warning 215: expression has no effect
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Come on man i'm not a fortune teller, can you show the line where the error happen?
Reply
#7

What about using sscang mate, instead of tmp and srttok shit
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)