TransWikia.com

Player Save State for Game Mode

Arqade Asked on September 5, 2021

On our server I’d like to switch people to adventure when they enter an area, but when they leave it should set them back to the game mode they were in before entering.

So my question is, is it possible to record player information in the scoreboard or a tag for their game mode and then use it later

e.g. tag @s add GameMode=[m]

One Answer

When they enter the area do:

/tag @a[m=s] add survival

And:

/tag @a[m=c] add creative

And:

/tag @a[m=a] add adventure

Then just change their gamemodes back later accordingly:

/gamemode a @a[tag=adventure,r=5]

etc.

Make sure to untag them:

/tag @a[tag=survival,r=5] remove survival

Correct answer by Penguin on September 5, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP