SA-MP Forums Archive
Vehicle Position from File - 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: Vehicle Position from File (/showthread.php?tid=155497)



Vehicle Position from File - Mike Garber - 18.06.2010

Hi, I'd like to know the correct way to move a vehicle with SetVehiclePos from a file? I'd prefer to use dini.
I tried, but It tells me that argument 2 (the variable i use) is wrong inside SetVehiclePos.

This is under OnVehicleSpawn;
pawn Код:
new CARIDstring[64];
format(CARIDstring, sizeof(CARIDstring), "%d", vehicleid);

if(strlen(dini_Get("File.txt",CARIDstring))==1){
new newpos[256];
newpos = dini_Get("File.txt", CARIDstring);
SetVehiclePos(vehicleid,newpos); // error 035: argument type mismatch (argument 2)
}
Thank you for reading, and I'd appreciate any help

(Don't mind me creating a new value for the vehicleid, It's originally used for other stuff below)