Liberty's Villagers

Liberty's Villagers

7M Downloads

setpoi is not working for beds

volduck opened this issue ยท 1 comments

commented
commented

It seems the command works if you're aiming at the head of the bed.

I don't know much about coding (and next to nothing about java) but after a few hours of looking into it, the relevant line of code seems to be:

PointOfInterestTypes.getTypeForState(blockState);

This checks whether or not the block you're aiming at is a type of Point of Interest, which only applies to the head of a bed, with the relevant POI type being minecraft:home (or perhaps minecraft:bed_head?). Since beds are the only relevant POI type that effectively take up multiple blocks, perhaps individualized handling for beds is needed.

Note that I did discover this on Minecraft version 1.21.4 using the mod version/fork mentioned in this pull request: #145 but this fork doesn't seem to make any changes relevant to this issue.