Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command /storeinv <player> [<player>] [<player>]:
- trigger:
- if arg-2 is not set:
- set {_slot} to 0
- set {_player} to arg-1
- loop 36 times:
- clear {theslot.%{_slot}%.%{_player}%}
- add 1 to {_slot}
- set {_slot} to 0
- loop 36 times:
- set {theslot.%{_slot}%.%{_player}%} to slot {_slot} of {_player}'s inventory
- add 1 to {_slot}
- set {thehelm.%{_player}%} to helmet of {_player}
- set {thechest.%{_player}%} to chestplate of {_player}
- set {thelegs.%{_player}%} to leggings of {_player}
- set {theboots.%{_player}%} to boots of {_player}
- message "&7%{_player}%'s inventory has been stored."
- stop
- if arg-2 is set:
- if arg-3 is not set:
- set {_slot} to 0
- set {_player1} to arg-1
- set {_player2} to arg-2
- loop 36 times:
- clear {theslot.%{_slot}%.%{_player1}%}
- clear {theslot.%{_slot}%.%{_player2}%}
- add 1 to {_slot}
- set {_slot} to 0
- loop 36 times:
- set {theslot.%{_slot}%.%{_player1}%} to slot {_slot} of {_player1}'s inventory
- set {theslot.%{_slot}%.%{_player2}%} to slot {_slot} of {_player2}'s inventory
- add 1 to {_slot}
- clear {thehelm.%{_player1}%}
- clear {thechest.%{_player1}%}
- clear {thelegs.%{_player1}%}
- clear {theboots.%{_player1}%}
- clear {thehelm.%{_player2}%}
- clear {thechest.%{_player2}%}
- clear {thelegs.%{_player2}%}
- clear {theboots.%{_player2}%}
- set {thehelm.%{_player1}%} to helmet of {_player1}
- set {thechest.%{_player1}%} to chestplate of {_player1}
- set {thelegs.%{_player1}%} to leggings of {_player1}
- set {theboots.%{_player1}%} to boots of {_player1}
- set {thehelm.%{_player2}%} to helmet of {_player2}
- set {thechest.%{_player2}%} to chestplate of {_player2}
- set {thelegs.%{_player2}%} to leggings of {_player2}
- set {theboots.%{_player2}%} to boots of {_player2}
- message "&7%{_player1}%'s and %{_player2}%'s inventories has been stored."
- stop
- if arg-3 is set:
- set {_slot} to 0
- set {_player1} to arg-1
- set {_player2} to arg-2
- set {_player3} to arg-3
- loop 36 times:
- clear {theslot.%{_slot}%.%{_player1}%}
- clear {theslot.%{_slot}%.%{_player2}%}
- clear {theslot.%{_slot}%.%{_player3}%}
- add 1 to {_slot}
- set {_slot} to 0
- loop 36 times:
- set {theslot.%{_slot}%.%{_player1}%} to slot {_slot} of {_player1}'s inventory
- set {theslot.%{_slot}%.%{_player2}%} to slot {_slot} of {_player2}'s inventory
- set {theslot.%{_slot}%.%{_player3}%} to slot {_slot} of {_player3}'s inventory
- add 1 to {_slot}
- clear {thehelm.%{_player1}%}
- clear {thechest.%{_player1}%}
- clear {thelegs.%{_player1}%}
- clear {theboots.%{_player1}%}
- clear {thehelm.%{_player2}%}
- clear {thechest.%{_player2}%}
- clear {thelegs.%{_player2}%}
- clear {theboots.%{_player2}%}
- clear {thehelm.%{_player3}%}
- clear {thechest.%{_player3}%}
- clear {thelegs.%{_player3}%}
- clear {theboots.%{_player3}%}
- set {thehelm.%{_player1}%} to helmet of {_player1}
- set {thechest.%{_player1}%} to chestplate of {_player1}
- set {thelegs.%{_player1}%} to leggings of {_player1}
- set {theboots.%{_player1}%} to boots of {_player1}
- set {thehelm.%{_player2}%} to helmet of {_player2}
- set {thechest.%{_player2}%} to chestplate of {_player2}
- set {thelegs.%{_player2}%} to leggings of {_player2}
- set {theboots.%{_player2}%} to boots of {_player2}
- set {thehelm.%{_player3}%} to helmet of {_player3}
- set {thechest.%{_player3}%} to chestplate of {_player3}
- set {thelegs.%{_player3}%} to leggings of {_player3}
- set {theboots.%{_player3}%} to boots of {_player3}
- message "&7%{_player1}%'s, %{_player2}%'s and %{_player3}%'s inventories has been stored."
- stop
- command /unstoreinv <player> [<player>] [<player>]:
- trigger:
- if arg-2 is not set:
- set {_slot} to 0
- set {_player} to arg-1
- loop 36 times:
- set slot {_slot} of {_player} to {theslot.%{_slot}%.%{_player}%}
- delete {theslot.%{_slot}%.%{_player}%}
- add 1 to {_slot}
- equip {_player} with {theboots.%{_player}%}
- equip {_player} with {thechest.%{_player}%}
- equip {_player} with {thechest.%{_player}%}
- equip {_player} with {thehelm.%{_player}%}
- delete {thehelm.%{_player}%}
- delete {thechest.%{_player}%}
- delete {thelegs.%{_player}%}
- delete {theboots.%{_player}%}
- message "&7%{_player}%'s inventory has been restored."
- stop
- if arg-2 is set:
- if arg-3 is not set:
- set {_slot} to 0
- set {_player1} to arg-1
- set {_player2} to arg-2
- loop 36 times:
- set slot {_slot} of {_player1} to {theslot.%{_slot}%.%{_player1}%}
- set slot {_slot} of {_player2} to {theslot.%{_slot}%.%{_player2}%}
- delete {theslot.%{_slot}%.%{_player1}%}
- delete {theslot.%{_slot}%.%{_player2}%}
- add 1 to {_slot}
- equip {_player1} with {theboots.%{_player1}%}
- equip {_player1} with {thechest.%{_player1}%}
- equip {_player1} with {thelegs.%{_player1}%}
- equip {_player1} with {thehelm.%{_player1}%}
- equip {_player2} with {theboots.%{_player2}%}
- equip {_player2} with {thechest.%{_player2}%}
- equip {_player2} with {thelegs.%{_player2}%}
- equip {_player2} with {thehelm.%{_player2}%}
- delete {thehelm.%{_player1}%}
- delete {thechest.%{_player1}%}
- delete {thelegs.%{_player1}%}
- delete {theboots.%{_player1}%}
- delete {thehelm.%{_player2}%}
- delete {thechest.%{_player2}%}
- delete {thelegs.%{_player2}%}
- delete {theboots.%{_player2}%}
- message "&7%{_player1}%'s and %{_player2}%'s inventories has been restored."
- stop
- if arg-3 is set:
- set {_slot} to 0
- set {_player1} to arg-1
- set {_player2} to arg-2
- set {_player3} to arg-3
- loop 36 times:
- set slot {_slot} of {_player1} to {theslot.%{_slot}%.%{_player1}%}
- set slot {_slot} of {_player2} to {theslot.%{_slot}%.%{_player2}%}
- set slot {_slot} of {_player3} to {theslot.%{_slot}%.%{_player3}%}
- delete {theslot.%{_slot}%.%{_player1}%}
- delete {theslot.%{_slot}%.%{_player2}%}
- delete {theslot.%{_slot}%.%{_player3}%}
- add 1 to {_slot}
- equip {_player1} with {theboots.%{_player1}%}
- equip {_player1} with {thechest.%{_player1}%}
- equip {_player1} with {thelegs.%{_player1}%}
- equip {_player1} with {thehelm.%{_player1}%}
- equip {_player2} with {theboots.%{_player2}%}
- equip {_player2} with {thechest.%{_player2}%}
- equip {_player2} with {thelegs.%{_player2}%}
- equip {_player2} with {thehelm.%{_player2}%}
- equip {_player3} with {theboots.%{_player3}%}
- equip {_player3} with {thechest.%{_player3}%}
- equip {_player3} with {thethelegs.%{_player3}%}
- equip {_player3} with {thehelm.%{_player3}%}
- delete {thehelm.%{_player1}%}
- delete {thechest.%{_player1}%}
- delete {thelegs.%{_player1}%}
- delete {theboots.%{_player1}%}
- delete {thehelm.%{_player2}%}
- delete {thechest.%{_player2}%}
- delete {thelegs.%{_player2}%}
- delete {theboots.%{_player2}%}
- delete {thehelm.%{_player3}%}
- delete {thechest.%{_player3}%}
- delete {thelegs.%{_player3}%}
- delete {theboots.%{_player3}%}
- message "&7%{_player1}%'s, %{_player2}%'s and %{_player3}%'s inventories has been restored."
- stop
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement