#stop playerInteractWithBlock from firing with playerPlaceBlock
1 messages · Page 1 of 1 (latest)
resolved ✅
const id = world.afterEvents.playerInteractWithBlock.subscribe(event => {
let { player } = event;
player.sendMessage("after interact");
})
world.afterEvents.playerPlaceBlock.subscribe(event => {
world.afterEvents.playerInteractWithBlock.unsubscribe(id);
let player = event.player;
player.sendMessage("after place");
system.runTimeout(() => {
world.afterEvents.playerInteractWithBlock.subscribe(id);
}, 1);
});
this is not compatible with multiplayer