Download Create Track Map — Minecraft Mods — MetaMods
Create Track Map

Create Track Map

Active

Downloads

48

Last update

2 years ago

Versions

1.18.2 — 1.20.1
Server
Fabric
Forge
Neoforge
Quilt
Utils

Create Track Map

Create Track Map (CTM) is a cross-platform solution that creates an interactive web map of the Create mod's railway system in your Minecraft world. The map displays all tracks, signals, stations, and trains with nearly instant updates of signal states and train movements.

Example track map

How to Use

The mod requires opening an additional port (default 3876) where the web server runs. The map is accessible at the root address (typically http://localhost:3876/).

Installation

Simply place the .jar file in the mods folder, like any other mod. CTM is designed to run on the server side but also works in single-player worlds and local networks.

Singleplayer: The map is hosted on your computer. Open http://localhost:3876/ in your browser while Minecraft is running.

Multiplayer:

  • Local server: Use http://localhost:3876/ or http://[your IPv4 address]:3876/ for other users on your network
  • Server on your PC: Similar to local server, external users can access via your public IP address
  • Hosting provider: The map is hosted with the server, accessible at [server address]:3876/

Advanced Features

CTM API

The mod provides the following API endpoints:

  • /api/network, /api/network.rt - list of all track elements and stations
  • /api/signals, /api/signals.rt - list of signals with their states (green, yellow, red)
  • /api/blocks, /api/blocks.rt - signal control blocks and occupancy information
  • /api/trains, /api/trains.rt - list of all assembled trains with names and positions
  • /api/style.css - CSS style sheet
  • /api/config.json - map configuration

Versions with .rt update in real time via Server-Sent Events.

Configuration

Configuration is located in the create-track-map.json file in the server's config directory. Available options:

{
  // Enable/disable the mod
  "enable": false,

  // Track data update interval
  "watch_interval_seconds": 0.5,
  // Web server port
  "server_port": 3876,

  "map_style": {
    // Font for map interface
    "font": "ui-monospace, \"JetBrains Mono\", monospace",
    // Map element colors
    "colors": {
      "background": "#888",
      "track": {
        "occupied": "red",
        "reserved": "pink",
        "free": "white"
      },
      "signal": {
        "green": "#71db51",
        "yellow": "#ffd15c",
        "red": "#ff5f5c",
        "outline": "black"
      },
      "portal": {
        "primary": "purple",
        "outline": "white"
      },
      "station": {
        "primary": "white",
        "outline": "black"
      },
      "train": "cyan",
      "lead_car": "darkturquoise"
    }
  },

  "map_view": {
    "initial_dimension": "minecraft:overworld",
    "initial_position": { "x": 0, "z": 0 },

    // Zoom levels
    "initial_zoom": 3,
    "min_zoom": 0,
    "max_zoom": 4,

    // Zoom controls
    "zoom_controls": true,

    // Signal display side
    "signals_on": "RIGHT"
  },

  "dimensions": {
    "minecraft:overworld": {
      "label": "Overworld"
    },
    "minecraft:the_nether": {
      "label": "Nether"
    },
    "minecraft:the_end": {
      "label": "End"
    }
  },

  "layers": {
    "tracks": {
      "label": "Tracks",
      "min_zoom": 0,
      "max_zoom": 4
    },
    "blocks": {
      "label": "Track Occupancy",
      "min_zoom": 0,
      "max_zoom": 4
    },
    "signals": {
      "label": "Signals",
      "min_zoom": 0,
      "max_zoom": 4
    },
    "portals": {
      "label": "Portals",
      "min_zoom": 0,
      "max_zoom": 4
    },
    "stations": {
      "label": "Stations",
      "min_zoom": 0,
      "max_zoom": 4
    },
    "trains": {
      "label": "Trains",
      "min_zoom": 0,
      "max_zoom": 4
    }
  }
}

To reload configuration without restarting the server, run the /ctm reload command (operator permissions required).

Project members
littlechasiu

littlechasiu

Developer

Created: 9 Mar 2023

ID: 1692