Visualization for safehouses in The Long Dark. This is a work in progress!
The purpose of this vizualizer is to give a bird's eye view of all one's bases in the game. Everything is SVG, meaning you can zoom in and out and the icons will scale nicely.
I'm currently using this vizualizer to keep track of all my bases in my current interloper game. Right now, it looks like:
You can install them with:
pip install drawsvg beautifulsoup
The visualizer takes its data from a JSON file which you provide as a command-line argument. Two example JSON files are provided: mybases.json and loottable4.json.
To run the visualizer: python3 TLDBaseViz.py <inputFile.json>
The input JSON has two sections: a list of bases, and a list of connections between the bases. A small vizualization might look something like this:
In this example, Hibernia, the No 5 Mine, and Lonely Lighthouse have been explored, but the other locations have not, and are hence outlined in purple. Square boxes indicate indoor (warm) locations where one could cure a hide. The opacity of the box's border indicates whether there is safehouse customization. Italics indicate there is no loading screen to access this location. The JSON entry for Hiberina is:
"Hibernia":{
"region": "DesolationPoint",
"customizable": true,
"loading": true,
"cabinfeverrisk":true,
"indoors": true,
"explored":true,
"features": ["salt,beachcombing",
"bed, grill, workbench",
"quality, -hammer",
"#Cannery, +woodworking, +furnbench, +bearbed"
]
},
The icons are specified by the list features: each string is a row, and each string in the list is a column. Every icon has a specified keyword (e.g. salt is for salt deposit). There are three special prefixes:
-is used to indicate something should be taken from this location (e.g.-hammer: you can see the nearby Riken has a+hammershowing where it should go). By default, cyan is used for this.+is used to indicate something should be brought to this location (e.g.+woodworking). By default pink is used for this.#is used to indicate a text box. This is useful for notes for yourself, such as if an item is coming or going far away. In the example above,#Canneryis a note I made to indicate the woodworkng tools are coming from the Cannery.*is used to indicate something should be produced (crafted) for this location (e.g. a furniture workbench).?is used to indicate something should be searched for at this location.
Connections are formatted as a list, and an excerpt looks like this:
["Hibernia", "north", "top,left", "BrokenBridge", "bottom,left", "path"],
["Hibernia", "south", "bottom,left", "Riken", "top,left", "charcoal"],
["Riken", "east", "top,right", "LittleIsland", "top,left", "charcoal"],
["No5Mine", "east", "bottom,right", "Hibernia", "top,left", "path"],
The format goes:
- Name of source base
- Direction from source base to sink (destination) base
- Which corner of the source base's box the connection starts from
- Name of sink base
- Which corner of the sink base's box the connection ends at
- A keyword used to style the connection. For example
pathfor when a connection is readily navigated in low-visibility conditions thanks to a road, railroad, or natural path.
You can change the colour scheme by editing styling.json as desired. A high contrast style file, hicontraststyling.json is also provided.
The order in which you list your bases in the JSON file affects the order in which they are drawn. The program draws bases in this order:
- Draw the first base in the JSON file.
- Draw all of the bases connected to that base.
- Move to the second base in the JSON file. If it isn't already drawn, draw it. Then draw all of the bases connected to it.
- Repeat #3 with the third base, fourth base, etc.
If your bases are appearing in janky locations, you may have to fuss with the order of the bases. If the program gets to a base but has no connections to it so far, it won't know where to put it, and will put it at the location of the first base.
A full legend is avilable in legend.csv.
Green indicates it is not available on interloper/misery.
You can modify legend.csv to remap the keywords and add icons of your own.
If you want to add or modify the SVG icons, please be forewarned that the SVG parser is rather minimal, and presently only supports SVG files which are square in shape, have no layers, no relative paths, and no transformations.
Icons used here are all from The Noun Project unless otherwise noted. They are all Creative Commons licensed.
- Accelerant by AFY Studio
- Antiseptic by projecthayat
- Arrowhead by Manja
- Aviator Cap by madness stock
- Backpack (container) by Andi wyianto
- Balaclava by Juicy Fish
- Ballistic Vest by Smashicons
- Bandage by Side Project
- Barb's Rifle by Hey Rabbit
- Beachcombing by Idwar
- Bear by abdul gofur (also used for bear hunting destination)
- Bear Hide by Yo! Baba
- Bear Hide Bed by Luiz Carvalho
- Bearskin Bedroll by Agan24
- Bearskin Coat based on art by iconcheese, Simon Child, and Roundicons.com
- Bed by Adrien Coquet
- Bedroll by Daniel Shettel
- Birch Bark by Amethyst Studio
- Birch Sapling by endang firmansyah
- Book by Dong Gyu Yang
- Box by Elin Erkani
- Bunker Rifle based on art by ka reemov
- Bushcraft Bow by Mask Icon
- Briefcase based on art by Arkinasi
- Cabinet by sentya irma
- Caffeine Pills by Cards Against Humanity
- Camera by Andi Nur Abdillah
- Can of Gunpowder by fauzan akbar
- Can Opener by Amethyst Studio
- Car Battery by ARI NOFIANA
- Cattail Head by Mohamed Mb
- Cattail Stalk by ghufronagustian
- Cedar Firewood by qubodup [OpenClipArt]
- Charcoal by Vectors Market
- Chemical Boots by monkik
- Climb by Adrien Coquet
- Climbing Rope by IYIKON
- Climbing Socks by Agan24
- Cloth by Rifqi Real
- Coal Piece by Sean Maldjian
- Coal Spawn by BinikSol
- Cookpot by NeueDeutsche
- Combat Boots by Amethyst Studio
- Combat Pants by Amethyst Studio
- Continued on next line by Ine shinta dewi
- Cougar by Sahiruddin
- Cougar Hide by Amir Ali
- Cougar Claw Knife based on art by Abdullah Faisal
- Cougar Hide Wrap based on art by Flowicon
- Cowichan Sweater by ferdizzimo
- Crampons based on art by Vectors Point
- Crow Feather by Abd Majd
- Curator's Rifle by Jarem Frye
- Cured Leather by Amethyst Studio
- Curing Box by Pham Duy Phuong Hung
- Decoration by metami septiana
- Deer by Anissa
- Deer Hide based on art by Smashicons
- Deerskin Boots based on art by Eucalyp
- Deerskin Pants based on art by Jajang Nurrahman
- Distress Pistol by Andy Horvath
- Distress Pistol Ammunition by Dwi Budiyanto
- Drawer (5kg) by Vectors Market
- Drawer (10kg) by Dilon Choudhury
- Dusting Sulfur / Grown Well by Azam Ishaq
- Emergency Stim by Andi Nur Abdillah
- Expedition Parka by Cik merry
- FastFilm-500 by Y
- Firestriker by IconMark
- Firelog by Ronald Cortez
- Fire Hardened Arrow by Zach Bogart
- Firearm Cleaning Kit by Maria AG
- Fist Aid Container by ainul muttaqin
- Fish by BnB Studio
- Fishing Tackle by Aidan Stonehouse
- Fisherman's Sweater by Ayub Irawan
- Fishing Tip-up is original art for this project
- Flare by Side Project
- Flashlight by ajat sudrajat
- Flight Jacket based on art by Zky Icon
- Floor by Free Fair & Healthy
- Food by Abdul Matic
- Forester's Revolver by Hey Rabbit
- Forge by Andi Nur Abdillah
- Freezer by Graphicxs_Art
- Fridge/Oven by Paonkz
- Furniture Workbench by Deni Sudibyo
- Gauntlets based on art by Michael T
- Goating by Nick Novell
- Grill (2-burner stove) by Cuby Design
- Gut by Serena
- Hacksaw by omeneko
- Handheld Shortwave Radio by Uswa KDT
- Harvestable Cloth by Solid Icon Co
- Harvestable Leather by mangunkarsa
- Harvestable Scrap Metal by Slamlabs
- Hatchet by Studio Danro
- Heat Pack by Cattie
- Heavy Hammer by Firza Alamsyah
- Hockey Jersey / Festive Sweater by Andry Horvath
- Hook by Andy Mc
- Hunter's Revolver by Graphic Nehar
- Hunting Knife by icongarage
- Hunting Rifle by Hey Rabbit
- Improvised Crampons based on art by LSE Designs
- Improvised Hatchet by farra nugraha
- Improvised Insulation based on art by Amethyst Stedio
- Improvised Knife based on art by J703
- Insulated Flask by AbtoCreative
- Insulated Boots by Side Project
- Jerry Can by Nikita Kozin
- Lamp by Angriawan Ditya Zulkarnain
- Lantern by Athok
- Lantern Fuel by Justin Blake
- Locker by popcornarts
- Mackinaw Jacket based on art by ToZIcon
- Magnifying Lens by vectaicon
- Manufactured Arrow by Leonardo Henrique Martini
- Maple Sapling by Blaise Sewell
- Marine Flare by Amethyst Studio
- Mariner's Pea Coat by Smallike
- Matches by Zach Bogart
- Metal Container by Amethyst Studio
- Military Coat by Blackonion
- Miner's Flashlight by Amethyst Studio
- Milling Machine by krisna agra muria
- Miner's Pants by pictranoosa
- Moose by pramana
- Moose Hide based on art by Nhor
- Moose-Hide Cloak by Daniela Baptista
- Moose-Hide Satchel by Amethyst Studio
- Mukluks by Eucalyp
- Nearby by Bagus Kusnandar
- Newspaper by Puspa Kusuma
- Noisemaker by Azland Studio
- Oats by Iconiyo
- Old Man's Beard Wound Dressing by Magicon
- Plastic Container by Ranah Pixel Studio
- Poisoned Wolf by icon trip
- Polaroid by Alice Design
- Pot Belly Stove by Andrejs Kirma
- Prybar by Ben Gilman
- Ptarmigan by Amethyst Studio
- Ptarmigan Down by Gan Khoon Lay
- Quality Tools by Asiah
- Rabbit by Logisstudio
- Rabbit Pelt based on art by Eucalpy
- Rabbitskin Hat by DTNS Studio
- Rabbitskin Mittens by Neneng Fadliyah
- Radio by Arif Arisandi
- Range (6-burner stove) by Cuby Design
- Recipe Card by Marianna Nardella
- Reclaimed Wood by Adrien Coquet
- Recycled Can by S. Salinas
- Reishi Mushroom by Amando Hua
- Replacement Fuse by M. Tohirin
- Revolver by Eskak
- Revolver Ammunition by basticon
- Rifle Ammunition by rizal2109
- Rock Cache by kusuma potter
- Rose Hip by T. Kiefer Robertson
- Rug by tezar tantular
- Rustic Storage Box by Marc Anderson
- Safe by Jonn Tronic
- Salt Bag by IconMark
- Salt Deposit by Muhammad Hilmi Fajri
- Salt Shaker by Adrien Coquet
- Scrap Metal by Ivanda Arief Budiarto
- Sewing Kit by iconisme
- Shelf by Creative Stall
- Shelf (wall-attached) by Sembodo Tioss Halala
- Simple Arrow by Sahab Uddin
- Simple Parka by Siipkan Creative
- Simple Tools by fauzin idea
- Ski Boots by Lars Meiertoberens
- Ski Jacket based on art by ToZIcon
- Skillet by icelloid
- Snare by Intervex [Wikimedia Commons]
- Snowpants by Studio365
- Spelunker's Lantern by Teny Septiani
- Sport Bow by TRAVIS BIRD
- Spray Paint by Kemesh Maharjan
- Stick by Delapouite [Wikipedia Commons]
- Stone by Amethyst Studio
- Suitcase by shashank singh
- Survival Bow by Anditii Creative
- Survival Knife by Soremba
- Tactical Gloves modified from art by Abu Ibrahim Icon
- Technical Backpack by johanna
- Technical Balaclava by P Thanga Vignesh
- Thermal Underwear by Ainun Nadliroh
- Thermal Underwear by Edi Prastyo
- Thin Wool Sweater by Jamil Akhtar
- Timberwolf by okja
- Tinder Plug by Rikas Dzihab
- Torch by Darwin Mulya
- Trader by Salman Azzumardi
- Transmitter by IconsHome
- Trash Can by Adeel rehman
- Trunk (rustic) by Annisa
- Trunk (premade) by Chintuza
- Urban Parka by James gibson
- Vaughn's Rife by ka reemov
- Vitamin-C Pills by Studio 365
- Warden's Revolver by Eskak
- Water Bottle by Hilmy Abiyyu Asad
- Whetstone is original art for this project
- Windbreaker by Lars Meiertoberens
- Wires by Marie Van den Broeck
- Wolf by IronSV
- Wolf Hide based on art by Singlar
- Wolfskin Coat by Collicon
- Wolfskin Hat based on art by Amethyst Studio
- Wolfskin Pants modified from art by Jo Santos
- Woodworking Tools by Berkah Icon
- Woodwright's Bow by Simon Henrotte
- Wool Ear Wrap by parkjisun
- Wool Longjohns by Edi Prastyo
- Wool Mittens by Icon Market
- Wool Shirt by Amethyst Studio
- Wool Socks by Pong Pong
- Wool Toque by Flatart
- Workbench by cdesign933
- Workbench Vice by Melisa Lutfiani
- Icons for all accessories
- Separate icon for outdoor workbench?
- Rethink how draw the graph so position doesn't need so much manual tweaking
- Stitch the coord-based maps together. Figure out how to handle the fact that AC-TWM-PV-KP-BRM does not have a shared point with most of island, and that HRV and DP are similarly only accessed via caves.
- Visualize bases on this new graph
- Reposition the inventory
- Automatically split legend up to make it easier to fit
- Automatic centring and canvas sizing (two-stage drawing?)... when redrawing, put the connections under the boxes
- Automatic legend location
- Write more documentation for other people to use it
- Finish loot table templates for interloper, automate a way to base them off of mybases.json
- Refine the dark mode / hi contrast style
- When checking workbench number, count vices as well
- High-level view vs detail view
- Location tiers and minimum supplies for each
- Add some level of importance/priority?
- Add some indicator of wear/decay
- Item weights in legend.csv
- See image credits!
- TLD Interactive Map for helping me visualize how the regions connect