I am saving pop_support of a province as a (%.1f) float. If I set the pop_support to 66.574, it gets saved as 66.6.
("PopSupport 66.6") This is fine. When I reboot the mud, I get a message during startup saying "BUG: Fread_province: no match: .6". I've traced this to a part of the code that says:
case 'P':
KEY( "PopSupport", province->pop_support, fread_number( fp ) );
break;
It then displays the pop_support as being 66.0, because it doesn't load the additional '.6' and reports it as a bug.
I tried changing 'fread_number' to 'fread_float' and then got a compile report saying 'implicit declaration of function 'fread_float'.
I'm all out of ideas, so please help!
("PopSupport 66.6") This is fine. When I reboot the mud, I get a message during startup saying "BUG: Fread_province: no match: .6". I've traced this to a part of the code that says:
case 'P':
KEY( "PopSupport", province->pop_support, fread_number( fp ) );
break;
It then displays the pop_support as being 66.0, because it doesn't load the additional '.6' and reports it as a bug.
I tried changing 'fread_number' to 'fread_float' and then got a compile report saying 'implicit declaration of function 'fread_float'.
I'm all out of ideas, so please help!