[Include] clFunction - CreativityLacker's custom functions
#8

Quote:
Originally Posted by ikkentim
Посмотреть сообщение
stock GetValidVehiclesCount()
{
new count;
for(new x = 0; x < MAX_VEHICLES; x++)
{
if(x != INVALID_VEHICLE_ID)
{
count++;
}
}
return count;
}

Are you sure that works?
How can a static, defined number equal a dynamic number in a for loop?
Well, I didn't try it, But seeing it from the code, It looked fine when I was done with it though I did doubt that the check for checking if the vehicle is valid might be wrong. I'll try it asap and see if it has any bugs, Thanks for pointing it out though.

EDIT - Didn't work, I tried it with grand larc, The original count was 1750 something while the script counted 2000 vehicles, I'll work on it.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)