mirror of
https://github.com/Multiverse/Multiverse-Core.git
synced 2024-11-23 19:15:27 +01:00
Page:
Sharing Details (Inventories)
Pages
API Usages (Inventories)
API Usages (NetherPortals)
API Usages (Portals)
API Usages
Anchor Tutorial
Basics (Inventories)
Basics (NetherPortals)
Basics (Portals)
Basics
Big List O' Permissions
Big List O Permissions
Building
Command Reference (Inventories)
Command Reference (NetherPortals)
Command Reference (Portals)
Command Reference
Config.yml (Inventories)
Currency
Custom Generator Plugins
Destinations
Developer API Starter
FAQ (Inventories)
FAQ (NetherPortals)
FAQ
Help
Home (Inventories)
Home (NetherPortals)
Home (Portals)
Home (SignPortals)
Home
How can I help
How to get help
How to upgrade
Install (Inventories)
Install (NetherPortals)
Install (Portals)
Install (SignPortals)
Install
Known Conflicts
Permissions (Inventories)
Permissions (Portals)
Permissions (SignPortals)
Permissions List (Portals)
Permissions
Placeholders
Portal Style (SignPortals)
RedstoneTeleporting (SignPortals)
Shares List (Inventories)
Sharing Details (Inventories)
Sign Style (SignPortals)
Simple chinese config.yml
Submitting a Bug
World properties
config.yml (NetherPortals)
config.yml (Portals)
config.yml
0
Sharing Details (Inventories)
Jeremy Wood edited this page 2019-07-05 13:10:48 -04:00
Table of Contents
Sharing Details for Multiverse-Inventories
This document details how sharing works in Multiverse-Inventories. If you do not care for the nitty gritty details, this page doesn't contain any necessary information though it may be useful as another way to look at the plugin's usability.
World Groups
- WorldGroups contain a list of worlds and details regarding how Multiverse-Inventories will treat players within, leaving and entering that group of worlds.
- Each WorldGroup has a list of Sharables called shares.
- A Sharable is a thing (statistics mostly) that remains the same for a player when they move between worlds listed in a WorldGroup. A Sharable should really be thought of as that value for purposes of this document.
- A Sharable has two main responsibilities. It saves the appropriate value from the Minecraft player to a profile file and it loads that value from a profile file to the Minecraft player. Read about Share Handling below for more details on this.
- Some Sharables are optional (Such as economy) which are only considered if they're added to the optional shares list (Not covered here.)
- A Sharable can be negative which means a group is specifically NOT sharing that Sharable. This can be useful to share "all" and then simply remove a few instead of listing all but those. Negative Sharables are indicated by a negative symbol (-) in front of the name (example:
-inventory
). This is not to be confused with a yaml list entry (example:- inventory
). - A WorldGroup has an optional "spawn" setting (setup not covered here) which will cause players in that group to respawn at the world listed in the setting.
Share Handling
- Multiverse-Inventories currently ONLY handles world sharing when a player actually changes worlds. (This means they have arrived in the world already.) In other words, it doesn't touch players inventories/stats upon logging in/out.
- No matter what, a backup copy of every Sharable's data is stored in a file for the world the player came from.
- Then, for each of the groups that contain the from world:
- If the group contains the to world, the shares of the group are checked. If the shares contain every Sharable, nothing is done with this groups profile file. Otherwise, we're going to save all the data for each *Sharable that isn't shared with the data from the Minecraft player.
- If the group does not contain the to world then the data for all Sharables is saved to that group's profile file as the player is effectively "leaving the group."
- Then, for each of the groups that contain the to world:
- If the group contains the from world, the shares of the group are checked. If the shares contain every Sharable, nothing is done to the Minecraft player. Otherwise, we're going to load all the data for each Sharable that isn't shared into the Minecraft player
- If the group does not contain the to world then the data for all Sharables is loaded from that group's profile file as the player is effectively "joining the group."
- If, after running the checks on the second set of groups, we have not determined a way to handle all possible Sharables, we will load whatever Sharables that are left over from the profile file for the to world.
Multiverse-Core
Getting Started
Configuration
- Config.yml
- World Properties
- Destinations
- Currency
- Custom Generator Plugins
- Anchor Tutorial
- Placeholders
Help
Developers
Other
Multiverse-Portals
Getting Started
Configuration
Developers
Multiverse-NetherPortals
Getting Started
Configuration
Help
Developers
Multiverse-Inventories
Getting Started
Configuration
Help
Developers
Multiverse-SignPortals
Getting Started
Configuration
A great place to get help is from Multiverse's Discord (Click the logo for invite link):