I am trying to build a spleef arena (and in the future more games) on a server that for everyone except admin is survival only. I want to set something up so that when they enter the waiting area to play, a set of command blocks empty their inventory to a chest, gives them the items needed for the game, removes said items after the game, then teleports them to en exit room with the chest containing their items.

Is this possible and how would I do it?

  1. Make sure /gamerule keepInventory is false.
  2. Teleport the player above a hopper which feeds into the chest you want to store their items in:

Cell above hopper feeding into chest

(You should probably make the chest a double chest.)

  1. Kill the player, and all their items will fall into the hopper and then get fed into the chest.
  • it might also have an array of these set up with an armorstand teleporting around to the unused ones. That way multiple players could play/drain their inventories at one time without mixing each others' stuff. – caucow Aug 8 '15 at 20:02
  • You can use the command /effect @p 7 10 15 to kill the player with command blocks (without having to teleport them to the void) – angussidney Aug 9 '15 at 7:42
  • @AngusAtkinson Or just /kill @p. – SirBenet Aug 9 '15 at 10:04
  • @colorfusion I thought /kill didn't work with command blocks? They must have updated it in 1.8 – angussidney Aug 9 '15 at 10:26
  • @AngusAtkinson I think it has worked in command blocks for as long as it's had a selector. – SirBenet Aug 9 '15 at 10:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.