
New Back in Slime pistons ("betterPistons" in mixin.cfg) destroy piston relays when pulling them.
Roadhog360 opened this issue ยท 2 comments
Originally reported by @DrParadox7 on Discord, posted here since I can't tell if this is even fixable from my end or not.
Please check any boxes that apply to you and your issue
-
I use a translator application to post this issue.
-
This is a crash. Please upload, Pastebin, Gist or copypaste the whole crash report along with this issue.
-
This is a mod incompatibility. If I do this in vanilla Forge with only Et Futurum Requiem installed, it works normally.
Version number of Et-Futurum-Requiem (IMPORTANT)
EFR 2.5.0 6132816 although the issue likely started with the first Back in Slime backport commit. Issue is likely in the original Back in Slime (untested)
Describe the issue (IMPORTANT)
Piston relays cannot stick to slime blocks, do not move blocks when pushed by a sticky piston, and will disappear when being pulled by a sticky piston. When being pushed by a line of blocks or by a slime block it pops off as an item.
The "betterPistons" mixin seems to be fundamentally incompatible with force relays.
I missed the fact they are only supposed to work with regular pistons when pushing, and do not react to sticky pistons whatsoever despite being pulled. I think we can reasonably declare the slime block incompatibility as intended and just focus on not making it destroy the relay when pulling it.
Note: To even get Botania in the dev environment you have to basically completely disable all of the stuff in the enum or else there's bizarre crashing related to the DebugTestItem.
Additional Context (OPTIONAL)
BlockPistonRelay source code
Code analasys: I need a fucking cigarette
Longer code analasys: It seems the mobility flag is 1 due to it using the material gourd, and seems to manually try to hack together push-like behavior based on the world tick event, just deleting and replacing itself. The mobility flag 1 is used when a block should pop off when being pushed or pulled, and for slime blocks if it's not in the path it just won't get moved even if it's adjacent to one. And it's hard to tell if my guess is correct because this code looks incredibly fragile and difficult to read.
This explains the complete incompatibility with my slime block code. I'm not sure what I can do to actually fix the slime block compatibility, and I'm definitely not sure what I am doing differently from a piston pulling a block directly to cause the above issue.
Upon further analasys it probably shouldn't work with slime blocks as it seems they're supposed to only react at all to standard pistons. But this weird behavior is fully explained by bypassing piston logic by using the gourd material (why not just override the mobility function and set it to 1?!) and then stapling weird ass piston logic over the tick event...
Video tutorial on how they work
Update: Watching the tutorial in more detail now (I only cared to watch how to link relays before) turns out, they are not supposed to work with sticky pistons; they just should pull the relay back and forth and nothing happens to the linked block. Squishing a relay between pistons drops it, and due to the piston incompatibility and slight difference in behavior between a block being "slimed" and a block being pulled directly by a sticky piston, I will also reasonably declare that the relay popping off when a block or sticky block is pushed into it, as the intended behavior.
Relays, by design, probably should not work with any of the new piston functionality because they are incompatible with sticky pistons in vanilla.
Since only regular pistons are supposed to be used, and only for pushing (which works) I think we can resonably declare here the bug is just the relay being destroyed when pulled, when it should be pulled with no further action to the connected block.