GregTechCEu / GregTech

GregTech CE 1.12 fork continuing progression and development
GNU Lesser General Public License v3.0
254 stars 176 forks source link

Add OCing past MAX and fix multi Laser and Substation Hatch support #2611

Closed IncandescenceSy closed 2 months ago

IncandescenceSy commented 2 months ago

What

In base CEu, there was never a need for machines to be able to overclock beyond MAX voltage, nor was there a need for multiblocks with SUBSTATION_INPUT_ENERGY or INPUT_LASER to actually be able to perform recipes using the power in those hatches. However, addons wishing to extend the game and add new content often want both of those things.

Outcome

Base CEu is not impacted at all. In any addon that adds any way to give a machine >MAX voltage, those machines will now be able to overclock further. In any addon that adds multiblocks that have SUBSTATION_INPUT_ENERGY or INPUT_LASER, those machines will now be able to use the power in those hatches to perform recipes.

Additional Information

image For tier names and colors above max, I used "MAX+X" with these 5 colors. This is impossible to see in base CEu (for this screenshot, I had temporarily allowed the EBF to accept Laser Target Hatches.)

The reason these two changes are bundled together is because I found out that multiblock INPUT_LASER support was broken while I was trying to test OCing past MAX.

IntegerLimit commented 2 months ago

Should multis also initialise energy container from SUBSTATION_INPUT_ENERGY?

IncandescenceSy commented 2 months ago

Oh, you're right, I didn't think of that. Let me test to make sure that's actually needed and then I'll add it if it is (it probably is)

IncandescenceSy commented 2 months ago

Actually, now that I think of it, don't the GCYM multis for the EBF and Vac already support this? Maybe they do something special to make it work, though, I'm not sure.

IncandescenceSy commented 2 months ago

I thought that the GCYM Mega EBF/Vac accepted Substation Hatches because Maya told me they did, but looking at the code, it seems they don't, and after testing, it seems that multiblocks won't take energy from Substation Hatches at all. Thankfully an easy fix, though.