-
Bug
-
Resolution: Unresolved
-
None
-
1.21.30.22 Preview, 1.21.2 Hotfix
-
None
-
Community Consensus
-
Multiple
If an add-on sets event.cancel to true of a playerInteractWithBlock event, and the block interacted with is a door, the door will still open for a split second on the client, allowing them to glitch through to the other side. Other players still see a closed door.
EDIT: I have renamed the bug because I suspect that this is related due to the animation controllers still being triggered, and some other blocks still play their animations. I have attached a video of my character interacting with a bunch of blocks with the example add-on enabled, and while nothing else happens, they still have their animations triggered. Since the door's animation includes a change in the hitbox, the door's animation also causes you to be able to glitch through.
Expected Result:
No animation plays on the block.
Doors stay closed for both client and server and player cant pass through if the playerIneractWithBlock event is canceled.
Observed Result:
Some blocks have their animations played.
Doors stay closed on server but open momentarily on client, allowing client to pass through.
Steps to Reproduce:
1. Open a new world.
2. Place blocks.
3. Add to that world an add-on that cancels playerInteractWithBlock Before Event signals, like this (attached is an add-on that does this):
main.js:
import * as server from '@minecraft/server' server.world.beforeEvents.playerInteractWithBlock.subscribe((event) => { event.cancel = true; });
4. Interact with the blocks you placed down.