digraph g {
	concentrate=true
	dpi=192
	rankdir=LR
	//{rank=same; copper iron}
     graph [compound=true]
     
	subgraph cluster_legend {
		label=Legend
		"raw materials" [style=filled,fillcolor=mistyrose]
		"artificial\nmaterials" [shape=trapezium,style=filled,fillcolor=lightsteelblue]
		concepts [shape=component]
		"useable items" [shape=box,style=filled,fillcolor=khaki]
		"ingredient only" [shape=box,style=filled]
		{rank=source; "raw materials" "artificial\nmaterials"}
		{rank=same; concepts "useable items" "ingredient only"}
	}
	
	subgraph cluster_weaponarmour {
		"arming sword" [shape=box,style=filled,fillcolor=khaki]
		greatsword [shape=box,style=filled,fillcolor=khaki]
		headgear [shape=box,style=filled,fillcolor=khaki]
		breastplate [shape=box,style=filled,fillcolor=khaki]
		leggings [shape=box,style=filled,fillcolor=khaki]
		boots [shape=box,style=filled,fillcolor=khaki]
		{rank=source; "arming sword" greatsword headgear}
		{rank=sink; breastplate leggings boots}
	}
	subgraph cluster_handtools {
		pickaxe [shape=box,style=filled,fillcolor=khaki]
		hatchet [shape=box,style=filled,fillcolor=khaki]
		sledgehammer [shape=box,style=filled,fillcolor=khaki]
		"grappling hook" [shape=box,style=filled,fillcolor=khaki]
		{rank=source; pickaxe hatchet}
	}
	subgraph cluster_electrictools {
		"mining drill" [shape=box,style=filled,fillcolor=khaki]
		chainsaw [shape=box,style=filled,fillcolor=khaki]
		breaker [shape=box,style=filled,fillcolor=khaki]
		{rank=source; "mining drill"}
		{rank=same; breaker}
		{rank=sink; chainsaw}
	}
	subgraph cluster_hautecouture {
		"victorian furniture set" [shape=box,style=filled,fillcolor=khaki]
		"provence furniture set" [shape=box,style=filled,fillcolor=khaki]
		"ikea-esque furniture set" [shape=box,style=filled,fillcolor=khaki]
		//{rank=source; "victorian furniture set"}
		//{rank=same; "provence furniture set"}
		//{rank=sink; "ikea-esque furniture set"}
	}
	subgraph cluster_furnishings {
		"iron furniture set" [shape=box,style=filled,fillcolor=khaki] // basic
		"steel furniture set" [shape=box,style=filled,fillcolor=khaki] // fancier iron with a tint of diesel-punk
		"glass furniture set" [shape=box,style=filled,fillcolor=khaki]
		"cupric furniture set" [shape=box,style=filled,fillcolor=khaki] // copper-coloured rustic
		{rank=source; "iron furniture set" "cupric furniture set"}
		{rank=sink; "glass furniture set" "steel furniture set"}
	}
	subgraph cluster_kineticcomponents {
		clutch [shape=box,style=filled,fillcolor=khaki]
		gear [shape=box,style=filled,fillcolor=khaki]
		shaft [shape=box,style=filled,fillcolor=khaki]
		belt [shape=box,style=filled,fillcolor=khaki]
		//{rank=source; gear belt}
	}
	subgraph cluster_machineries {
		press [shape=box,style=filled,fillcolor=khaki]
		crusher [shape=box,style=filled,fillcolor=khaki]
		saw [shape=box,style=filled,fillcolor=khaki] // cuts rocks AND chops trees
		crafter [shape=box,style=filled,fillcolor=khaki]
		harvester [shape=box,style=filled,fillcolor=khaki]
		// no drill; mining is easier in 2D world
	}

	/* raw materials */
	wood [style=filled,fillcolor="#d5bc89"]
	stone [style=filled,fillcolor="#babfc5"]
	coal [style=filled,fillcolor="#606060",fontcolor=white]
	quartz [style=filled,fillcolor=mistyrose]
	sand [style=filled,fillcolor="#f0ecca"]
	
	malachite [style=filled,fillcolor="#54b295",fontcolor=white]
	hematite [style=filled,fillcolor="#cb8c6d",fontcolor=white]
	rutile [style=filled,fillcolor="#df6e88",fontcolor=white] // kinda fake colour for playability
	gold [style=filled,fillcolor="#dbba5e"]
	sphalerite [style=filled,fillcolor="#5c9abb",fontcolor=white] // fluoresces lead-oxide yellow

	/* manufactured materials */
	steel [shape=trapezium,style=filled,fillcolor="#4e5152",fontcolor=white]
	iron [shape=trapezium,style=filled,fillcolor="#a08778",fontcolor=white]
	copper [shape=trapezium,style=filled,fillcolor="#d69544",fontcolor=white]
	titanium [shape=trapezium,style=filled,fillcolor="#daddd9"]
	glass [shape=trapezium,style=filled,fillcolor="#79b883",fontcolor=white]
	zinc [shape=trapezium,style=filled,fillcolor="#8a8d8e",fontcolor=white]
	brass [shape=trapezium,style=filled,fillcolor="#d6af44"]
	/* concepts */
	thermal [shape=component]
	electricity [shape=component]
	kinetic [shape=component]
	information [shape=component]
	"sequential logic" [shape=component] // implies electronic memory
	radio [shape=component]
	telecommunication [shape=component]
	teleportation [shape=component]
	optics [shape=component]
	"quantum mechanics" [shape=component]
	networking [shape=component]
	"haute couture" [shape=component]
	"world portal" [shape=component]
	"hand tools" [shape=component] // pickaxe, axe, etc.
	"weapons&armours" [shape=component]
	"motorised tools" [shape=component] // DISABLED: TOO OP; drill, chainsaw, etc.
	"traditional machinery" [shape=component] // big fscking grinding wheels
	"electromechanical\nmachinery" [shape=component] // e.g. signal-controlled clutch
	galvanisation [shape=component] // iron plates/blocks/etc that won't rust
	/* useable items */
	furnace [shape=box,style=filled,fillcolor=khaki]
	torch [shape=box,style=filled,fillcolor=khaki]
	"light fixture" [shape=box,style=filled,fillcolor=khaki] // Both lamps and blinkenlight(s)
	furnitures [shape=box,style=filled,fillcolor=khaki]
	office [shape=box,style=filled,fillcolor=khaki]
	"logic gate" [shape=box,style=filled,fillcolor=khaki]
	"wireless circuit" [shape=box,style=filled,fillcolor=khaki]
	wire [shape=box,style=filled,fillcolor=khaki]
	typewriter [shape=box,style=filled,fillcolor=khaki]
	teletype [shape=box,style=filled,fillcolor=khaki]
	//rtty [shape=box,style=filled,fillcolor=khaki]
	"digital billboard" [shape=box,style=filled,fillcolor=khaki]
	"CRT display" [shape=box,style=filled,fillcolor=khaki]
	"personal computer" [shape=box,style=filled,fillcolor=khaki] // small computer with single integrated
	mainframe [shape=box,style=filled,fillcolor=khaki] // big computer that can have multiple terminals
	windmill [shape=box,style=filled,fillcolor=khaki]
	engine [shape=box,style=filled,fillcolor=khaki]
	motor [shape=box,style=filled,fillcolor=khaki]
	battery [shape=box,style=filled,fillcolor=khaki]
	
	/* ingredient items */
	LED [shape=box,style=filled]
	dyes [shape=box,style=filled]
	"steel casing" [shape=box,style=filled]
	"computing unit" [shape=box,style=filled] // motherboard+cpu+ram+powersupply combined
	"quartz oscillator" [shape=box,style=filled]
	"quartz lens" [shape=box,style=filled]

	
	stone -> furnace -> thermal
	coal -> thermal
	
	sand -> glass
	thermal -> glass -> furnitures
	
	thermal -> iron
	hematite -> iron
	thermal -> copper
	malachite -> copper
	
	iron -> steel
	coal -> steel
	thermal -> steel
	
	iron -> engine
	copper -> electricity
	thermal -> engine -> electricity
	copper -> wire
	wire -> electricity
	engine -> kinetic

	brass -> furnitures
	wood -> furnitures
	wood -> "hand tools"
	iron -> "hand tools"
	copper -> "hand tools"
	steel -> "hand tools"
	copper -> "weapons&armours"
	iron -> "weapons&armours"
	steel -> "weapons&armours"
	
	thermal -> titanium
	rutile -> titanium
	iron -> titanium -> "weapons&armours"

	furnitures -> office
	office -> information
	
	//electricity -> "motorised tools"
	//titanium -> "motorised tools"
	//steel -> "motorised tools"

 	wood -> torch
	coal -> torch
	torch -> "light fixture"
	iron -> "light fixture"
	copper -> "light fixture"
	glass -> "light fixture"
	
	information -> typewriter
	information -> "logic gate"
	gold -> "logic gate"
	iron -> typewriter -> teletype
	wire -> "logic gate"
	zinc -> typewriter
	
	electricity -> radio
	quartz -> "quartz oscillator" -> radio -> "wireless circuit"
	radio -> telecommunication
	information -> telecommunication -> networking
	"wireless circuit" -> networking
	telecommunication -> teletype -> "world portal"
	networking -> "world portal"

	"quartz oscillator" -> "sequential logic"
	"logic gate" -> "sequential logic" -> "computing unit"
	"computing unit" -> networking
		
	quartz -> "quartz lens" -> optics
	optics -> "quantum mechanics" -> teleportation -> "world portal" /* to not make quartz useless */
	"computing unit" -> "world portal"
	
	electricity -> "CRT display"
	glass -> "CRT display"
	"logic gate" -> "CRT display"
	
	electricity -> LED
	optics -> LED
	"logic gate" -> LED
	
	LED -> "digital billboard"
	"sequential logic" -> "digital billboard"
	LED -> "light fixture"
	

	steel -> "steel casing" -> "computing unit"
	"computing unit" -> "personal computer"
	"CRT display" -> "personal computer"
	LED -> "personal computer"
	"computing unit" -> mainframe
	teletype -> mainframe

	gold -> "haute couture"
	furnitures -> "haute couture"
	furnitures -> "iron furniture set" [lhead=cluster_furnishings]
	"haute couture" -> "victorian furniture set" [lhead=cluster_hautecouture]

	"steel casing" -> teletype
	"steel casing" -> "CRT display"
	"steel casing" -> "digital billboard"
	
	"hand tools" -> pickaxe [lhead=cluster_handtools]
	"weapons&armours" -> "arming sword" [lhead=cluster_weaponarmour]
	"motorised tools" -> breaker [lhead=cluster_electrictools]

	wood -> windmill -> kinetic
	electricity -> motor -> kinetic
	
	kinetic -> gear [lhead=cluster_kineticcomponents]
	
	brass -> "traditional machinery"
	kinetic -> "traditional machinery"

	"traditional machinery" -> "electromechanical\nmachinery"
	electricity -> "electromechanical\nmachinery"

	"traditional machinery" -> crusher [lhead=cluster_machineries]

	copper -> brass
	sphalerite -> zinc -> brass
	
	zinc -> galvanisation
	iron -> galvanisation
	
	coal -> battery
	zinc -> battery // zinc-carbon battery
	battery -> electricity

	titanium -> dyes
	coal -> dyes
}
