Skip to main content

How do i enable pvp in a specific area



  • Minecraft EDU Official Community manager

    Chris Fuge any thoughts?

  • Chris Fuge Community moderator
    Expert (Gold) Moderator

    I was thinking about this the other day. My understanding is that PVP true/false is a general gamerule that would apply to the entire world. I could be wrong, but I'm not aware of a way to limit it to a certain area/player.

    What I have done in my battle arena game is start with PVP false (use the command: /gamerule pvp false) for the start of the game while players are joining and getting ready. Then, I have a countdown and run the command: /gamerule pvp true.

    Another option, that I use when players are defeated in the arena, is to give them a weakness effect so that even if they try to attack one another, they don't really do any damage. 

    /effect @p weakness 9999 255 true
    This will be the max effect 255, for 9999 seconds.

    Then, if you want to start another round, just make sure to clear all effects.
    /effect @a clear

    Hope this helps!

  • Brett Girod

    Create different zones with barrier blocks. Then have students enter the zone through a portal that forces them to step on a pressure plate, push a button, or pull a lever to trigger the needed commands. I use commands like Chris Guge, /effect @p weakness 9999 255 true

  • Dat Chu

    How can I play PvP maps with other people because I don’t have anyone to play with ?


Please sign in to leave a comment.