Artisan Worktables 1.12

Artisan Worktables 1.12

3M Downloads

Inserting liquid into worktable from stackable containers voids container & liquid

Damit84 opened this issue · 2 comments

commented

There is a strange bug when you try to insert liquid into a worktable by rightclicking with a stack of liquid containers. (Tech Reborn cells or Forestry cans for example).

If the worktable is not full but has not enough space to insert a full bucket the container gets voided and no liquid is added. This only happens if the container is in a stack. A single cell/can behaves correctly.

The problem is a bit hard to explain so I attached a video link as a demonstration.
The bug occured in DDSS Version 7.4a (the most recent one). I also reported the bug to Freebi85 but this does not seem to be a DDSS bug but rather a Artisan Worktable one.

If you need further information please feel free to message me!

commented

Thanks for the report!

This one is a bit complicated since the problem lies with Forge's FluidUtil class, specifically how the tryEmptyContainer method handles the case where a fluid handler returns null when drained, as does the Tech Reborn fluid handler when trying to drain any less than the container's full capacity (link).

When the tryEmptyContainer method is called with the intent to simulate a drain, it never actually calls the drain method on the fluid handler and instead it simulates the drain by simply checking if the container has enough fluid to satisfy the drain request. In this specific case, it causes the simulation to succeed and the subsequent actual drain to fail.

If the result of the call to drain here (link) is null, the method should return null.

The proper action here would probably be to PR a fix to Forge, but I don't know when or if I'll have time to do that. In the meantime, I'll implement a less-than-ideal workaround that should solve the issue.

It should be solved in Artisan Worktables 1.23.2 with Athenaeum 1.18.1.

commented

I'm leaving the issue open because it still requires proper action.