Advertisement
TheTombstone

Shulker Block

Aug 21st, 2019
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.63 KB | None | 0 0
  1. prevent_shulker_box_recursion:
  2. type: world
  3. events:
  4. on player clicks in inventory:
  5. - if <context.item.material> == "m@shulker_box" {
  6. - if <context.is_shift_click> {
  7. - narrate "Shift-clicking shulker boxes is disabled."
  8. - determine cancelled
  9. }
  10. }
  11. - if <context.hotbar_button> > 0 && <player.inventory.slot[<context.hotbar_button>].material> == "m@shulker_box" {
  12. - narrate "Hotbar hotkeys are disabled for shulker boxes."
  13. - determine cancelled
  14. }
  15. on player clicks in chest with shulker_box:
  16. - if <context.clicked_inventory.inventory_type> == CHEST && !<context.cursor_item.inventory.is_empty> {
  17. - narrate "The chest isn't big enough for that."
  18. - determine cancelled
  19. }
  20. on player drags shulker_box in chest:
  21. - if <context.clicked_inventory.inventory_type> == CHEST && !<context.item.inventory.is_empty> {
  22. - narrate "The chest isn't big enough for that."
  23. - determine cancelled
  24. }
  25. on player clicks in ender_chest with shulker_box:
  26. - if <context.clicked_inventory.inventory_type> == ENDER_CHEST && !<context.cursor_item.inventory.is_empty> {
  27. - narrate "The ender chest isn't big enough for that."
  28. - determine cancelled
  29. }
  30. on player drags shulker_box in ender_chest:
  31. - if <context.clicked_inventory.inventory_type> == ENDER_CHEST && !<context.item.inventory.is_empty> {
  32. - narrate "The ender chest isn't big enough for that."
  33. - determine cancelled
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement