Vehicle name
#2

Checking if the car is valid prevents it and also change the 2nd dimension of the array to 18 as it's nowhere close to 64.

PHP код:
GetVehicleModelName(modelid)
{
    new 
tmp_vname[sizeof VehicleName[]];
    if (
400 <= modelid <= 611strcat(tmp_vnameVehicleName[modelid 400], sizeof tmp_vname);
    return 
tmp_vname;

EDIT: In the loop, you can skip it directly so it won't call the function for no reason:
pawn Код:
if (!(400 <= g_VehicleData[i][eModel] <= 611)) continue;
Reply


Messages In This Thread
Vehicle name - by J4Rr3x - 18.06.2015, 16:32
Re: Vehicle name - by Konstantinos - 18.06.2015, 16:43
Re: Vehicle name - by J4Rr3x - 18.06.2015, 17:31

Forum Jump:


Users browsing this thread: 1 Guest(s)