Skip to main content
2 of 2
deleted 23 characters in body; edited title
pppery
  • 4k
  • 8
  • 29
  • 50

Place a complete bed using /setblock

I am setting up different means of transportation on our server. Right now I'm building an airship with four cabins. In each cabin is a bed. The idea is that each room has a different destination and when you sleep in the bed it teleports you to the same room in a duplicate of that airship at the destination area (to make it like you're really travelling in the ship).

I tried teleporting a sleeping player (using {Sleeping:1b}) but the sleeping animation continued and then moved the player back to the original bed. I corrected this by destroying the bed before teleporting and that fixed it however now I have another issue resulting from that. I replace the bed with /setblock and it only places the foot of the bed.

How can I use a command block to replace the bed so that both the foot and head of the bed are present?