/carlocate
#1

Hello fellow SA-MP Scripter !
As you probably all know, the /carlocate part of the RP GMs is always green (/*)
Which means that you can't do /carlocate or /v locate as i know it. Because it causes like 26 errors.
"Setplayerto" or some shit like that.
Anyone could make one like /carlocate, just fixed?
Код:
	/*if(strcmp(cmd, "/carlocate", true) == 0)
	{
	  if(IsPlayerConnected(playerid))
		{
			if(PlayerInfo[playerid][pPcarkey] != 999)
			{
			  if(PlayerInfo[playerid][pPnumber] != 0)
			  {
			    if(gPlayerCheckPointStatus[playerid] != CHECKPOINT_CAR)
			    {
						SetPlayerSpecialAction(playerid, SPECIAL_ACTION_USECELLPHONE);
						format(string,sizeof(string),"** %s takes out a cellphone",sendername);
						ProxDetector(15.0,playerid,string,COLOR_WHITE,COLOR_WHITE,COLOR_WHITE,COLOR_WHITE,COLOR_WHITE);
						Wait(5000);
						SendClientMessage(playerid,COLOR_WHITE,"On-Star: This is On-Star how can I help you?");
						Wait(2000);
						format(string,sizeof(string),"%s says: [Cell] I'd like to locate a stolen vehicle",sendername");
	          ProxDetector(15.0,playerid,string,COLOR_WHITE,COLOR_WHITE,COLOR_WHITE,COLOR_WHITE,COLOR_WHITE);
	          Wait(2000);
						SendClientMessage(playerid,COLOR_WHIE,"On-Star: Okay sir, can I have your name and identification number please");
						Wait(2000);
						format(string,sizeof(string),"%s enters in the information into their cellphone",sendername);
						ProxDetector(15.0,playerid,string,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
						Wait(2000);
						SendClientMessage(playerid,COLOR_WHITE,"On-Star: Okay sir, your car location is being uploaded to your phone.");
						Wait(500);
						SendClientMessage(playerid,COLOR_WHITE,"On-Star: If you wish to cancel the trace of your car, call this number again");
						Wait(500);
						SetPlayerCheckpoint(playerid,CarInfo[PlayerInfo[playerid][pPcarkey]][cLocationx], CarInfo[PlayerInfo[playerid][pPcarkey]][cLocationy], CarInfo[PlayerInfo[playerid][pPcarkey]][cLocationz], 5.0);
						gPlayerCheckpointStatus[playerid] = CHECKPOINT_CAR;
						return 1;
					}
					else
					{
					  SetPlayerSpecialAction(playerid, SPECIAL_ACTION_USECELLPHONE);
						Wait(1000);
						SendClientMessage(playerid,COLOR_WHITE,"Your tracking of your vehicle has been automatically cancelled");
						return 1;
					}
				}
				else
				{
				  SendClientMessage(playerid,
				}
			}
			else
			{
				GameTextForPlayer(playerid, "~w~You do not have a car to locate", 5000, 1);
			}
		}
		return 1;
	}*/
Reply
#2

Thanks, this helped me a lot
Reply
#3

Alot of code for a simple thing...
Reply
#4

Quote:
Originally Posted by mavtias
Alot of code for a simple thing...
Indeed, this code could have been made in just some few lines.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)