Cars Command!
#24

Look This Is my Command

Код:
if (strcmp("/v", cmdtext, true, 10) == 0)
	{
	    if(PlayerInfo[playerid][Level] >= 0) {
	    new tmp[256], tmp2[256], tmp3[256], Index; tmp = strtok(params,Index), tmp2 = strtok(params,Index); tmp3 = strtok(params,Index);
	    if(!strlen(tmp)) return SendClientMessage(playerid, red, "USAGE: /car [Modelid/Name] [colour1] [colour2]");
		new car, colour1, colour2, 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");
		if(!strlen(tmp2)) colour1 = random(126); else colour1 = strval(tmp2);
		if(!strlen(tmp3)) colour2 = random(126); else colour2 = strval(tmp3);
		if(PlayerInfo[playerid][pCar] != -1 && !IsPlayerAdmin(playerid) ) CarDeleter(PlayerInfo[playerid][pCar]);
		new LVehicleID,Float:X,Float:Y,Float:Z, Float:Angle,int1;	GetPlayerPos(playerid, X,Y,Z);	GetPlayerFacingAngle(playerid,Angle);   int1 = GetPlayerInterior(playerid);
		LVehicleID = CreateVehicle(car, X+3,Y,Z, Angle, colour1, colour2, -1); LinkVehicleToInterior(LVehicleID,int1);
		PlayerInfo[playerid][pCar] = LVehicleID;
		CMDMessageToAdmins(playerid,"CAR");
		format(string, sizeof(string), "%s spawned a \"%s\" (Model:%d) colour (%d, %d), at %0.2f, %0.2f, %0.2f", pName(playerid), VehicleNames[car-400], car, colour1, colour2, X, Y, Z);
        SaveToFile("CarSpawns",string);
		format(string, sizeof(string), "You have spawned a \"%s\" (Model:%d) colour (%d, %d)", VehicleNames[car-400], car, colour1, colour2);
		return SendClientMessage(playerid,lightblue, string);
		{
And Thos are the errors

Код:
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(219) : warning 219: local variable "pName" shadows a variable at a preceding level
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(225) : error 017: undefined symbol "GetOnLinePlayers"
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(509) : error 017: undefined symbol "PlayerInfo"
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(509) : warning 215: expression has no effect
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(509) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(509) : error 029: invalid expression, assumed zero
C:\Documents and Settings\user\Desktop\server samp\gamemodes\Stunt.pwn(509) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


5 Errors.
Reply


Messages In This Thread
Cars Command! - by IvancheBG - 03.06.2011, 15:54
Re: Cars Command! - by ColdIce - 03.06.2011, 16:45
Re: Cars Command! - by IvancheBG - 03.06.2011, 17:29
Re: Cars Command! - by IvancheBG - 03.06.2011, 17:56
Re: Cars Command! - by Vince - 03.06.2011, 18:04
Re: Cars Command! - by Iphone1234g - 03.06.2011, 18:09
Re: Cars Command! - by IvancheBG - 04.06.2011, 05:13
Re: Cars Command! - by Converted - 04.06.2011, 08:17
Re: Cars Command! - by park4bmx - 04.06.2011, 09:11
Re: Cars Command! - by IvancheBG - 04.06.2011, 15:50
Re: Cars Command! - by park4bmx - 04.06.2011, 16:06
Re: Cars Command! - by IvancheBG - 04.06.2011, 16:09
Re: Cars Command! - by park4bmx - 04.06.2011, 16:20
Re: Cars Command! - by IvancheBG - 04.06.2011, 16:26
Re: Cars Command! - by Snowman12 - 04.06.2011, 16:28
Re: Cars Command! - by IvancheBG - 04.06.2011, 16:31
Re: Cars Command! - by IvancheBG - 04.06.2011, 16:38
Re: Cars Command! - by park4bmx - 04.06.2011, 16:52
Re: Cars Command! - by IvancheBG - 04.06.2011, 17:08
Re: Cars Command! - by IvancheBG - 04.06.2011, 19:02
AW: Cars Command! - by Julian12345 - 04.06.2011, 19:05
Re: Cars Command! - by IvancheBG - 04.06.2011, 19:17
AW: Cars Command! - by Julian12345 - 04.06.2011, 19:21
Re: Cars Command! - by IvancheBG - 05.06.2011, 02:56
Re: Cars Command! - by IvancheBG - 05.06.2011, 04:35
Re: AW: Cars Command! - by Aoi_Rikuto - 05.06.2011, 05:11
Re: Cars Command! - by IvancheBG - 05.06.2011, 05:12
Re: Cars Command! - by IvancheBG - 05.06.2011, 05:55
AW: Cars Command! - by Julian12345 - 05.06.2011, 09:37
Re: Cars Command! - by IvancheBG - 05.06.2011, 09:41
Re: Cars Command! - by Mean - 06.06.2011, 09:50
Re: Cars Command! - by IvancheBG - 06.06.2011, 15:47

Forum Jump:


Users browsing this thread: 1 Guest(s)