We're back, baby!

Fast Rails v2

After about 5 hours of command block copy-pasta, I've created a stable, reliable form of rail acceleration.
- it works by detecting "marker blocks" under the rails. In the screenshot, the markers are gold and gold ore blocks
- gold block marks acceleration over the next straight section, up until the two gold ore blocks. 
- it only works for straight sections. New marker blocks need to be re-applied after corners.
- it is tag based, meaning that only minecarts on STA will be affected.
- it is completely player-independent, meaning that all tags are info are stored on minecarts.
- acceleration can potentially support slopes and diagonals, but it requires more copy pasting.
- confirmed to be multiplayer-compatible as I tested the track with multiple creepers.
- since the command ties to minecarts, the rider, be it a mob or a player, doesn't matter.
- if an accident happens, the player can simply hop out and re-place the cart to refresh the tags.
- the only possible accidents are derailing at junctions and getting stuck in the wrong direction.
- simply don't let carts speed through junctions, only place markers at straight sections.
- directions should not be a problem since Andy's STA mod removes friction.
- it accelerates to 20 blocks/second, however can be modified to support 40, 60 or 80.
- the carts never derail if marked properly.
- it uses a coordinate system to create the illusion of fast movement, so the speed of carts are unchanged.
- tags can be erased by a single command block on detector rail at the stations. This is mostly a fail-safe, but any special carts with STA-routing tags will also be wiped. Use with caution.
- it currently only accelerates carts on regular tracks, but with copy-paste can support any type of rail.

Here are the command blocks:
image
The left column are the accelerators, commands in order are:

/execute @e[type=MinecartRideable,tag=westFast] ~ ~ ~ detect ~ ~ ~-1 minecraft:rail 0 /tp @e[type=MinecartRideable,r=1] ~ ~ ~-1

/execute @e[type=MinecartRideable,tag=southFast] ~ ~ ~ detect ~1 ~ ~ minecraft:rail 1 /tp @e[type=MinecartRideable,r=1] ~1 ~ ~

/execute @e[type=MinecartRideable,tag=eastFast] ~ ~ ~ detect ~ ~ ~1 minecraft:rail 0 /tp @e[type=MinecartRideable,r=1] ~ ~ ~1

/execute @e[type=MinecartRideable,tag=northFast] ~ ~ ~ detect ~-1 ~ ~ minecraft:rail 1 /tp @e[type=MinecartRideable,r=1] ~-1 ~ ~

The center column are the start-marker detectors, commands are:

/execute @e[type=MinecartRideable,tag=!eastFast] ~ ~ ~ detect ~ ~-1 ~-1 minecraft:gold_block 0 /scoreboard players tag @e[type=MinecartRideable,r=1,tag=!westFast] add westFast

/execute @e[type=MinecartRideable,tag=!northFast] ~ ~ ~ detect ~1 ~-1 ~ minecraft:gold_block 0 /scoreboard players tag @e[type=MinecartRideable,r=1,tag=!southFast] add southFast

/execute @e[type=MinecartRideable,tag=!westFast] ~ ~ ~ detect ~ ~-1 ~1 minecraft:gold_block 0 /scoreboard players tag @e[type=MinecartRideable,r=1,tag=!eastFast] add eastFast

/execute @e[type=MinecartRideable,tag=!southFast] ~ ~ ~ detect ~-1 ~-1 ~ minecraft:gold_block 0 /scoreboard players tag @e[type=MinecartRideable,r=1,tag=!northFast] add northFast

The right column are the end-marker detectors (green blocks), commands are:

/execute @e[type=MinecartRideable] ~ ~ ~ detect ~ ~-1 ~-1 minecraft:gold_ore 0 /scoreboard players tag @e[type=MinecartRideable,r=1] remove westFast

/execute @e[type=MinecartRideable] ~ ~ ~ detect ~1 ~-1 ~ minecraft:gold_ore 0 /scoreboard players tag @e[type=MinecartRideable,r=1] remove southFast

/execute @e[type=MinecartRideable] ~ ~ ~ detect ~ ~-1 ~1 minecraft:gold_ore 0 /scoreboard players tag @e[type=MinecartRideable,r=1] remove eastFast

/execute @e[type=MinecartRideable] ~ ~ ~ detect ~-1 ~-1 ~ minecraft:gold_ore 0 /scoreboard players tag @e[type=MinecartRideable,r=1] remove northFast

The station command block that clears tags contains:

entitydata @e[type=MinecartRideable,r=1] {Tags:[]}

Here's the test track:
image
Gold blocks indicate acceleration towards gold ores.

Here's the test track in stress test:
image
The creepers have been going on their accelerated loopy journey throughout the duration of me writing this post.

Note about lag: shouldn't be an issue as long as the command block output is set to X. 8 repeating command blocks is miniscule.
CoffeeAndChill

Comments

  • is it just one set of command blocks for the entire world & if their chunk gets unloaded, then will they stop working?
  • I tried to set this up and I can't get it to work. I'll show you next time we're on together

    image
  • edited December 2016
    Supposedly it works regardless of distance, even if the player is in the nether.
    A way to debug it is to place down a gold block, put a named minecart beside it, do 
    /scoreboard tag players <name> list
    and see if you have a tag called <...>Fast
    If you don't, scoreboards ain't working. If you do then it's the fault of the teleporter.
    CoffeeAndChill
  • Thank you, I'll have a look when I'm free! :) 
    Long drive today :'(
  • edited October 8
    Sooooo 1.13 killed this, and I've been taking a look.

    Tried to rewrite the westHyper commands, however that is affecting every direction and treating it as if it was a westhyper cart. ie you go eastbound towards a diamond block under you, and it flings you back to the west.
    execute as @e[type=minecart,tag=!eastHyper] at @s if block ~-1 ~-1 ~ minecraft:diamond_ore run tag @s[tag=!westHyper] add westHyper
    
    execute as @e[type=minecart,tag=westHyper] at @s if block ~-3 ~ ~ minecraft:rail run teleport @s ~-3 ~ ~
    
    execute as @e[type=minecart] at @s if block ~-1 ~-1 ~ minecraft:lapis_ore run tag @s remove westHyper
    
    EnderKillaWuggeh0Narcs121
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Railway Status

To plan your journey, click here.

All lines are currently part-suspended due to the 1.13 update breaking everything.

AetherGood service Venice-Ivory Beach. No service Ivory Beach-Groenevelden.
CereliaNo service SEAC - Lord Temple due to ongoing signalling faults. Good service on rest of line.
DulciaGood service
EmpirePart-suspended. Good service Sunspear-Venice, and good service Cactus County-Baba South. No other services are operational.
FrancoGood service Venezia Cipriana - Lythia University. No service Lythia-Epsilon.
HestiaGood service
HyperloopGood service on all routes.
JurisGood service
LamiaGood service
NSTAMajor renovations; expect delays.
NysaNuovo Firenze station is closed. Otherwise, good service.
Phobean S'wayGood service
QuintusGood service
SkiraGood service
ThuleGood service Drosvenar—Ionia, good service Hobbiton-Modaora High Level. No service on rest of line.
Vnz OvergroundGood service on all routes.
Venezia MetroGood service Valeria-Biblioteca via Giardino. No service on other routes.
ZelosGood service.
West Shire RailGood service Nobityo-Solentse, UoC West-Thothum, Zege-Groenevelden, and Groenevelden-Amica.
Last updated 1 September 2018 02:07 UTC