SA-MP Forums Archive
Give a car - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Give a car (/showthread.php?tid=130922)



Give a car - 02manchestera - 28.02.2010

How do i go by make a command give a car so i do /sultan gives me a sultan or /nrg gives me a nrg-500

Manythanks.


Re: Give a car - RyDeR` - 28.02.2010

Use CreateVehicle


Re: Give a car - 02manchestera - 28.02.2010

so it will be something like

Код:
if(!strcmp(cmdtext, "/rally1", true))
		{

			Createvehicle,id 560;
			return 1;



Re: Give a car - qwt - 28.02.2010

Quote:
Originally Posted by 02manchestera
so it will be something like

Код:
if(!strcmp(cmdtext, "/rally1", true))
		{

			Createvehicle,id 560;
			return 1;
pawn Код:
if(!strcmp(cmdtext, "/rally1", true))
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X,Y,Z);
CreateVehicle(560, X,Y,Z,0.0,1,1,respawntime(miliseconds));
return 1;
}



Re: Give a car - 02manchestera - 28.02.2010

Код:
C:\Program Files\Rockstar Games\GTA San Andreas\my server\gamemodes\mad-dog.pwn(38) : error 017: undefined symbol "respawntime"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
Thankyou so far


Re: Give a car - qwt - 28.02.2010

Quote:
Originally Posted by 02manchestera
Код:
C:\Program Files\Rockstar Games\GTA San Andreas\my server\gamemodes\mad-dog.pwn(38) : error 017: undefined symbol "respawntime"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
Thankyou so far
Put the respawn time, like 60000.


Re: Give a car - 02manchestera - 28.02.2010

Код:
if(!strcmp(cmdtext, "/sultan", true))
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X,Y,Z);
CreateVehicle(560, X,Y,Z,0.0,1,1,respawntime(60000));
return 1;
}
Still getting same error any ideas

edited-- sorted it