PneumaticCraft: Repressurized

PneumaticCraft: Repressurized

50M Downloads

Refinery

Supertankkillz opened this issue · 4 comments

commented

Describe the bug

Refinery not outputting any fluids

How to reproduce the bug

have full crude oil, and i have 100+ heat and no fluids are being produce.

Expected behavior

i expect, gasoline, deisel, kreosote, and LPG to be made

Additional details

No response

Which Minecraft version are you using?

1.20.1

Which version of PneumaticCraft: Repressurized are you using?

8.0.3

Crash log

No response

commented

"kreosote" ?? Are you in some mod pack with custom recipes?

commented

@Synchris2-0 thanks for the detailed investigation, that was enough to identify the problem. The Refinery caches valid recipes based on the input fluid, for performance, but caching didn't take into account the current number of refinery outputs (so with no outputs, it cached an empty result for crude oil).

Next version takes both the fluid and the number of outputs into account when generating cache keys, so will function correctly as outputs are added/removed.

commented

Hello,

I have encountered a situation similar to what OP described. I conducted some research to try to reproduce the bug, isolate the cause and find a way to revert the refineries to an un-glitched state.
Not wanting to duplicate issue topic, I hope this is okay to comment on this one, if not I may create another issue.

Describe the bug

Refinery controller not working despite having crude oil, at least 2 refinery outputs and enough heat (see Figure 1).

Figure 1 - Refinery controller in a glitched state, no output even with at least 2 refinery outputs and enough heat

Figure 1 - Refinery controller in a glitched state, no refining even with at least 2 refinery outputs and enough heat

Notes:

  • The temperature gauge does not show the yellow arrow (>=100°C) indicating the minimum temperature needed
  • The GUI has nothing to complain about ("No problems")

How to reproduce the bug

  1. Create a new world (preferably in creative)
  2. Give yourself 1 refinery controller and 1 crude oil bucket
  3. Place the controller
  4. Fill the controller with crude oil
  5. Open the controller GUI

The controller is now in a glitched state (see Figure 2 below)

Figure 2 - Glitched refinery: does not complain about low temperature

Figure 2 - Glitched refinery: does not complain about low temperature

Adding refinery outputs (and thermal isolation to avoid warnings) doesn't change anything, see Figure 3 below.

2

Figure 3 - Glitched refinery not complaining about low temperature

The GUI states "No Problems" even though the temperature is below 100°C

Expected behaviour

Figure 4 below shows the expected behaviour of the refinery controller with crude oil, enough heat and 2 refinery output blocks (that is, when the refinery should be operating)

Figure 4 - Refinery in nominal state

Figure 4 - Refinery in nominal state

As intended, the GUI states "No Problems" and the crude oil is being refined.

The expected behaviour of the refinery controller when it should not be operating can be seen in Figure 5 (lack of heat) and Figure 6 (lack of heat and refinery output blocks) below.

Figure 5 - Expected behaviour of a refinery controller with crude oil, low temperature and 2 refinery outputs

Figure 5 - Expected behaviour of a refinery controller with crude oil, low temperature and 2 refinery outputs

Figure 6 - Expected behaviour of a refinery controller with crude oil, low temperature and no refinery outputs

Figure 6 - Expected behaviour of a refinery controller with crude oil, low temperature and no refinery outputs

As intended, an un-glitched controller is complaining about the lack of heat. Also, the mouse tooltip indicate the minimum temperature needed as well as the yellow arrow on the temperature gauge.

Additional details

Once the bug is present, from my experience, every refinery will be affected. Destroying and replacing one won't fix the issue. Same as crafting another one from scratch.
The only way to fix it is to reload the save, but only after making sure the following condition is TRUE:

The first refinery controller loaded by the game (should be the closest one to the player) has 0mB of crude oil OR has at least 2 refinery output blocks

In other words, the glitch is triggered when:

The first refinery controller loaded has crude oil but less than 2 refinery output blocks

Reloading is not so bad in single player, however, having to restart the whole server in MP is rather inconvenient.
I hope these informations are sufficient to track down and fix the bug. If you have any question, feel free to ask.

Which Minecraft version are you using?

1.21.1

Which version of PneumaticCraft: Repressurized are you using?

8.1.0

commented

Fixed in 8.1.1