Skip to content

Commit

Permalink
[1.5.6] - Cancel event on ATTACHED display creation
Browse files Browse the repository at this point in the history
  • Loading branch information
Luncaaa committed Nov 1, 2024
1 parent 6f335c6 commit bff64b5
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ public void onPlayerInteract(PlayerInteractEvent event) {

DisplaysManager manager = plugin.getDisplaysManager();
if (manager.isPlayerAttaching(player) && action == Action.RIGHT_CLICK_BLOCK) {
event.setCancelled(true);
AttachedDisplay display = manager.getAttachingDisplay(player);
ADTextDisplay newDisplay = manager.createAttachedDisplay(event, display);
if (newDisplay == null) {
Expand Down

0 comments on commit bff64b5

Please sign in to comment.