So I've been working on my map for a while, and its a custom pvp game kinda thing. There, I want all the players to be unable to access their inventories because it might cause some errors, as in my minigame there are different classes with different skills etc. How do I do that?
Minecraft – How to disable opening inventories in minecraft
minecraft-commandsminecraft-java-edition
Related Topic
- Minecraft – Have snowballs actually ever been able to hit players in vanilla
- Minecraft – How to detect which specific mob was killed by a player and increase a score accordingly
- Minecraft /xp wont let me target @p or @a
- Minecraft-Java-Edition – How to Prevent Players from Editing Armor Stands
- Minecraft Java Edition – How to Prevent Players from Spawning at Their Beds in Version 1.14
Best Answer
If you are a developer you can look further into cancelling the OpenInventoryEvent, it would look something like this, with a little editing of course. Or you can look into premade code such as RegionInventoryBlocker.
If you are a regular user, you can use a plugin such as http://mods.curse.com/bukkit-plugins/minecraft/lobbytools to disable the movement of things around on your inventory, this should do the job. You can also look into many other plugins that do this job.
Other than that, there is no other known way to completely disable the inventory.