Minecraft - Prevent people from logging off in certain areas

Minecraft - Prevent people from logging off in certain areas - Doctor offering choice to patient in office

I am currently making a bukkit server. I have trade rooms, however I do not want people to be able to log off inside them, and log in while someone is trading. How can I prevent this?

My idea is to make their characters tp to spawn if they log off in the area. Anyone know a plugin where I can do this? Or how to do it if I can with WorldGuard. Thanks.



Best Answer

You could run a command to teleport them out again when they recognise, but you also could just run a command like /execute @e[type=Player] (x) (y) (z) /(command) onto a NOT gate to run a command that will teleport the other player out of there... I'm thinking put the command block under the trading room, put in something like /tp @e[type=Player,range=5] (x) (y) (z) and make sure that no other player can come within that radius.

Hope this helps!




Pictures about "Minecraft - Prevent people from logging off in certain areas"

Minecraft - Prevent people from logging off in certain areas - Faceless doctor with chocolate coins in hands
Minecraft - Prevent people from logging off in certain areas - Faceless medical worker showing sample of herbal medicine in hand while sitting at table
Minecraft - Prevent people from logging off in certain areas - Crop unrecognizable person grasping handle in metro train





Minecraft: WorldGuard Tutorial - Protect Regions, Disable PvP, and More!




Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

Images: Karolina Grabowska, Karolina Grabowska, Karolina Grabowska, Laura James