Issue description
Solar Generator and Advanced Solar Generator cause a crash when placed in biomes with a high temperature modifier due to the "peakMultiplier" becoming negative and being used in FloatingLong#multiply which is apparently not allowed to be negative.
I would expect the multiplier to cap out at 0 so this doesnt happen (and I've never heard of actual IRL solar panels taking power rather than generate)
Steps to reproduce
1 Find a biome (in my case I created my own with a temp mod of 5 out of curiosity) with a temperature above 4.1333 (relevant math: 1 - 0.3 * (0.8 - temp_mod))
2 Place Solar Generator or Advanced Solar Generator
3 Observe crash
Minecraft version
1.20.x or earlier (No longer being developed)
NeoForge version
47.4.0 (Forge)
Mekanism version
Older
Other relevant versions
Im aware that this is an older version but if you do run into this issue it would be difficult to resolve for the average player and its probably sufficiently solved by changing https://github.com/mekanism/Mekanism/blob/release/1.20.x/src/generators/java/mekanism/generators/common/tile/TileEntitySolarGenerator.java#L172 from return peakMultiplier; to return Math.min(0, peakMultiplier); but thats not for me to decide
If a (crash)log is relevant for this issue, link it here: (It's almost always relevant)
https://gist.github.com/stellanera98/9bc258ab54f033e8f608c3a0085b5419
Issue description
Solar Generator and Advanced Solar Generator cause a crash when placed in biomes with a high temperature modifier due to the "peakMultiplier" becoming negative and being used in FloatingLong#multiply which is apparently not allowed to be negative.
I would expect the multiplier to cap out at 0 so this doesnt happen (and I've never heard of actual IRL solar panels taking power rather than generate)
Steps to reproduce
1 Find a biome (in my case I created my own with a temp mod of 5 out of curiosity) with a temperature above 4.1333 (relevant math:
1 - 0.3 * (0.8 - temp_mod))2 Place Solar Generator or Advanced Solar Generator
3 Observe crash
Minecraft version
1.20.x or earlier (No longer being developed)
NeoForge version
47.4.0 (Forge)
Mekanism version
Older
Other relevant versions
Im aware that this is an older version but if you do run into this issue it would be difficult to resolve for the average player and its probably sufficiently solved by changing https://github.com/mekanism/Mekanism/blob/release/1.20.x/src/generators/java/mekanism/generators/common/tile/TileEntitySolarGenerator.java#L172 from
return peakMultiplier;toreturn Math.min(0, peakMultiplier);but thats not for me to decideIf a (crash)log is relevant for this issue, link it here: (It's almost always relevant)
https://gist.github.com/stellanera98/9bc258ab54f033e8f608c3a0085b5419