Player next to vehicle
#2

PHP код:
stock GetNearestVehicle(playeridFloat:dis)
{
    new 
Float:LFloat:OFloat:II;
    if(
GetPlayerPos(playeridLOII))
    {
        new 
vehicleid INVALID_VEHICLE_ID;
        for(new 
vFloat:tempFloat:VLFloat:VOFloat:VII!= MAX_VEHICLESv++)
        {
            if(
GetVehiclePos(vVLVOVII) && != GetPlayerVehicleID(playerid))
            {
                
VL -= LVO -= OVII -= II;
                
temp VL VL VO VO VII VII;
                if(
temp disdis tempvehicleid v;
            }
        }
        
dis floatpower(dis0.5);
        return 
vehicleid;
    }
    return 
INVALID_VEHICLE_ID;

Reply


Messages In This Thread
Player next to vehicle - by Amine_Mejrhirrou - 31.10.2012, 20:48
Re: Player next to vehicle - by tyler12 - 31.10.2012, 21:09
Re : Player next to vehicle - by Amine_Mejrhirrou - 31.10.2012, 21:43
Re: Player next to vehicle - by Stu1 - 31.10.2012, 21:50

Forum Jump:


Users browsing this thread: 1 Guest(s)