{Rep++}Help!!![Vehicle OwnerShip]{++Rep}
#1

Well guys,after the successfully house system,I scripted a "successful" Vehicle OwnerShip in like about 20 mins (it was easy,following the example from the house system),but with my scripting skills,I cannot come up with an idea of how to load the player's vehicles when he connects to the server(when he disconnects I destroy them,so "pushing vehicle into water" is not possible).This is how the DataBase looks(made with Y_INI):
Код:
VehInfo = AddStaticVehicle(451,-2011.099243,135.788101,27.318271,181.324340,0,0) ;
Whenever the player buys a new car,a new line like the one above is added to the player's VehiclesDB.Do you have an idea of how should I load the vehicles from those DataBase lines acording to the fact that the player can own more than 1 vehicle(:P)?And,also,I have problems related to the car's angle.This is how I save the car's angle[RESUMED](:P):

pawn Код:
new vehicleid=GetPlayerVehicleID(playerid);
  Float:vAngle//This belongs to the vehicle's enumeration of course,but I am resuming now :P
  new Float:zangle;//The angle
  GetVehicleZAngle(vehicleid,zangle);//Getting the angle :P
  VehiInfo[vehicleid][vAngle]=zangle; //Saving it
  //Of course I am adding it to the DataBase...:P
  //When the vehicle re-spawns...
  SetVehicleZAngle(vehicleid,VehInfo[vehicleid][vAngle]);
So I am doing exactly the same for vehicle's position,the position saves,and when the car re-spawns,it spawns where it should,but with 45 angle(LOL?)[And the angle saves normally in the DataBase]-(DOUBLE LOL?).Anyway,much more important is how to load the vehicle from the DataBase if you have an idea,thanks.

"Help me fast,please and thanks.Giving you reputation!!!"
Reply


Messages In This Thread
{Rep++}Help!!![Vehicle OwnerShip]{++Rep} - by Cjgogo - 06.04.2012, 09:29
Re: {Rep++}Help!!![Vehicle OwnerShip]{++Rep} - by Harish - 06.04.2012, 10:20
Re: {Rep++}Help!!![Vehicle OwnerShip]{++Rep} - by Cjgogo - 06.04.2012, 12:58
Re: {Rep++}Help!!![Vehicle OwnerShip]{++Rep} - by Harish - 07.04.2012, 07:23

Forum Jump:


Users browsing this thread: 1 Guest(s)