advtrains_netmapper
is an external program that reads the advtrains node database as well as the train save file. It uses these to produce a map of the railway network in a minetest world. It is written in Lua 5.1, so it is not compatible with 5.2 or above. You will need a command line lua interpreter to run it, available from the Lua project, from the LuaJIT project, or through your package manager on linux.
netmapper produces an SVG file that shows the straight and curved sections of tracks and shades them from blue to red (by default) in ascending height (y-coordinate). It also draws yellow or dark green circles at the front of trains and black text to indicate their Line Number property next to that circle. You can optionally overlay it on the output of another program like mtmapper for a complete map.
main.lua [-m file] [-t] [-w file] <datapath> <datapath> represents the path to your minetest world. -m, --map-file Only draw trains, requires an already-drawn file to draw on top of -t, --no-trains Do not draw trains -w, --world-image Add a background world image. This is an external image, e.g. from mtmapper that will be linked in the SVG output.
Output will always be to <datapath>/out.svg
. netmapper will always clobber (replace) any existing file there.
Using the luajit interpreter, run netmapper on the world 'ILikeTrains'
luajit main.lua ~/minetest/worlds/ILikeTrains/
Blockhead's Fork (repository) draws linetrack watertrack, draws TCBs perpendicular to the track at the position, draws track numbers on station/stop rail text, attempts to scrape and draw some atlatc stations, and has some other refactoring.
Unfortunately, this fork hasn't yet been updated for LuaSer / format, the format used used since Advtrains 2.2.0.