How I Make Car Respawn
#1

How I make a System when the people exit the car, the car respawn?
My GameMode is this: http://forum.sa-mp.com/index.php?topic=33818.0
Reply
#2

pawn Код:
public OnPlayerExitVehicle(playerid, vehicleid)
{
  SetVehicleToRespawn(vehicleid);
  return 1;
}
Reply
#3

Use the SetVehicleToRespawn function.
Reply
#4

Do you u have any script tho spwan vehicle after 20 seconds of use....

Ex.: I exit the vehicle and after 20 seconds, the vehicle respawn
Reply
#5

Try this i think it's work

Put on top

Код:
forward("VehicleRespawn");
And that (not on top)

Код:
public OnPlayerExitVehicle(playerid, vehicleid)
{
  SetTimer("VehicleRespwn",2000,0);
  SetVehicleToRespawn(vehicleid);
  return 1;
}
i hope it work lol....
Reply
#6

Quote:
Originally Posted by .•[XpoweR
•. ]
Try this i think it's work

Put on top

Код:
forward("VehicleRespawn");
Код:
public OnPlayerExitVehicle(playerid, vehicleid)
{
  SetTimer("VehicleRespwn",2000,0);
  SetVehicleToRespawn(vehicleid);
  return 1;

i hope it work D:
}
Don't do it that way.
Use AddStaticVehicleEx or CreateVehicle. Search them on the wiki.
Reply
#7

Quote:
Originally Posted by .•[XpoweR
•. ]
Try this i think it's work

Put on top

Код:
forward("VehicleRespawn");
And that (not on top)

Код:
public OnPlayerExitVehicle(playerid, vehicleid)
{
  SetTimer("VehicleRespwn",2000,0);
  SetVehicleToRespawn(vehicleid);
  return 1;

i hope it work D:
}
Little mistake,he asked for 20 seconds.Just change 2000 to 20000
Reply
#8

yup
Reply
#9

Код:
forward("VehicleRespawn");
public OnPlayerExitVehicle(playerid, vehicleid)
{
  SetTimer("VehicleRespwn",2000,0);
  SetVehicleToRespawn(vehicleid);
  return 1;
}

I dont no where i put

Код:
forward("VehicleRespawn");
Reply
#10

put it on top after

Код:
#include <a_samp>
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)