Radar Command
#3

Quote:
Originally Posted by jakejohnsonusa
Посмотреть сообщение
Are you sure that your GetVehicleName function is working correctly (does it work elsewhere)?
No, actually. I'll test it real quick.

EDIT: Yes, it works.

pawn Код:
CMD:name(playerid, params[])
{
    new vehicleid;
    if(sscanf(params, "d", vehicleid)) return 1;
   
    new string[16];
    format(string, sizeof(string), "%s", GetVehicleName(vehicleid));
    SendClientMessage(playerid, -1, string);
    return 1;
}
I used this to test it.

EDIT 2: This must mean it's the GetNearestVehicle function, which also works elsewhere.

EDIT 3: I made a command to test GetNearestVehicle as well, and it's returning MAX_VEHICLES for some reason..

pawn Код:
CMD:near(playerid, params[])
{
    new vehicleid = GetNearestVehicle(playerid, 30.0);

    new string[16];
    format(string, sizeof(string), "%d", vehicleid);
    SendClientMessage(playerid, -1, string);
    return 1;
}
Reply


Messages In This Thread
Radar Command - by austin070 - 31.08.2014, 17:16
Re: Radar Command - by jakejohnsonusa - 31.08.2014, 17:27
Re: Radar Command - by austin070 - 31.08.2014, 17:29

Forum Jump:


Users browsing this thread: 2 Guest(s)