GetPlayerSurfingVehicleID

GetPlayerSurfingVehicleID

Description:
Function GetPlayerSurfingVehicleID get the ID of the vehicle that the player is surfing on (stuck to the roof of).
Function GetPlayerSurfingVehicleID was added in 0.3a and will not work in earlier versions!


Parameters:
(playerid)
int playerid The ID of the player you want to know the surfing vehicle ID of.


Return Values:
The ID of the vehicle that the player is surfing. If they are not surfing a vehicle or the vehicle they are surfing has no driver, INVALID_VEHICLE_ID. If the player specified is not connected, INVALID_VEHICLE_ID also.


Examples:
new surf = GetPlayerSurfingVehicleID(playerid);
if(surf == INVALID_VEHICLE_ID) SendClientMessage(playerid, COLOR_RED, "You are not surfing.");


Related Functions
The following functions may be useful, as they are related to this function in one way or another.