Linked Portals
Next-Generation Portals
This is a server-side modification for organizing portal systems. The mod's capabilities are under active development, so if you discover any issues, be sure to report them.
Core Functionality
Portal Linking
Each portal requires a specific item for activation. All portals using identical items with matching characteristics automatically connect with each other. You can customize item names and add custom model data to create different connection groups.
Consider this example:
- Portal A uses Paper named "Nether Gates"
- Portal B uses regular Paper without a name
- Portal C uses Paper named "Nether Gates"
Portals A and C form a connected pair, while Portal B remains isolated. Using an unlinked portal may lead to unexpected consequences.
Locking System
Portal types that support locking can be protected by sneaking and using the control block. Items cannot be removed from locked controllers. Players with appropriate permissions can lock any portal controller, regardless of its type. By default, access management is handled through the following permission systems:
- In single-player mode
- Server operators
- linkedportals.masterkey permission nodes when using mods like LuckPerms
Datapack Configuration
Block Tags:
linkedportals:valid_frames- identifies valid blocks for creating frames of standard portal typeslinkedportals:portal_controller_base- identifies blocks that can be converted into portal control blocks. Destroying a controller returns the original block
Item Tags:
linkedportals:valid_activators- identifies items that are consumed when converting base blocks into controllers
Portal Types:
Portal type configurations are stored in JSON files at the path data/<namespace>/linkedportals/types/<portal_type_name>.json. Each portal type is created in a separate file. The standard portal type can be disabled by overriding the default.json file or replacing the linkedportals:valid_frames tag with an empty tag.
When checking valid frames and interior blocks, test rules are used that support any custom tests. The most common are block_match, blockstate_match, and tag_match.
Main configuration parameters:
valid_frame_rule- rule for checking frame block validityvalid_interior_rule- rule for checking interior blocks (default - air)size_limit- maximum frame size limit for width and height (default 21)lockable- ability for players to lock portals (default true)
Configuration format example:
{
"valid_frame_rule": {
"predicate_type": "minecraft:tag_match",
"tag": "linkedportals:valid_frames"
},
"valid_interior_rule": {
"predicate_type": "minecraft:blockstate_match",
"block_state": {
"Name": "minecraft:air"
}
},
"size_limit": 21,
"lockable": false
}