Stargate - Revived | Teleport on your Mount | For Spigot 1.18+1.19 | Now with RGB icon

Stargate - Revived | Teleport on your Mount | For Spigot 1.18+1.19 | Now with RGB -----

The old Stargate plugin, for modern Minecraft servers. Now with more features!



Commands
Stargate doesn't have a lot of commands, but here's a little guide of the few that exist.

Command | Permission | Description
/sg | None | Displays the plugin version
/sg about | None | Displays some information about the plugin
/sg reload | stargate.admin.reload | Reloads the config from disk
/sg config | stargate.admin.config | Changes a config value

Permissions
All permission nodes

Here's a list of all available permissions with usage information:

Code (Text):

stargate.use -- Allow use of all Stargates linking to any world in any network (Override ALL network/world permissions. Set to false to use network/world specific permissions)
  stargate.world -- Allow use of Stargates linking to any world
    stargate.world.{world} -- Allow use of Stargates with a destination in {world}. Set to false to disallow use.
  stargate.network -- Allow use of Stargates on all networks
    stargate.network.{network} -- Allow use of all Stargates in {network}. Set to false to disallow use.
  stargate.server -- Allow use of Stargates going to all servers
    stargate.server.{server} -- Allow usee of all Stargates going to {server}. Set to false to disallow use.
 
stargate.option -- Allow use of all options
  stargate.option.hidden -- Allow use of 'H'idden
  stargate.option.alwayson -- Allow use of 'A'lways-On
  stargate.option.private -- Allow use of 'P'rivate
  stargate.option.free -- Allow use of 'F'ree
  stargate.option.backwards -- Allow use of 'B'ackwards
  stargate.option.show -- Allow use of 'S'how
  stargate.option.nonetwork -- Allow use of 'N'oNetwork
  stargate.option.random -- Allow use of 'Random' stargates
  stargate.option.silent -- Allow use of S'i'lent stargates
  stargate.option.nosign -- Allow use of 'E' (No sign)
 
stargate.create -- Allow creating Stargates on any network (Override all create permissions)
  stargate.create.personal -- Allow creating Stargates on network {playername}
  stargate.create.network -- Allow creating Stargates on any network
    stargate.create.network.{networkname} -- Allow creating Stargates on network {networkname}. Set to false to disallow creation on {networkname}
  stargate.create.gate -- Allow creation using any gate layout
    stargate.create.gate.{gatefile} -- Allow creation using only {gatefile} gates

stargate.destroy -- Allow destruction of Stargates on any network (Orderride all destroy permissions)
  stargate.destroy.personal -- Allow destruction of Stargates owned by the player only
  stargate.destroy.network -- Allow destruction of Stargates on any network
    stargate.destroy.network.{networkname} -- Allow destruction of Stargates on network {networkname}. Set to false to disallow destruction of {networkname}

stargate.free -- Allow free use/creation/destruction of Stargates
  stargate.free.use -- Allow free use of Stargates
  stargate.free.create -- Allow free creation of Stargates
  stargate.free.destroy -- Allow free destruction of Stargates
 
stargate.admin -- Allow all admin features (Hidden/Private bypass, BungeeCord, Reload, Config)
  stargate.admin.private -- Allow use of Private gates not owned by user
  stargate.admin.hidden -- Allow access to Hidden gates not ownerd by user
  stargate.admin.bungee -- Allow the creation of BungeeCord stargates (U option)
  stargate.admin.reload -- Allow use of the reload command
  stargate.admin.config -- Allows the player to change config values from the chat
  stargate.admin.dye -- Alows this player to change the dye of any stargate's sign
 
Default permissions

The default permissions are as follows:


Code (Text):
stargate.use -- Everyone
stargate.create -- Op
stargate.destroy -- Op
stargate.option -- Op
stargate.free -- Op
stargate.admin -- Op

Configuration
Configuration values
Code (Text):
language - The language to use (Included languages: en, de, es, fr, hu, it, ja, nb-no, nl, nn-no, pt-br, ru, zh_cn)
folders:
  portalFolder - The folder your portal databases are saved in
  gateFolder - The folder containing your .gate files
gates:
  maxGatesEachNetwork - If non-zero, will define the maximum amount of gates allowed on any network.
  defaultGateNetwork - The default gate network
  exitVelocity - The velocity to give players exiting stargates, relative to the entry velocity (1 = same as entry velocity)
  cosmetic:
    rememberDestination - Whether to set the first destination as the last used destination for all gates
    sortNetworkDestinations - If true, network lists will be sorted alphabetically.
    mainSignColor - This allows you to specify the color of the gate signs. Use a color code such as WHITE,BLACK,YELLOW or a hex color code such as '#ed76d9'. You need quotes around hex color codes.
    highlightSignColor - This allows you to specify the color of the sign markings. Use a color code such as WHITE,BLACK,YELLOW or a hex color code such as '#ed76d9'. You need quotes around hex color codes.
    perSignColors: - A list of per-sign color specifications. Format: "SIGN_TYPE:mainColor,highlight_color". The SIGN_TYPE is OAK for an oak sign, DARK_OAK for a dark oak sign and so on. The colors can be "default" to use the color specified in "mainSignColor" or "highlightSignColor", "inverted" to use the inverse color of the default color, a normal color such as BLACK,WHITE,YELLOW or a hex color code such as #ed76d9.
  integrity:
    destroyedByExplosion - Whether to destroy a stargate with explosions, or stop an explosion if it contains a gates controls.
    verifyPortals - Whether or not all the non-sign blocks are checked to match the gate layout when an old stargate is loaded at startup.
    protectEntrance - If true, will protect from users breaking gate entrance blocks (This is more resource intensive than the usual check, and should only be enabled for servers that use solid open/close blocks)
  functionality:
    enableBungee - Enable this for BungeeCord support. This allows portals across Bungee servers.
    handleVehicles - Whether or not to handle vehicles going through gates. Set to false to disallow vehicles (Manned or not) going through gates.
    handleEmptyVehicles - Whether or not to handle empty vehicles going through gates (chest/hopper/tnt/furnace minecarts included).
    handleCreatureTransportation - Whether or not to handle players that transport creatures by sending vehicles (minecarts, boats) through gates.
    handleNonPlayerVehicles - Whether or not to handle vehicles with a passenger which is not a player going through gates (pigs, horses, villagers, creepers, etc.). handleCreatureTransportation must be enabled.
    handleLeashedCreatures - Whether or not to handle creatures leashed by a player going through gates. Set to false to disallow leashed creatures going through gates.
  enableCraftBookRemoveOnEjectFix - Whether to enable a fix that causes loss of NBT data, but allows vehicle teleportation to work when CraftBook's remove minecart/boat on eject setting is enabled
economy:
  useEconomy - Whether or not to use Economy
  createCost - The cost to create a stargate
  destroyCost - The cost to destroy a stargate (Can be negative for a "refund"
  useCost - The cost to use a stargate
  toOwner - Whether the money from gate-use goes to the owner or nobody
  chargeFreeDestination - Enable to make players pay for teleportation even if the destination is free
  freeGatesColored - Enable to make gates that won't cost the player money show up as green
  freeGatesColor - This allows you to specify the color of the markings and name of free stargates
debugging:
  debug - Whether to show massive debug output
  permissionDebug - Whether to show massive permission debug output
advanced:
  waitForPlayerAfterTeleportDelay - The amount of ticks to wait before adding a player as passenger of a vehicle. On slow servers, a value of 6 is required to avoid client glitches after teleporting on a vehicle.
dynmap:
  enableDynmap - Whether to display Stargates in Dynmap
  dynmapIconsHiddenByDefault - Whether to hide Stargates in Dynmap unless a user manually enables them.
Vehicle teleportation options
  • handleVehicles disables all vehicle teleportation, no matter what, if disabled
  • handleEmptyVehicles disables teleportation of all vehicles without a passenger if disabled. This also disables teleportation of chest/hopper/tnt/furnace minecarts.
  • handleCreatureTransportation disables all teleportation of non-players if disabled. This prevents players from using boats or minecarts to transport pigs, creepers, pandas, etc. through stargates
  • handleNonPlayerVehicles disables all teleportation of vehicles containing one or more passengers, none of which is a player. As permissions for teleportation cannot be checked unless a player is teleporting, disabling this will prevent any bypassing of permissions by creatures. This will still allow players to transport creatures using boats, as the player controlling the boat can authorize the teleportation.

Gates

Creating a stargate
Building a gate:

There are currently three default gate configurations. They all use the same structure as a standard nether portal. One
gate is using obsidian blocks, one is using end bricks and the last uses sea lanterns. Only the sea lantern one can be
used underwater. You must put a sign on one of the blocks in the middle of the layout to activate the portal (see next
section). See the Custom Gate Layout section to learn how to add custom gates.

Code (Text):
    OO
   O  O - These are Obsidian blocks, End bricks or Sea Lanterns. You need 10.
   O  O - Place a sign on either of these two middle blocks.
   O  O
    OO

Sign Layout:

- Line 1: Gate Name (Max 13 characters)
- Line 2: Destination Name [Optional] (Max 13 characters, used for fixed-gates only)
- Line 3: Network name [Optional] (Max 13 characters)
- Line 4: Options [Optional] :
- 'A' for always-on fixed gate
- 'H' for hidden networked gate
- 'P' for a private gate
- 'F' for a free gate
- 'B' is for a backwards facing gate (You will exit the back)
- 'S' is for showing an always-on gate in the network list
- 'N' is for hiding the network name
- 'R' is for random gates. These follow standard permissions of gates, but have a random exit location every time a
player enters. (Implicitly always on)
- 'U' is for a gate connecting to another through bungee (Implicitly always on)
- 'I' is for a silent gate, which does not output anything to the chat while teleporting. Increases immersion
- 'E' is for a gate without a sign. Only for fixed stargates

The options are the single letter, not the word. So to make a private hidden gate, your 4th line would be 'PH'. The
&[0-9a-f] color codes are not counted in the character limit, thus allowing a 13-character name with an additional 2
characters used for the color code.

Gate networks:


- Gates are all part of a network, by default this is "central".
- You can specify (and create) your own network on the third line of the sign when making a new gate.
- Gates on one network will not see gates on the second network, and vice versa.
- Gates on different worlds, but in the same network, will see each other.
- If the gate is a bungee gate, the network name should be the name of the server as displayed when typing /servers

Fixed gates:

- Fixed gates go to only one set destination.
- Fixed gates can be linked to other fixed gates, or normal gates. A normal gate cannot open a portal to a fixed gate,
however.
- To create a fixed gate, specify a destination on the second line of the stargate sign.
- Set the 4th line of the stargate sign to "A" to enable an always-open fixed gate.
- A bungee gate is always automatically a fixed gate

Hidden Gates:

- Hidden gates are like normal gates, but only show on the destination list of other gates under certain conditions.
- A hidden gate is only visible to the creator of the gate, or somebody with the stargate.hidden permission.
- Set the 4th line of the stargate sign to 'H' to make it a hidden gate.

Using a stargate
- Right-click the sign to choose a destination.
- Right-click the button to open up a portal.
- Step through.

For stargates with only one destination, you only need to click the button.
For stargates which are always on, you just need to enter the stargate.

Creating a Custom Gate Layout
You can create as many gate formats as you want, the gate layouts are stored in plugins/Stargate/gates/.
The .gate file must be laid out a specific way, the first lines will be config information, and after a blank line you
will lay out the gate format. Here is the default nethergate.gate file:


Code (Text):
portal-open=NETHER_PORTAL
portal-closed=AIR
button=STONE_BUTTON
usecost=0
createcost=0
destroycost=0
toowner=false
X=OBSIDIAN
-=OBSIDIAN

 XX
X..X
-..-
X*.X
 XX
The keys portal-open and portal-closed are used to define the material in the gate when it is open or closed. The
material for portal-closed can be most things, including solid blocks. Some materials may act weirdly though. The
material for portal-open can be any block the player can partially enter, even things like GLOW_LICHEN.
NETHER_PORTAL, END_GATEWAY and END_PORTAL all work.

The usecost, createcost and destroycost keys can be used to set an economy price for gates of this type, different
from the cost defined in the config. With economy enabled, all gates without these values set will use the values from
the config. If you want to have different costs for different portals, you must create different gate types and set
different costs for each one. The toowner key can be used to set whether funds withdrawn for using portals with this
gate type should go to the portal's owner.

The key button is used to define the type of button that is generated for this gate. It can be a button (of any type),
a type of wall coral (dead or alive), a type of shulker box or a chest.

X and - are used to define block types for the layout (Any single-character can be used, such as #).
In the gate format, you can see we use X to show where obsidian must be, - where the controls (Button/sign) are.

For more complex gate designs, it is possible to add more materials. If you add something like a=GLOWSTONE, a can then
be used in the gate layout, just as X is used. See the squarenetherglowstonegate.gate file for an example.

You will also notice a * in the gate layout, this is the "exit point" of the gate, the block at which the player will
teleport in front of.

Buttons

The actual buttons cannot be used underwater, but all the other items in the button list can be:

Code (Text):
STONE_BUTTON
OAK_BUTTON
SPRUCE_BUTTON
BIRCH_BUTTON
JUNGLE_BUTTON
ACACIA_BUTTON
DARK_OAK_BUTTON
CRIMSON_BUTTON
WARPED_BUTTON
POLISHED_BLACKSTONE_BUTTON

CHEST
TRAPPED_CHEST
ENDER_CHEST
SHULKER_BOX
WHITE_SHULKER_BOX
ORANGE_SHULKER_BOX
MAGENTA_SHULKER_BOX
LIGHT_BLUE_SHULKER_BOX
YELLOW_SHULKER_BOX
LIME_SHULKER_BOX
PINK_SHULKER_BOX
GRAY_SHULKER_BOX
LIGHT_GRAY_SHULKER_BOX
CYAN_SHULKER_BOX
PURPLE_SHULKER_BOX
BLUE_SHULKER_BOX
BROWN_SHULKER_BOX
GREEN_SHULKER_BOX
RED_SHULKER_BOX
BLACK_SHULKER_BOX
TUBE_CORAL_WALL_FAN
BRAIN_CORAL_WALL_FAN
BUBBLE_CORAL_WALL_FAN
FIRE_CORAL_WALL_FAN
HORN_CORAL_WALL_FAN
DEAD_TUBE_CORAL_WALL_FAN
DEAD_BRAIN_CORAL_WALL_FAN
DEAD_BUBBLE_CORAL_WALL_FAN
DEAD_FIRE_CORAL_WALL_FAN
DEAD_HORN_CORAL_WALL_FAN
Underwater Portals

There is a default gate type for underwater gates. There are no real restrictions on underwater gate materials, except
normal buttons cannot be used since they'd fall off. Using wall coral fans work much better, though CHEST and
SHULKER_BOX works too.

Using AIR for a closed underwater gate looks weird, so WATER might be better. If using AIR for the closed gate,
you need to make sure it actually contains air when creating it. For partially submerged portals, like ones used for
boat teleportation, you need to keep water away from the portal entrance/opening until it's been created.

Economy Support

The latest version of Stargate has support for Vault. Gate creation, destruction and use can all have different costs
associated with them. You can also define per-gate layout costs. The default cost is assigned in the config.yml file,
while the per-gate costs re defined in the .gate files. To define a certain cost to a gate just add these lines to your
.gate file:

Code (Text):

  createCost: 5 -- Will cost 5 currency to create
  destroyCost: 5 -- Will clost 5 currency to destroy (negative to get back the spent money)
  useCost: 5 -- Will cost 5 currency to use the stargate
  toOwner: true -- Will send any fees to the gate's owner

Coloring
Some coloring options are available. The general text color can be changed, and names and networks can be colored individually

Coloring of general text
The main config contains the option "gates.cosmetic.mainSignColor" which defines the main color used for signs. This set to BLACK by default. There is also and option "gates.cosmetic.highlightSignColor" which allows you to set the color of the highlighting characters on the portal sings. You can set the two to the same color if you don't like the highlighting.

It's also possible to set the main and highlighting colors on a per-sign basis. This is done through the "gates.cosmetic.perSignColors" list. The format is "SIGN_TYPE:MAIN_COLOR,HIGHLIGHT_COLOR". It's recommended to change the values through the /sg config command to avoid errors.

If using economy, the option "economy.freeGatesColored" can be used to enable a different color to be used for the markings and name of free stargates. Which color to be used can be set using the "economy.freeGatesColor" option.

The available chat colors are: AQUA, BLACK, BLUE, DARK_AQUA, DARK_BLUE, DARK_GRAY, DARK_GREEN, DARK_PURPLE, DARK_RED, GOLD, GRAY, GREEN, LIGHT_PURPLE, RED, WHITE, YELLOW.
Additionally, any hex color code, such as #ed76d9 can be used.

Dye can be applied to a sign. The main color will be overwritten by the dye color, and the highlighting color will be the inverse of the dye color. Glow ink sacs can be used to add a glowing effect to the sign.

Coloring of gate names and networks
The color of gate names and network names can be set by using the '&' character followed by the character defining the color (a-f, 0-9), or by using a hex code such as #ed76d9.

Message Customization
It is possible to customize all the messages Stargate displays, including the [Stargate] prefix. You can find the
strings in plugins/Stargate/lang/chosenLanguage.txt.

If a string is removed, or left blank, it will default to the default english string. There are some special cases
regarding messages. When you see %variableName%, you need to keep this part in your string, as it will be replaced with
relevant values.

The full list of strings is as follows:


Code (Text):
prefix=[Stargate]
teleportMsg=Teleported
destroyMsg=Gate Destroyed
invalidMsg=Invalid Destination
blockMsg=Destination Blocked
destEmpty=Destination List Empty
denyMsg=Access Denied
reloaded=Stargate Reloaded

ecoDeduct=Deducted %cost%
ecoRefund=Refunded %cost%
ecoObtain=Obtained %cost% from Stargate %portal%
ecoInFunds=Insufficient Funds
ecoLoadError=Vault was loaded, but no economy plugin could be hooked into
vaultLoadError=Economy is enabled but Vault could not be loaded. Economy disabled
vaultLoaded=Vault v%version% found

createMsg=Gate Created
createNetDeny=You do not have access to that network
createGateDeny=You do not have access to that gate layout
createPersonal=Creating gate on personal network
createNameLength=Name too short or too long.
createExists=A gate by that name already exists
createFull=This network is full
createWorldDeny=You do not have access to that world
createConflict=Gate conflicts with existing gate

signRightClick=Right click
signToUse=to use gate
signRandom=Random
signDisconnected=Disconnected
signInvalidGate=Invalid gate

bungeeDisabled=BungeeCord support is disabled.
bungeeDeny=You do not have permission to create BungeeCord gates.
bungeeEmpty=BungeeCord gates require both a destination and network.
bungeeSign=Teleport to

portalInfoTitle=[STARGATE INFO]
portalInfoName=Name: %name%
portalInfoDestination=Destination: %destination%
portalInfoNetwork=Network: %network%
portalInfoServer=Server: %server%

API
Stargate has an API which allows other plugins to interact with available events.
Here is an overview of how the different events can be used:
  • The StargateAccessEvent is called whenever a player clicks a stargate's sign, and when a player enters a Stargate. It can be used to override whether the access should be allowed or denied.
  • The StargateActivateEvent is called whenever a player activates a stargate (uses the stargate's sign). It can be used to override which destinations are available to the player.
  • The StargateCloseEvent is called whenever a stargate is closed. Forcing the stargate closed can be toggled.
  • The StargateCreateEvent is called whenever a new stargate is created. Its deny value can be overridden, the cost can be changed
  • The StargateDeactivateEvent is called whenever a stargate is deactivated.
  • The StargateDestroyEvent is called whenever a stargate is destroyed. Its deny value can be overridden or the cost can be changed.
  • The StargateEntityPortalEvent is called whenever an entity teleports through a stargate. The exit location can be changed.
  • The StargateOpenEvent is called whenever a stargate is opened. Forcing the stargate open can be toggled.
  • The StargatePlayerPortalEvent is called whenever a player teleports through a stargate. The exit location can be changed.
Resource Information
Author:
----------
Total Downloads: 1,761
First Release: Nov 21, 2021
Last Update: Apr 19, 2023
Category: ---------------
All-Time Rating:
4 ratings
Find more info at git.knarcraft.net...
Version -----
Released: --------------------
Downloads: ------
Version Rating:
----------------------
-- ratings