15.02.2009, 17:54
How would I go about loading car spawns from a file like the .txt spawns included in the server?
public OnGameModeInit() { [....] LoadVehiclesFromFile(); [...] } stock LoadVehiclesFromFile() { new File: file = fopen("file name", io_read); new data[256]; while (fread(file,data)) { // use something here to split the string into all sorts of smaller strings, usable for extracting data // this requires every car to be saved like this >>> model,x,y,z,a,col1,col2 // so with commas to seperate the different values CreateVehicle(model, x, y, z, a, col1, col2); } return 1; }