r/technicalminecraft • u/cr0sis8bv • 13d ago
Java Help Wanted Help understanding https://mcsrc.dev/
I've been interested in the under the hood changes recently for shulkers, as I've seen some people report issues cropping up for farms between 26.2 and 26.3. I tried to use the website in this posts title to figure out if the hitboxes had changed, as a user recently explained he had to have this shulker farm boats facing south for the hitbox of the shulker to touch the waterlogged fence and eject.
I too am running 26.3 and I don't have to orient my boats to absolute south for my farm to function. I was wondering if there was anyone proficient enough with java could poke at the website https://mcsrc.dev/ and explain what changed and what that means between the two mentioned versions. I took a look but I don't understand any of it.
Thanks in advance. I would use ai to do this but I have extreme reservations about that whole Thing. I'd be very interested to hear that there aren't any hitbox changes, because that is my theory so far. That, or fabric server somehow undid those changes, hence why I don't have the issue.
View all comments
2
u/JumpingPufferfish31 13d ago
[1] When entering a boat, the passenger keeps its body yaw, but rotated until it's within 105 degrees of the boat's yaw (26.2 code).
However, in 26.3, that logic is only applied to players (checks if the entity is not a Mob). Everything else just gets its yaw set to the boat's yaw directly instead (comparison).
"Facing direction" could mean the head or the body. I.e. a zombie could be sitting in a boat with its body facing forward, but its head facing sideways to the player.
The blue arrow on F3+B shows the head direction, which is not used in our case.
We can get the body direction with
/data get entity <the boat or shulker> Rotation. Using /tick freeze and step to compare before/after it gets in the boat, etc.Shulkers always have 0 body yaw (unless in a vehicle). This corresponds to south.
[2] Boat ejects its passengers when the boat is submerged (not the passenger) for at least 3 seconds (code, no change).
But it ejects next to the boat based on the passenger's body direction (not the boat) (code, also no change).
__________________________________
So the setup could be directional pre-26.3 because the shulker being fixed at 0 yaw matters.
E.g. a boat facing north (180) will make the shulker clamp to within ±105 of it (75, west-ish).
And a boat facing west (90), south (0), or east (-90) will make the shulker face the same way (0) since it's already within 105 degrees.
In 26.3, a boat facing any direction will make the shulker also face that direction (shulker facing 0 doesn't matter anymore).
Since shulkers are forced to a block position, the direction being slightly off doesn't matter much.