23.07.2011, 06:16
Quote:
Yes, the Respawn Delay, I know of that, Thats spawns the vehicle back from where the players spawned it from the dialog.
|
pawn Код:
new Car;
Car = CreateVehicle(blahahahah);
DestroyVehicle(car); // this destroys the car they spawned but delete it after the exit the car but set a timer for the amount of seconds you want to return in the car before it deletes the car.
pawn Код:
SetTimerEx("RepairNao",500,true,"i",playerid);
forward RepairNao ( playerid ) ;
public RepairNao ( playerid) {
RepairVehicle ( GetPlayerVehicleID ( playerid ) );
SetVehicleHealth ( GetPlayerVehicleID ( playerid ), 9999.0 );
return 1;
}
pawn Код:
SetTimerEx("RepairNao",500,true,"i",playerid); // OnGameModeInit
forward RepairNao ( playerid ) ; // On Top of script
public RepairNao ( playerid) { // Any where in script not in a callback. like bottom of your script works.
RepairVehicle ( GetPlayerVehicleID ( playerid ) );
SetVehicleHealth ( GetPlayerVehicleID ( playerid ), 9999.0 );
return 1;
}