select_item.mcfunction 9.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. execute if score @s item_slot matches 0 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:0b}]
  2. execute if score @s item_slot matches 1 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:1b}]
  3. execute if score @s item_slot matches 2 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:2b}]
  4. execute if score @s item_slot matches 3 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:3b}]
  5. execute if score @s item_slot matches 4 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:4b}]
  6. execute if score @s item_slot matches 5 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:5b}]
  7. execute if score @s item_slot matches 6 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:6b}]
  8. execute if score @s item_slot matches 7 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:7b}]
  9. execute if score @s item_slot matches 8 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:8b}]
  10. execute if score @s item_slot matches 9 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:9b}]
  11. execute if score @s item_slot matches 10 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:10b}]
  12. execute if score @s item_slot matches 11 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:11b}]
  13. execute if score @s item_slot matches 12 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:12b}]
  14. execute if score @s item_slot matches 13 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:13b}]
  15. execute if score @s item_slot matches 14 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:14b}]
  16. execute if score @s item_slot matches 15 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:15b}]
  17. execute if score @s item_slot matches 16 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:16b}]
  18. execute if score @s item_slot matches 17 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:17b}]
  19. execute if score @s item_slot matches 18 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:18b}]
  20. execute if score @s item_slot matches 19 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:19b}]
  21. execute if score @s item_slot matches 20 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:20b}]
  22. execute if score @s item_slot matches 21 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:21b}]
  23. execute if score @s item_slot matches 22 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:22b}]
  24. execute if score @s item_slot matches 23 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:23b}]
  25. execute if score @s item_slot matches 24 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:24b}]
  26. execute if score @s item_slot matches 25 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:25b}]
  27. execute if score @s item_slot matches 26 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:26b}]
  28. execute if score @s item_slot matches 27 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:27b}]
  29. execute if score @s item_slot matches 28 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:28b}]
  30. execute if score @s item_slot matches 29 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:29b}]
  31. execute if score @s item_slot matches 30 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:30b}]
  32. execute if score @s item_slot matches 31 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:31b}]
  33. execute if score @s item_slot matches 32 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:32b}]
  34. execute if score @s item_slot matches 33 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:33b}]
  35. execute if score @s item_slot matches 34 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:34b}]
  36. execute if score @s item_slot matches 35 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:35b}]
  37. execute if score @s item_slot matches 100 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:100b}]
  38. execute if score @s item_slot matches 101 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:101b}]
  39. execute if score @s item_slot matches 102 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:102b}]
  40. execute if score @s item_slot matches 103 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:103b}]
  41. execute if score @s item_slot matches -106 run data modify entity @e[type=item,tag=LockTempItem,limit=1] Item set from entity @s Inventory[{Slot:-106b}]
  42. execute if score @s item_slot matches 0 run item replace entity @s hotbar.0 with air
  43. execute if score @s item_slot matches 1 run item replace entity @s hotbar.1 with air
  44. execute if score @s item_slot matches 2 run item replace entity @s hotbar.2 with air
  45. execute if score @s item_slot matches 3 run item replace entity @s hotbar.3 with air
  46. execute if score @s item_slot matches 4 run item replace entity @s hotbar.4 with air
  47. execute if score @s item_slot matches 5 run item replace entity @s hotbar.5 with air
  48. execute if score @s item_slot matches 6 run item replace entity @s hotbar.6 with air
  49. execute if score @s item_slot matches 7 run item replace entity @s hotbar.7 with air
  50. execute if score @s item_slot matches 8 run item replace entity @s hotbar.8 with air
  51. execute if score @s item_slot matches 9 run item replace entity @s inventory.0 with air
  52. execute if score @s item_slot matches 10 run item replace entity @s inventory.1 with air
  53. execute if score @s item_slot matches 11 run item replace entity @s inventory.2 with air
  54. execute if score @s item_slot matches 12 run item replace entity @s inventory.3 with air
  55. execute if score @s item_slot matches 13 run item replace entity @s inventory.4 with air
  56. execute if score @s item_slot matches 14 run item replace entity @s inventory.5 with air
  57. execute if score @s item_slot matches 15 run item replace entity @s inventory.6 with air
  58. execute if score @s item_slot matches 16 run item replace entity @s inventory.7 with air
  59. execute if score @s item_slot matches 17 run item replace entity @s inventory.8 with air
  60. execute if score @s item_slot matches 18 run item replace entity @s inventory.9 with air
  61. execute if score @s item_slot matches 19 run item replace entity @s inventory.10 with air
  62. execute if score @s item_slot matches 20 run item replace entity @s inventory.11 with air
  63. execute if score @s item_slot matches 21 run item replace entity @s inventory.12 with air
  64. execute if score @s item_slot matches 22 run item replace entity @s inventory.13 with air
  65. execute if score @s item_slot matches 23 run item replace entity @s inventory.14 with air
  66. execute if score @s item_slot matches 24 run item replace entity @s inventory.15 with air
  67. execute if score @s item_slot matches 25 run item replace entity @s inventory.16 with air
  68. execute if score @s item_slot matches 26 run item replace entity @s inventory.17 with air
  69. execute if score @s item_slot matches 27 run item replace entity @s inventory.18 with air
  70. execute if score @s item_slot matches 28 run item replace entity @s inventory.19 with air
  71. execute if score @s item_slot matches 29 run item replace entity @s inventory.20 with air
  72. execute if score @s item_slot matches 30 run item replace entity @s inventory.21 with air
  73. execute if score @s item_slot matches 31 run item replace entity @s inventory.22 with air
  74. execute if score @s item_slot matches 32 run item replace entity @s inventory.23 with air
  75. execute if score @s item_slot matches 33 run item replace entity @s inventory.24 with air
  76. execute if score @s item_slot matches 34 run item replace entity @s inventory.25 with air
  77. execute if score @s item_slot matches 35 run item replace entity @s inventory.26 with air
  78. execute if score @s item_slot matches 100 run item replace entity @s armor.feet with air
  79. execute if score @s item_slot matches 101 run item replace entity @s armor.legs with air
  80. execute if score @s item_slot matches 102 run item replace entity @s armor.chest with air
  81. execute if score @s item_slot matches 103 run item replace entity @s armor.head with air
  82. execute if score @s item_slot matches -106 run item replace entity @s weapon.offhand with air
  83. scoreboard players reset @s item_slot