11.09.2011, 14:35
This makes no sense for this, since it not a real system to detect where the player marked the map, just a little trick for it..
For the GPS thing you could do (I will do a complete example for it tomorrow):
I think you didn't really understand the sense for this...
GetPlayerMarkedPlace could be done, but isn't really needed because of the callback.
For the GPS thing you could do (I will do a complete example for it tomorrow):
Код:
//Top of the script: new GPSx[MAX_PLAYERS]; new GPSy[MAX_PLAYERS]; new GPSz[MAX_PLAYERS]; new bool:GPSon[MAX_PLAYERS]; //command /gps: SetPlayerMarkingMap(playerid,1); // In the callback: if(MarkID == 1) { GPSx[playerid] = X; GPSy[playerid] = Y; GPSz[playerid] = Z; // Not really needed... GPSon[playerid] = true; } // Then create a timer which checks the distance etc.... and turns off if the destination is reached
GetPlayerMarkedPlace could be done, but isn't really needed because of the callback.