how to do this help ?
#1

Код:
new Owner_1;

OnGameModeInit()
{
  Owner_1 = CreateVehicle(581, 0.0, 0.0, 0.0, 0.0, 6, 6, 3000); 
  return 1;
}

public OnPlayerStateChange(playerid, newstate, oldstate)
{
  if(newstate == 2 || newstate == 3)
  {
    new VehicleID = GetPlayerVehicleID(playerid);
    if(VehicleID == Owner_1)
    {
      new Name[MAX_PLAYER_NAME];
      GetPlayerName(playerid, Name, sizeof(Name));
      if(strcmp( Name, "Firstname_Lastname")) RemovePlayerFromVehicle(playerid);
    }
  }
  return 1;
}
this is an example code but i want to make like a person types /buycar (id) (color id1) (color id2)
then it puts the player into the car and saves car owner how can i do like that?

i have login and register system just need an example code so i can edit it and remake into my gamemode
help please
Reply
#2

bump
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)