Float to Integer function problem
# support-forum
c
Why this function:
Copy code
c++
    GetVehicleHealth(vehicleid, vehiclehp);
    if(FloatToInteger(vehiclehp) > FloatToInteger(VehicleInfo[vehicleid][vHealth]))
    {
      printf("%i/%i", FloatToInteger(vehiclehp), FloatToInteger(VehicleInfo[vehicleid][vHealth]));
Copy code
c++
stock FloatToInteger(Float:floatnumber) {
    new YourInteger = floatround(floatnumber, floatround_round);
    return YourInteger;
}
sometimes prints 957/957 907/907 they are the same value, why it is entering on this if > ?