OnPlayerEnterVehicle
#1

PHP код:
public OnPlayerEnterVehicle(playeridvehicleidispassenger)
{
    if((
vehicleid) == 447)
    {
          
TogglePlayerControllable(playeridtrue);
        
SendClientMessage(playerid,COLOR_RED,"Bayad Level 14 Bashi Ta Betooni Savar Shi");
    }
    return 
1;

Not to enter the ring
Reply
#2

Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger) { 
    if(GetVehicleModel(vehicleid) == 447)  { 
      TogglePlayerControllable(playerid, true); 
      SendClientMessage(playerid,COLOR_RED,"Bayad Level 14 Bashi Ta Betooni Savar Shi"); 
    } return 1; 
}
Reply
#3

Thank You <3
Reply
#4

Hope i am not confusing something here, but:

I'd suggest using OnPlayerStateChange instead, because you can check if the player actually entered a vehicle.
Look at OnPlayerEnterVehicle - "This callback is called when a player starts to enter a vehicle, meaning the player is not in vehicle yet at the time this callback is called."

I am probably am confusing something, sorry in advance.
Reply
#5

Quote:
Originally Posted by [Bios]Marcel
Посмотреть сообщение
Hope i am not confusing something here, but:

I'd suggest using OnPlayerStateChange instead, because you can check if the player actually entered a vehicle.
Look at OnPlayerEnterVehicle - "This callback is called when a player starts to enter a vehicle, meaning the player is not in vehicle yet at the time this callback is called."

I am probably am confusing something, sorry in advance.
You're not confusing it, your suggest is optional though, depends on what he wants.
Reply
#6

Quote:
Originally Posted by saffierr
Посмотреть сообщение
You're not confusing it, your suggest is optional though, depends on what he wants.
Well, i was confused , because he used TogglePalyerControllable(playerid, true);, so maybe he wants to prevent the player from entering specific vehicles (can't rellay judge cause i dont speak his language and he didnt provide further info)
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)