Check vehicles nearby
#9

here i also tested it:

you can set you'r own radius too

PHP код:
IsPlayerNearSpecificVehicle(playeridvehicle_modelidFloat:radius)
{
    new 
Float:vxFloat:vyFloat:vz;
    for(new 
vi 0vi MAX_VEHICLESvi++)
    {
        
GetVehiclePos(vivxvyvz);
        if(
vi == INVALID_VEHICLE_ID || GetVehicleModel(vi) != vehicle_modelid || !IsPlayerInRangeOfPoint(playeridradiusvxvyvz)) continue; 
        return 
1;
    }
    return 
0;

Reply


Messages In This Thread
Check vehicles nearby - by Drak03 - 26.03.2018, 12:55
Re: Check vehicles nearby - by v1k1nG - 26.03.2018, 13:32
Re: Check vehicles nearby - by Grim_ - 26.03.2018, 13:48
Re: Check vehicles nearby - by v1k1nG - 26.03.2018, 14:55
Re: Check vehicles nearby - by Grim_ - 26.03.2018, 15:01
Re: Check vehicles nearby - by v1k1nG - 26.03.2018, 15:26
Re: Check vehicles nearby - by Grim_ - 26.03.2018, 15:41
Re: Check vehicles nearby - by v1k1nG - 26.03.2018, 16:05
Re: Check vehicles nearby - by Lokii - 26.03.2018, 16:27
Re: Check vehicles nearby - by Grim_ - 26.03.2018, 17:32

Forum Jump:


Users browsing this thread: 3 Guest(s)