I wasn’t actually removing the other lines of code for any significant point, just because it was a bit easier for me to work with as I wasn’t running your whole project, only this one script, I simply dropped it on a game object and let it run. You may of course need many of the things I removed for the rest of your game, so it’s not for me to say really
I did spend quite a bit of time trying to get the float to work, but what I round was that in the console, the output of TankInventory only ever appeared to one decimal place, both before and after any calculation. If I let it keep running for long enough the first decimal digit did do down, but it was going down at a rate of 0.1 initially around 1 second, and then the duration seemed to increase - it was certainly not accurate.
I then thought about the amount of time I was spending on trying to make a float work, and why it needed to be a float. Based on the objective, it didn’t really seem to matter what our data type was to some degree, as long as it could reasonably accurately show to rate of deduction.
With decimal you can of course have a large number of decimal places should you wish, and without knowing the full plan behind your goal here it would be impossible for me to start what is right, but I thought at least 4 for the demo would be enough, you could always change later on etc.
The one thing that I did change which seemed relevant was moving part of the calculation to the Start() method, as both your throughput and the number of second, minute and hours in a day were constant, there was no need to calculate that every frame - so you got a little performance boost there too
Glad to be of help anyway