Only one car parked at one spot, need help [++Rep]
#1

Hello, on my server I have a car system and a command:
pawn Код:
if(strcmp(cmd, "/parkcar", true) == 0)
{

new CarFile[35];
format(CarFile,sizeof(CarFile),"Cars/%d.ini",PlayerInfo[playerid][pCarSel]);

//rest of the command is here
}
pawn Код:
PlayerInfo[playerid][pCarSel]
is you car ID, everyone has a different ID.

Now, when you park your car I also want the ca ID and Position to be saved in such way:
Код:
PlayerInfo[playerid][pCarSel],X,Y,Z,A
And if you use park again if that string already exists it updates X,Y,Z,A
and if somone with a different ID tries to park in your spot or within 3m (so need to check through the file there) they will get a message saying that this parking space is taken.

So overall, I need a file that can update position of certain car ID's
and a way to check the file to see if any one is parked here.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)