Encrypted-Thoughts / DimensionPortalLinker

Fabric mod that lets you configure how end and nether portals work in custom dimensions instead of just being disabled.
MIT License
3 stars 0 forks source link
fabric minecraft minecraft-mod

Dimension Portal Linker

License Version Downloads

By default nether and end portals only work in the regular overworld, nether, and end. This mod adds the ability to enable them to work in custom dimensions by mapping which portal should go to which dimension via a config file.

Mostly made to be used in concert with my bingo mod so that it can have multiple different types of playable dimensions where the portals still work and link up correctly with nether and end dimensions that I want.

Each defined dimension has 10 potentials properties:

Currently the dragon fight doesn't work in custom end dimensions so you'll need to manually place a portal to return back to the overworld as it won't spawn naturally.

Commands (OP ONLY)

/portalLinker

Display the current settings for all dimensions.

/portalLinker save

Save the current defined settings to the config so they'll apply on a server restart.

/portalLinker [dimension]

Display the current settings for the selected dimension.

/portalLinker [dimension] netherPortal [enabled] [destinationDimension]

Configure whether nether portals are enabled and where the portal takes you for the selected dimension.

/portalLinker [dimension] endPortal [enabled] [destinationDimension]

Configure whether end portals are enabled and where the portal takes you for the selected dimension.

/portalLinker [dimension] spawn [overrideWorldSpawn] [overridePlayerSpawn] [spawnDimension] [spawnPoint]

Configure whether world spawn and/or player spawns should be overriden while in the specified dimension. Determines where end portals in an end dimension take entities along with where players go if they die.

Example config for my Bingo server (portal_linker.json)

{
  "Dimensions": [
    {
      "Dimension": "minecraft:overworld",
      "Type": "minecraft:overworld",
      "IsNetherPortalEnabled": true,
      "NetherPortalDestinationDimension": "minecraft:the_nether",
      "IsEndPortalEnabled": true,
      "EndPortalDestinationDimension": "minecraft:the_end",
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "minecraft:the_nether",
      "Type": "minecraft:the_nether",
      "IsNetherPortalEnabled": true,
      "NetherPortalDestinationDimension": "minecraft:overworld",
      "IsEndPortalEnabled": false
    },
    {
      "Dimension": "minecraft:the_end",
      "Type": "minecraft:the_end",
      "IsNetherPortalEnabled": false,
      "IsEndPortalEnabled": true,
      "EndPortalDestinationDimension": "minecraft:overworld",
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "bingo:duplicate_overworld",
      "Type": "minecraft:overworld",
      "IsNetherPortalEnabled": true,
      "NetherPortalDestinationDimension": "bingo:duplicate_nether",
      "IsEndPortalEnabled": true,
      "EndPortalDestinationDimension": "bingo:duplicate_end",
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "bingo:duplicate_nether",
      "Type": "minecraft:the_nether",
      "IsNetherPortalEnabled": true,
      "NetherPortalDestinationDimension": "bingo:duplicate_overworld",
      "IsEndPortalEnabled": false
    },
    {
      "Dimension": "bingo:duplicate_end",
      "Type": "minecraft:the_end",
      "IsNetherPortalEnabled": false,
      "IsEndPortalEnabled": true,
      "EndPortalDestinationDimension": "bingo:duplicate_overworld",
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "bingo:tiny_biomes_overworld",
      "Type": "minecraft:overworld",
      "IsNetherPortalEnabled": true,
      "NetherPortalDestinationDimension": "bingo:tiny_biomes_nether",
      "IsEndPortalEnabled": true,
      "EndPortalDestinationDimension": "bingo:tiny_biomes_end",
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "bingo:tiny_biomes_nether",
      "Type": "minecraft:the_nether",
      "IsNetherPortalEnabled": true,
      "NetherPortalDestinationDimension": "bingo:tiny_biomes_overworld",
      "IsEndPortalEnabled": false,
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "bingo:tiny_biomes_end",
      "Type": "minecraft:the_end",
      "IsNetherPortalEnabled": false,
      "IsEndPortalEnabled": true,
      "EndPortalDestinationDimension": "bingo:tiny_biomes_overworld",
      "OverrideWorldSpawn": false,
      "OverridePlayerSpawn": false
    },
    {
      "Dimension": "dream:creative_superflat",
      "Type": "minecraft:overworld",
      "IsNetherPortalEnabled": false,
      "IsEndPortalEnabled": false,
      "OverrideWorldSpawn": true,
      "OverridePlayerSpawn": true,
      "SpawnDimension": "dream:creative_superflat",
      "SpawnPoint": "0, 100, 0"
    }
  ]
}