• check_circle Advancements
  • check_circle Functions
  • 3,773 views, 49 today
  • 512 downloads, 11 today
  • 31
  • 33
  • 19
EMD123's Avatar EMD123
Level 60 : High Grandmaster System
86
Revault is a small datapack that makes vaults and ominous vaults restock after some time. Normally once a vault is opened, it can't be opened again by that player, but Revault lets that player open it again, after some time has passed. It works in both singleplayer and multiplayer, with any number of players. Each player starts a timer in the vault when they open it. Once a timer finishes, the player who started that timer will be allowed to open that vault again.

Configuration

By default, a normal vault takes 1 hour to restock, and an ominous vault takes 5 hours. (For reference, a trial spawner takes 30 minutes)
You can change these values in a world by running /function revault:gamerules
You can change these values in every world by modifying/overwriting the function "revault:default_gamerules"

Installing and Uninstalling

When installed in an existing world, an already opened vault will stay locked, until a new player opens it, where it would then slowly unlock to each player that previously opened it, one at a time.

When Uninstalled, all vault-markers will stay.

When Reinstalled, all vaults that would have unlocked already, will unlock.
CompatibilityMinecraft 1.21
Tags

1 Update Logs

1.0.1 : by EMD123 06/22/2024 9:50:48 amJun 22nd

  • Removed debug chat messages/particles
  • Added a link to PMC in the gamerules menu

Create an account or sign in to comment.

User4452993G
07/13/2024 3:26 am
Level 1 : New Miner
User4452993G's Avatar
It doesn't seem to be working on my server? Could you help me
1
Aelve
06/26/2024 5:30 am
Level 43 : Master System Mage
Aelve's Avatar
Cool datapack. From your description it sounds like you're intending the the vault to work like the a trial spawner? Can I suggest you clear the entire list of UUIDs from the vault when it restocks rather than just the first player in the list?



As it only removed the first player, if you have two players who use the vault right after each other, then the first player only needs to wait 1 hour to use it again, while the second player has to wait two hours.
1
EMD123
06/30/2024 8:45 pm
Level 60 : High Grandmaster System
EMD123's Avatar
It's not exactly intended to work like a trial spawner. Each player that opens it has a timer, and the times don't stack. If two players open it, there will be two 1-hour timers, each one resetting the corresponding player in the list.

The only time a player would need to wait 2 hours to be reset is if a previous player opened it without starting a timer. (Ie, a player opens a vault before the pack is installed, or a player opens a vault outside of the default detection range.)

I like your idea of resetting every UUID, but I'll have it only do that if the last timer finishes but there are still un-reset players in the vault player list.
2
Aelve
07/01/2024 8:28 am
Level 43 : Master System Mage
Aelve's Avatar
I see, my mistake. Thanks for the explanation. The way I had opened the vault (I was using a fake player) had caused it be as if a player had opened the vault without starting a timer.
1
CoreyByte
06/24/2024 1:30 am
Level 27 : Expert Miner
CoreyByte's Avatar
I have a quick question, i was testing this with some custom vaults, and it didn't seem to work, does it only effect naturally generated in vaults?



or is there something im missing to get it to function with custom vaults?
1
EMD123
06/27/2024 12:01 pm
Level 60 : High Grandmaster System
EMD123's Avatar
It should work with custom vaults, as long as they don't have an increased player detection range.
The datapack only scans for vaults opened by a player within the default range.
2
CoreyByte
06/27/2024 4:55 pm
Level 27 : Expert Miner
CoreyByte's Avatar
ok good to know thank you for getting back to me ^^
1
that2ndshroom
06/21/2024 4:13 pm
Level 1 : New Miner
that2ndshroom's Avatar
Is it supposed to say "[​Marker] vault" whenever someone opens a vault? is there a way to make it stop saying it in chat> thanks!
1
EMD123
06/22/2024 8:08 am
Level 60 : High Grandmaster System
EMD123's Avatar
Nope! Thats a debug message I forgot to remove.

It will be fixed in 1.0.1
3
that2ndshroom
06/22/2024 8:45 pm
Level 1 : New Miner
that2ndshroom's Avatar
honestly i want there to be a toggle for it, my server has started a mini cult for it lol
1
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome