mojira.dev

Mondbrille

Assigned

No issues.

Reported

Comments

It's only reproducable with third party applications. I'm a developer and programming server plugins on the base of PaperMC. In this specific case I'm coupling minecarts together and let them move as a train with a spacing of 1 blocks between the minecarts (so every 2.0 blocks is one minecart). I'm doing this by appling deltaMovement to the minecarts. To prevent the minecarts from bouncing off of each other on ascending rails, I turn off the physics.

Steps to reproduce:

Test 1: normal minecart (working)
1. Build a short railroad as shown in the screenshot in north-south orientation (3 normal rails + detector rail at the most southern point)
2. Place a minecart on the most northern rail
3. Apply deltaMovement aka Motion. Command: /execute as @e[type=minecraft:minecart,distance=..5] run data merge entity @s {Motion:[0d, 0d, 0.08d]}
4. Minecart will travel south and stop on the detector rail
5. Detector rail will be powered

Test 2: noPhysics minecart
1. Take the test track from test 1
2. Place a minecart on the most northern rail
3. Set the Field Entity#noPhysics to true (not possible with normal commands, only with code)
4. Apply deltaMovement aka Motion. (see test 1 step 3)
5. Minecart will travel south and stop on the detector rail
6. Detector rail will NOT be powered.
7. Walk through the minecart or sit in it. Detector rail will be powered now.
8. Detector rail will stay powered until the minecart leaves the rail (e.g. applying deltaMovement again)

This never appears during normal gameplay nor by using commands, so the priority of this bug is nearly zero. But I would be thankful if the devs would fix this.

[media]

It isn't reproducable in vanilla gameplay. But it is a vanilla function, which is useful for mods and plugins.
Entity#checkInsideBlocks(...), BlockState#entityInside(...) and Entity#noPhysics are methods and fields in the Minecraft code.

I don't have the original Minecraft code, but I do have the remapped code via paperweight. Yes, this is a third party software, but please don't reject it because of this. A mojang developer will understand what I mean.

To the attached image: This is the checkInsideBlocks(...) method in net.minecraft.world.entity.Entity. The marked line 1752 triggers the detector rails check, if there is a minecart present. Because of line 1724 the following code (including line 1752) will not execute, if the Minecart has noPhysics set to true.

[media]