Summary:
When subscribing to world events in GameTest Framework -> mojang-minecraft, such as:
world.events.itemUseOn
The event fires several times whenever the thing in question happens.
Steps to Reproduce:
1. Create a simple js script (the example I used is screenshotted below) that subscribes to the "itemUseOn" world event.
2. Load into any world seed.
3. Connect the Visual Studio Code debugger.
4. Put a breakpoint inside of the subscribed event handle.
5. In the game, right-click on any block to cause the event to fire.
6. Go back to VS Code and observe that the breakpoint has been hit.
Observed Results:
When F5 is pressed, the breakpoint is hit again immediately (from my testing, up to as many as 11 times).
Expected Results:
When F5 is pressed, the breakpoint should not be hit again until you have right-clicked again in the game.
Screenshots/Videos:
Notes:
This issue was seen on every event subscription I attempted (Item events, Block events, & Entity events).