-
Bug
-
Resolution: Incomplete
-
None
-
1.20.50.21 Preview
-
None
-
Unconfirmed
-
Windows
When the event playerInteractWithBlock is emitted, it emits more than once for only one subscription
I wrote the following code
import {world} from "@minecraft/server";
let i = 0;
world.afterEvents.playerInteractWithBlock.subscribe(ev=>{
world.sendMessage(`Hello ${i++}`);
});
When triggering the event, it emits about 4~5 times in a row(i had causes that it emitted 10 times in a row), which causes unexpected behavior and possibly lag. I don't understand exactly what happens cause when I have a holdeable item in hand it emits once, but if not, on average, it emits 4 times