Blood Tank MAX Capacity Suggestion
Blue64 opened this issue ยท 2 comments
I know that it sounds like overkill to some, but if I'm setting up Mob Farms, I'm going to be funneling them into my upgraded Pedestal with Spikes on top (for full effect), thus generating a TON of Blood, I was customizing my config files, and read the Blood Container said to not go over the int limit, well, you weren't specific, and I set it to 2,000,000 (2 billion), which is under the limit, but you used the floating point int not the full value, three hours later I figured out that was why my game froze up during Mod Initialization phase 3 every time it hit CraftGuide (it spots the error while checking the recipes available, thus causing a massive memory leak, and what should have only needed 1 gig of RAM to launch, maxes out at my allotted 2 gigs and never finishes).
Might I ask what you intended a Negative MAX Capacity to be used for? There's 2 types of integers: signed
and unsigned
. One maxes out below 2 billion value and allows a negative value, the other maxes shortly beyond 2 billion value, and has no potential for Negative Values (it loops to it's Max, you can include code that sets it so if it loops and ends up above it's maximum capacity, it resets to the default capacity, thus retaining MineTweaker type compatibility while preventing exploits).
There's a difference between the MAX Capacity Variable, and the CURRENT Capacity Value. I suppose you would need to adjust the current capacity fail safe in a similar way (but instead of setting it to default, you'd set it to empty like the current standard. It's not much coding, just an extra check to see if it looped around, similar to the check for it going negative, so more of a tweak there)
This would be a major help in my Mob Farms, and probably many other's (along with a nice Fluid Storage Alternative to the Extra Utilities Barrels for any applicable fluids)
You're right, I didn't take into account integer overflows here: https://github.com/CyclopsMC/EvilCraft/blob/master-1.7/src/main/java/evilcraft/block/DarkTank.java#L270-L280
So this can result in a lot subitems which could overload NEI/CraftGuide-like mods.
Once this is fixed, you should be able to set this max value up to 2 147 483 647 (I'll test this once this has been fixed).