IsVehicleStreamedIn

From SA-MP Wiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 16:53, 18 January 2014
Smithy (Talk | contribs)

← Previous diff
Revision as of 22:38, 1 February 2014
Connor Mead (Talk | contribs)

Next diff →
Line 39: Line 39:
[[Category:Scripting Functions]] [[Category:Scripting Functions]]
 +
 +[[fr:IsVehicleStreamedIn]]

Revision as of 22:38, 1 February 2014



IsVehicleStreamedIn was added in SA-MP 0.3a This function was added in SA-MP 0.3a and will not work in earlier versions!


Description:

Checks if a vehicle is streamed in for a player.


Parameters:
(vehicleid, forplayerid)
vehicleidThe ID of the vehicle to check.
forplayeridThe ID of the player to check.


Return Values:

0: Vehicle is not streamed in for the player.

1: Vehicle is streamed in for the player.


new streamedVehicleCount = 0;
 
for(new v = 1; v < MAX_VEHICLES; v++)
{
    if(IsVehicleStreamedIn(v, playerid))
    {
        streamedVehicleCount++;
    }
}
 
new szString[144];
format(szString, sizeof(szString), "You currently have %i vehicles streamed in to your game.", streamedVehicleCount);
SendClientMessage(playerid, COLOUR_WHITE, string);

Related Functions

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


Related Callbacks

The following callbacks might be useful, as they're related to this function in one way or another.

In other languages