<<init>>\\n<div id="title">{{{PALADIN GAME}}}</div>\n* [[NEW GAME|Intro]]\n* <<if hasSaves()>>[[LOAD GAME]]<<else>>==LOAD GAME==<<endif>>\n* [[OPTIONS]]\n* [[CREDITS]]\n* [[QUIT][window.open('','_self').close()]]
{{{THERE ARE NO OPTIONS. WHY WOULD THERE BE OPTIONS.}}}\n\n[[<--|Start]]
{{{I'D LIKE TO THANK MYSELF, FOR BEING SO GREAT.}}}\n\n[[<--|Start]]
You've arrived at the passage to the [[City of Edges]].\n\nYou're on the trail of a blackguard and rogue who feigned taking holy orders to loot the ancient Monastary by the Sea. He drew the church here, to set the dark against the light and reap the rewards of their chaos. His list of sins is as long as the day, but here, now, he seeks the bones of an ancient saint, renowned in ages past for their blessing of miraculous healing, and thought lost when the city fell.\n\n[[You've|You]] wandered here by the vagaries of fate.
Beyond the cliffs of the black ocean, cut off from the world a century ago by divine calamity. The city died to wind and water and fire and earth, and in its wreckage a host of monstrous beasts have sprung like dragon's teeth from a field watered with blood. Dark cultists mingle with them, beasts themselves, and the men of the church have come cutting.\n\nThe city is burning. A paling alit in the clouds above the city before dawn, like a new moon, blue and orange.\n\n[[<--|Intro]]
You're a paladin. You circumscribe your volition by following the right path, so that you will not fall to temptation or wrath.\n\nYou wield the divine energy: howling \\n<<cycle colors>>\\n<<set $color = "violet">><<display "colorchange">><<revise colors "violet">>\\n<<becomes>>\\n<<set $color = "silver">><<display "colorchange">><<revise colors "silver">>\\n<<becomes>>\\n<<set $color = "golden">><<display "colorchange">><<revise colors "golden">>\\n<<becomes>>\\n<<set $color = "obsidian">><<display "colorchange">><<revise colors "obsidian">>\\n<<becomes>>\\n<<set $color = "tourmaline">><<display "colorchange">><<revise colors "tourmaline">>\\n<<becomes>>\\n<<set $color = "emerald">><<display "colorchange">><<revise colors "emerald">>\\n<<becomes>>\\n<<set $color = "sapphire">><<display "colorchange">><<revise colors "sapphire">>\\n<<becomes>>\\n<<set $color = "topaz">><<display "colorchange">><<revise colors "topaz">>\\n<<becomes>>\\n<<set $color = "ruby">><<display "colorchange">><<revise colors "ruby">>\\n<<endcycle>> light, scorching over your skin, gathering in flaming tongues at the nape of your neck.\n\nYou observe the holy way. You are a human, flawed as the rest, and you steadfastly \\n<<cycle virtues>>\\n<<set $virtue = "truth">><<revise virtues "refuse to speak false or misleading words">><<becomes>>\\n<<set $virtue = "faith">><<revise virtues "fear God and work to maintain God's earthly church">><<becomes>>\\n<<set $virtue = "charity">><<revise virtues "refuse any reward or payment for your good deeds">><<becomes>>\\n<<set $virtue = "justice">><<revise virtues "uphold justice and deliver the wages of sin to those who have trespassed against the law">><<becomes>>\\n<<set $virtue = "protect">><<revise virtues "protect those who cannot protect themselves, and help the needy, whatever the need">><<becomes>>\\n<<set $virtue = "fortitude">><<revise virtues "face fear, death, and the unknown with a brave heart">><<becomes>>\\n<<set $virtue = "valor">><<revise virtues "accept any challenge demanded from an equal">><<becomes>>\\n<<set $virtue = "obedience">><<revise virtues "serve and obey the liege lord of whatever land you travel through">><<becomes>>\\n<<set $virtue = "hope">><<revise virtues "maintain your hope, even at the darkest hour">><<becomes>>\\n<<set $virtue = "diligence">><<revise virtues "persevere to the end of any enterprise begun">><<endcycle>>\\n, for the corresponding vice is the one that bites deepest in your soul.\n\nYour name is <<textinput $name>>.\n\n<<set $langs = []>><<set $langpts = 4>>\\nYou know tongues: <span class="meta">you have <<cycle pts>><<print $langpts>><<endcycle>> language point<<cycle pts>><<print $langpts == 1 ? "" : "s">><<endcycle>></span><<set $langpts = 6>>\n* <<cycle human>>\\n<<addlang "human">>the local human tongue\\n<span class="meta"><<revert human "-">></span>\\n<<becomes>>\\n<<rmlang "human">><span class="meta">human \\n<<cycle outofpoints>><<revise human "+">><<becomes>>+<<endcycle>></span>\\n<<endcycle>>\n* <<cycle lizards>>\\n<<rmlang "lizard">><span class="meta">lizardpeople \\n<<cycle outofpoints>><<revise lizards "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "lizard">>the lizard-speech of the great swamp\\n<span class="meta"><<revert lizards "-">></span>\\n<<endcycle>>\n* <<cycle ogres>>\\n<<rmlang "ogre">><span class="meta">ogres \\n<<cycle outofpoints>><<revise ogres "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "ogre">>ogre-sign\\n<span class="meta"><<revert ogres "-">></span>\\n<<endcycle>>\n* <<cycle beasts>>\\n<<rmlang "beasts">><span class="meta">beasts \\n<<cycle outofpoints>><<revise beasts "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "beasts">>the sign-symbols of the fell beasts\\n<span class="meta"><<revert beasts "-">></span>\\n<<endcycle>>\n* <<cycle elementals>>\\n<<rmlang "elementals">><span class="meta">elementals \\n<<cycle outofpoints>><<revise elementals "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "elementals">>gutter arcane\\n<span class="meta"><<revert elementals "-">></span>\\n<<endcycle>>\n* <<cycle dragons>>\\n<<rmlang "dragons">><span class="meta">dragons \\n<<cycle outofpoints>><<revise dragons "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "dragons">>dragon posture language\\n<span class="meta"><<revert dragons "-">></span>\\n<<endcycle>>\n* <<cycle goblins>>\\n<<rmlang "goblins">><span class="meta">goblins & orcs \\n<<cycle outofpoints>><<revise goblins "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "goblins">>goblin and orc\\n<span class="meta"><<revert goblins "-">></span>\\n<<endcycle>>\n* <<cycle dark>>\\n<<rmlang "dark">><span class="meta">magical creatures \\n<<cycle outofpoints>><<revise dark "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "dark">>the sigils of the dark\\n<span class="meta"><<revert dark "-">></span>\\n<<endcycle>>\n* <<cycle sahagin>>\\n<<rmlang "sahagin">><span class="meta">sahagin \\n<<cycle outofpoints>><<revise sahagin "+">><<becomes>>+<<endcycle>></span>\\n<<becomes>>\\n<<addlang "sahagin">>the language of the deeps\\n<span class="meta"><<revert sahagin "-">></span>\\n<<endcycle>>\n* <<addlang "undead">>a link to the hive-mind of the dead\\n<span class="meta">-</span>\n\n/%<<set $genitalia to []>>Finally, there's the matter of <<cycle sex>><<set $sex = false>><<revise sex "sex...">><<becomes>>\\n<<set $sex = true>>sex...<span class="meta">pick some genitalia for use in sex scenes:\n* <<cycle breasts>>-<<becomes>><<set $genitalia.push("breasts")>><<revert breasts "-">><<endcycle>> \\nbreasts \\n<<cycle breasts>><<set $genitalia.splice($genitalia.indexOf ("breasts"),1)>><<revise breasts "+">><<becomes>>+<<endcycle>>\n* <<cycle cock>>-<<becomes>><<set $genitalia.push("cock")>><<revert cock "-">><<endcycle>> \\ncock & balls \\n<<cycle cock>><<set $genitalia.splice($genitalia.indexOf ("cock"),1)>><<revise cock "+">><<becomes>>+<<endcycle>>\n* <<cycle vagina>>-<<becomes>><<set $genitalia.push("vagina")>><<revert vagina "-">><<endcycle>> \\nvagina \\n<<cycle vagina>><<set $genitalia.splice($genitalia.indexOf ("vagina"),1)>><<revise vagina "+">><<becomes>>+<<endcycle>>\n* <<cycle ass>>-<<becomes>><<set $genitalia.push("ass")>><<revert ass "-">><<endcycle>> \\nass \\n<<cycle ass>><<set $genitalia.splice($genitalia.indexOf ("ass"),1)>><<revise ass "+">><<becomes>>+<<endcycle>>\n* <<cycle mouth>>-<<becomes>><<set $genitalia.push("mouth")>><<revert mouth "-">><<endcycle>> \\nmouth \\n<<cycle mouth>><<set $genitalia.splice($genitalia.indexOf ("mouth"),1)>><<revise mouth "+">><<becomes>>+<<endcycle>>\n* <<revert sex "nah let's not have any sex">>\n</span><<endcycle>>%/\n[[→|realStart]]
<<nobr>>\n<<set $arg to parameter(0)>>\n<<if $langs.indexOf($arg) != -1>>\n<<set $_ to $langs.splice($langs.indexOf($arg), 1)>>\n<<set $langpts += 1>><<reviseAll "revise" "pts">>\n<<if $langpts == 1>><<reviseAll "revise" "outofpoints">><<endif>>\n<<endif>>\n<<endnobr>>
<<nobr>>\n<<set $arg to parameter(0)>>\n<<if $langs.indexOf($arg) == -1>>\n<<set $_ = $langs.push ($arg)>>\n<<set $langpts -= 1>><<reviseAll "revise" "pts">>\n<<if $langpts == 0>><<reviseAll "revise" "outofpoints">><<endif>>\n<<endif>>\n<<endnobr>>
<<set $colors to ["violet", "obsidian", "silver", "ruby", "tourmaline", "golden", "emerald", "sapphire", "topaz"]>>\\n<<set $lt2 to String.fromCharCode(60) + String.fromCharCode(60) >>\\n<<set $gt2 to String.fromCharCode(62) + String.fromCharCode(62) >>\\n<<print $colors\n .map (function (c) {\n var h = state.history[0].variables;\n if (h.color != c)\n return h.lt2 + "removetag \"" + c + "\"" + h.gt2;\n else\n return h.lt2 + "addtag \"" + c + "\"" + h.gt2;\n })\n .join ("")>>
<<set $intro to false>>\\n<<if $virtue eq "truth">>\\nYou speak the truth, for you know well that words are simply words, and if you did not compel yourself to speak truth you would lie, scheme, and cheat. Ultimately, in the end, your words all ring hollow.\n<<else if $virtue eq "faith">>\\nYou obey God and God's clergy, for you know that it is only human thought that guides them, and that the throne of Heaven is empty. We are all graceless; we are all sinners: if we do not follow what little guidance we have, how can anyone survive?\n<<else if $virtue eq "charity">>\\nYou live a life of poverty, because you long constantly for gold and sweet wine, rich silks with gilded hems. The riches of the world are an eternal splendor, and their want is an ache that you know you could never sate. You make yourself do without.\n<<else if $virtue eq "justice">>\\nYou uphold justice, for law is a lie. There is no judgment beyond, and here the wicked rule and the upright are punished. You know how to commit wickedness very well, and for that reason you must uphold the law, for yourself if none other.\n<<else if $virtue eq "protect">>\\nYou protect the helpless, because charity and desperation have never stirred your emotions. Without an oath to aid others, your hard heart would let you walk by uncaring, without ever feeling guilt.\n<<else if $virtue eq "fortitude">>\\nYou have sworn to stand up to horror and misery because you are a coward. Your heart quails at every encounter: it is all you can do to hold to your oath, and push forward based on where you most dread to go. Without your oath to guide you, you would run.\n<<else if $virtue eq "valor">>\\nYou accept challenges from all worthy contenders to remind yourself you are not exceptional, nor undefeated. In your eyes, all are beneath you, and your failures the fault of those who stood with you. Your oath makes you behave as proper.\n<<else if $virtue eq "obedience">>\\nYou serve the lord of the land unquestioning, for all authority is false, and all lords are tyrants, and without your oath there would be no force in all the world that would send you to kneel before them.\n<<else if $virtue eq "hope">>\\nYou have sworn to hope, for all is hopeless. There are no happy endings, nor is there justice or mercy, and in all stories the same ending is written. Hope is an illusion -- but in others, it seems to be all they can do, and you've sworn to maintain hope, for their sakes.\n<<else if $virtue eq "diligence">>\\nYou have sworn to persevere, for otherwise you would find excuses to fail: to abandon quests, or vanish into the night, never to accomplish a single goal, for yourself or for others.\n<<else>>\\n{{{???}}}\n<<endif>>\\n\n/%<<if $sex == false>>You've taken a vow of chastity, for reasons of your own.\n<<else>>SEX: ON\nGENITALIA: <<print $genitalia>>\n<<endif>>%/\n\nNAME: <<print $name>>\n\n<<if $langs.indexOf("human") != -1>>You've wandered through these lands before, long enough to pick up the local tongue.\n\n<<endif>>\\n<<if $langs.indexOf("lizard") != -1>>You spent two years in the great swamp, sleeping first in the boughs of the ancient trees and then in village huts, and you still wake sometimes expecting to hear the sharp whistling, clicking speech ringing through the morning air.\n\n<<endif>>\\n<<if $langs.indexOf("ogre") != -1>>You travelled with an ogre for a few seasons, on and off -- you just seemed to always be crossing paths. You shared bread, and they taught you their hand-signs. You never got a hang on roaring, though you can understand it.\n\n<<endif>>\\n<<if $langs.indexOf("beasts") != -1>>In your childhood you befriended a dire wolf cub. In their den -- alongside them, before the looming monster that was their sole parent -- you learned the ancient symbols: drawn with claw and fang, on stone and flesh. There's a rune carved deep into the flesh of your back, between your shoulders, put there by your friend.\n\n<<endif>>\\n<<if $langs.indexOf("elementals") != -1>>You were once set against a summoner, who had trapped a band of elementals as slaves. You helped them topple him, and in the months-long struggle you learned the rudiments of their language: the common tongue of those from the lesser magical planes.\n\n<<endif>>\\n<<if $langs.indexOf ("dragons") != -1>>What knight hasn't encountered a dragon on their travels? There was an incident with a princess and a dragon, and while in the end the problem was an overzealous king angered by his daughter's latest paramour, you left that venture knowing the signs and signals the dragons used as speech.\n\n<<endif>>\\n<<if $langs.indexOf ("goblin") != -1>>You spent two summers, years apart, clapped in irons, chained to a goblin work-gang. You picked up words and phrases enough to get by, and by the time the goblins rebelled and slit their masters' throats you were almost fluent. The second time was less eventful. The dialect you speak is apparently incredibly rude and uncouth.\n\n<<endif>>\\n<<if $langs.indexOf ("dark") != -1>>You've learned the language of the unholy things that cloak themselves in darkness: occult sigils and signs; layers of metaphor and indirection and code-words. Some was learned in long battles against the creatures of the dark, and others -- rarer -- in helping them fight against injustices committed against them. After all, we are all damned sinners, and it is only by grace that we are saved.\n\n<<endif>>\\n<<if $langs.indexOf ("sahagin") != -1>>You grew up by the ocean, and there was a cove of sahagin and mer-people you met on the shore, speaking to each other until your voices were heard.\n\n<<endif>>\\n<<if $langs.indexOf ("undead") != -1>>You were struck down in battle, once, and you woke from that grim land to find yourself amongst the corpses of your friends, who had not been given a miraculous resurrection. You woke from death, and since then the voices of the dead followed you: lost souls, wandering and hungry, desperate to find rest. All dead speak the same tongue, for they speak in one voice, and that voice is your own.\n\n<<endif>>\n/%\n[[→|city]]\n\n[[map|mapd]]\n%/
<<if !$intro>>[[SAVE GAME]]\n<<endif>>
<<set $intro to true>>\\n<<if $save === 0>>\\n<<set $save to Array.apply(null, new Array(7)).map(Number.prototype.valueOf,0)>>\\n<<remember $save>>\\n<<endif>>
<<saveslots "OVERWRITE">>
<<saveslots "LOAD">>\n\n* [[{{{WIPE SAVE DATA}}}|ERASE SAVE DATA]]
<<print $save\n .map (function (s, i) {\n var\n o = "",\n d;\n if (s === 0) {\n o = "<div class=\"smain empty\"><span class=\"num\">#" + zeroFill (i+1, 2) + "</span><span class=\"empty\">EMPTY</span></div>";\n if (parameter(0) == "OVERWRITE") {\n o += " <div class=\"slink\">[[SAVE|" + parameter(0) + "][$slot = " + i + "]]</div>";\n }\n } else {\n d = JSON.parse (s);\n o = "<div class=\"smain\" data-tags=\"" + d.vars.color + "\"><span class=\"num\">#" + zeroFill (i+1, 2) + "</span><span class=\"place\">" + d.passage + "</span><span class=\"name\">" + d.vars.name + "</span><span class=\"virtue\">" + d.vars.virtue + "</span><span class=\"langs\">" + (d.vars.langs.join (", ")) + "</span></div>";\n o += " <div class=\"slink\">[[" + parameter(0) + "][$slot = " + i + "]]</div>";\n }\n o = "<div class=\"save\">" + o + "</div>";\n return o;\n })\n .join ("")>>
<<set $save [$slot] to JSON.stringify({vars: state.history[0].variables, passage: state.history[2].passage.title}); console.log ($save [$slot]) >><<remember $save>>\\nGAME SAVED\n\n<<print "[[BACK TO GAME|" + state.history[2].passage.title + "]]">>\n\n[[BACK TO TITLE|...][location.reload()]]
... (RELOADING) ...
<<set $load to JSON.parse ($save [$slot])>>\n<<print "[[LOAD COMPLETE|" + $load.passage + "]]">>\n<<set {\n var s = state.history[0].variables.save;\n state.history[0].variables = $load.vars;\n state.history[0].variables.save = s;\n }>>\n<<display "colorchange">>
{{{ARE YOU REALLY, REALLY SURE ABOUT THIS?}}}\n\n[[YES, DELETE EVERYTHING FOREVER|ERASE]]\n\n[[NO, DON'T DO THAT|Start]]
<<forget $save>>DATA ERASED\n\n[[BACK TO TITLE|...][location.reload()]]
The island is on a confluence of ley lines, fractured and cancerous from the destruction a century ago: no matter where you are on the island, some elemental spirit is bound there to the land.\n\nThe island is split up into many regions. Here are the ones you know of:\n* the ''City Center'', with a tent-encampment of the knights of the cardinal\n* the ''City Walls'', ringing the old city, middens and dens of foul lizard-men in three separate tribes\n* the ''Catacombs'', beneath the city, graves for the penitent in years past, now full of the wand'ring dead profaning the remains of saints\n* the ''Abandoned Mines'', ancient excavations beneath the city, now overrun with hordes of goblins and orcs\n* the ''Temple of Kiltia'', a profane temple to a pagan god, its corridors full of twisted dark creatures\n* the ''Keep'', the old city bastion, now a city unto itself, home to a degenerate kingdom of ogres\n* the ''Great Cathedral'', the ancient church, built when the city was first inhabited, and now the impregnable redoubt of the cultists\n* the ''Undercity'', a city subterrane, sundered from the quakes, and now a teeming market for any good the city can provide\n* the ''Snowfly Forest'', a wilding forest beyond the city, home to every manner of wild beast\n* the ''Cliffs'', splintering rock at the edges of the island, and the cliffside homes of a dozen clans of sahagin, from the top all the way down to the black, lightless caves beneath the sea\n* the ''Ringing Wall'', a sharp spar of mountain on the side of the sea, and its caves are home to an ancient wyrm and its kin\n\n* the ''Silver Way'', an isolated spar of the Undercity, what used to be a bazaar for the finest metalworkings in the city, and now just row after row of abandoned smiths.\n\nBut in these days, with the whole island in an uproar, movement from place to place is difficult.
The city is broken from the mainland. Rock spires like broken teeth twist up from the shattered coast. The island is edged by sheer cliffs, surrounded by the ichorous waters of the black sea, and past that the edge of the world.\n\nYou <<cycle across>><<set $arrive = "ridge">><<revise across "climb the tooth ridge">><<becomes>><<set $arrive = "sea">><<revise across "swim through the black sea">><<becomes>><<set $arrive = "catacombs">><<revise across "go through the catacombs">><<endcycle>>.\n\n[[→|arrive]]
<<if $arrive == "ridge">><<display "ridge">><<endif>><<if $arrive == "sea">><<display "sea">><<endif>><<if $arrive == "catacombs">><<display "catacombs">><<endif>>
The ridge is craggy spire upon spire, spiraling paths that dead-end at unstable spurs. Rock shifts and slides, like any moment the sunken bases could snap, sending the pillars sloping -- slowly, and then very fast -- into the black water. Already the magic of the end of the world is at work: you round a pillar and see a new sky, a new sea.\n\nBlack water dotted with daggerlike rocks, carving at the sky, rocks floating through the air, orbiting each other in complex patterns. Like the roots of mountains, stone breaks from the ocean, branching and sprawling in impossible directions. Dark shapes move against the sky, nearby seabirds or something else, impossibly distant and vast, with wings to blot out the sky.\n\nAgainst that unimaginable vista, the island with its ragged chain of connecting pillars seems nearby; a safe, easy destination.\n\nYou <<cycle climb>><<set $climb = "city">><<revise climb "climb across and reach the city">>/%\n%/<<becomes>><<set $climb = "dragon">><<revise climb "are waylaid when an immense dragon catches sight of you">>/%\n%/<<endcycle>>.
The island is broken off roughly, the island freshly split from the mainland. When the abyssal trench opened, it tore through the former peninsula and left behind a gap, like the world had been split apart.\n\nThe sea is dark and very, very deep. Reefs cluster thick on both sides. Spars of coral jut up like teeth, churning the water into foam as it cuts through the shallows. The black sea is nothing but whirlpools, the kind with hydras at their center, and crashing waves erode the rock of the island, cutting away at the substrate,carving out endless lightless caves beneath, a place of riptides and death.\n\nYou <<cycle swim>><<set $swim = "city">><<revise swim "swim across and reach the city">>/%\n%/<<becomes>><<set $swim = "hydra">><<revise swim "are drawn into the coils of a hydra">>/%\n%/<<endcycle>>.\n\n[[→|swim]]\n\n\n\nA water elemental. He's not amorphous, but he's not quite solid either. There's a rippling translucence across his forearms, on his sides. He's covered in scales, with rippling fins down his spine, fanning at the elbow, fluttering around his neck.\n\n\n\nYou crash through the door. There's a tableu you've apparently interrupted. The soldier is glances over, or maybe this was just the moment when it became inevitable, and the [[ogre]] he's fighting caves his head in with a mace. There's a soggy crack, followed by a thump. The ogre turns toward you.\n\n→
Ogres: tall, lean humanoids. Long-limbed and muscled. They have sharp, craggy features, with long, thick pointed ears. They have thick, leathery hide, in colors ranging from yellow to grey to blue to black-purple. They have tails, short and squat. They have no body hair.\n\nThey commonly wear masks, for reasons too lengthy to get into. Under the masks, their eyes are red or yellow.\n\nTheir vocal cords aren't developed for speech. Sound has some place in their language, but mostly they can roar. There's a complex set of hand-symbols, some of which require double-jointed ogre fingers to pull off comfortably.\n\nThis one: grey-blue skin, mid-tone. Bright red mask in a ferocious expression, swept over his head in nubby horns. It's lined with yellow paint, in thin grooves. He has red knuckle guards to match, with thin strips of faded fabric over the backs of his hands. He's got arcs of cured leather over his hips, stitched together, with ragged-ended squares of fabric low on his waist between them. He's blood-splattered, some of it his own.\n\n::→\n\nYour ogre sign is decent. You sign: following, humans, pass through, no harm. The ogre's ears twitch, flicking back like a horse throwing off flies. They raise their gauntleted hand, the one not holding the bloody club: pass.\n\nYou nod, and rush by.\n\n...
@font-face {\n font-family: 'Quicksand Regular';\n font-style: normal;\n font-weight: 400;\n src: local('Quicksand Regular'), local('Quicksand-Regular'), url(https://dl.dropbox.com/s/roxwdsrg09fho3b/Quicksand_Regular.ttf) format('truetype');\n}\nhtml, body {\n font-family: 'Quicksand Regular', sans-serif;\n font-size: 13pt;\n min-height: 100%;\n overflow: auto;\n}\nbody, #passages, .passage {\n margin: 0;\n padding: 0;\n min-height: 100%;\n}\n#passages, .passage {\n overflow: hidden;\n}\n.passage .main,\n.passage .map {\n padding-top: 5em;\n min-height: 100%;\n}\n#sidebar {\n display: none;\n}\n#passages {\n border-left: none;\n font-size: inherit;\n}\n.passage {\n font-size: inherit;\n}\n.passage .main,\n.passage .map {\n float: left;\n padding-bottom: 405em;\n margin-bottom: -400em;\n}\n.passage .main {\n display: block;\n width: 75%;\n box-sizing: border-box;\n padding-left: 1.5em;\n padding-right: 20%;\n border-left: 2px solid #f09;\n}\n.passage .map {\n display: block;\n width: 25%;\n box-sizing: border-box;\n padding-right: 1.5em;\n border-right: 4px solid #000;\n text-align: right;\n background: #f09;\n color: #000;\n}\n#passages .passage .map a,\n#passages .passage .map a:link,\n#passages .passage .map a:visited {\n color: #000;\n text-shadow: 0 0 3px #000;\n}\n#passages .passage .map a:hover,\n#passages .passage .map a:active {\n color: #000;\n text-shadow: 0 0 6px #000;\n}\n\n#passages .passage a,\n#passages .passage .main,\n#passages .passage .map {\n transition: 0.5s;\n -webkit-transition: 0.5s;\n}\n.passage a:link, .passage a:visited, .passage a {\n color: #f09;\n text-decoration: none;\n}\n.passage a:hover, .passage a:active {\n color: #f9c;\n text-decoration: none;\n}\ninput[type="text"] {\n background: #000;\n color: #fff;\n border: 1px inset #f09;\n border-radius: 3px;\n}\n\nbody[data-tags~="violet"] .passage a {\n color: #f09;\n text-shadow: 0px 0px 6px #603;\n text-decoration: none;\n}\nbody[data-tags~="violet"] .passage a:hover,\nbody[data-tags~="violet"] .passage a:active {\n color: #f9c;\n text-shadow: 0px 0px 9px #a37;\n text-decoration: none;\n}\nbody[data-tags~="violet"] .passage .main,\nbody[data-tags~="violet"] input[type="text"] {\n border-color: #f09;\n}\nbody[data-tags~="violet"] .passage .map,\n.save .smain[data-tags~="violet"] .num {\n background: #f09;\n color: #000;\n}\nbody[data-tags~="obsidian"] .passage a {\n color: #102;\n text-shadow: 1px 1px 4px #a6e, -1px -1px 4px #a6e;\n text-decoration: none;\n}\nbody[data-tags~="obsidian"] .passage a:hover,\nbody[data-tags~="obsidian"] .passage a:active {\n color: #a6e;\n text-shadow: 1px 1px 7px #608, -1px -1px 7px #608;\n text-decoration: none;\n}\nbody[data-tags~="obsidian"] .passage .main,\nbody[data-tags~="obsidian"] input[type="text"] {\n border-color: #204;\n}\nbody[data-tags~="obsidian"] .passage .map,\n.save .smain[data-tags~="obsidian"] .num {\n background: #204;\n color: #eee;\n}\nbody[data-tags~="obsidian"] #passages .passage .map a,\nbody[data-tags~="obsidian"] #passages .passage .map a:link,\nbody[data-tags~="obsidian"] #passages .passage .map a:visited {\n color: #fff;\n text-shadow: 0 0 3px #fff;\n}\nbody[data-tags~="obsidian"] #passages .passage .map a:hover,\nbody[data-tags~="obsidian"] #passages .passage .map a:active {\n color: #ccc;\n text-shadow: 0 0 6px #fff;\n}\nbody[data-tags~="silver"] .passage a {\n color: #ccd;\n text-shadow: 0px 0px 6px #446;\n text-decoration: none;\n}\nbody[data-tags~="silver"] .passage a:hover,\nbody[data-tags~="silver"] .passage a:active {\n color: #eef;\n text-shadow: 0px 0px 9px #66a;\n text-decoration: none;\n}\nbody[data-tags~="silver"] .passage .main,\nbody[data-tags~="silver"] input[type="text"] {\n border-color: #ccd;\n}\nbody[data-tags~="silver"] .passage .map,\n.save .smain[data-tags~="silver"] .num {\n background: #ccd;\n color: #000;\n}\nbody[data-tags~="ruby"] .passage a {\n color: #f10;\n text-shadow: 0px 0px 6px #900;\n text-decoration: none;\n}\nbody[data-tags~="ruby"] .passage a:hover,\nbody[data-tags~="ruby"] .passage a:active {\n color: #f98;\n text-shadow: 0px 0px 9px #c54;\n text-decoration: none;\n}\nbody[data-tags~="ruby"] .passage .main,\nbody[data-tags~="ruby"] input[type="text"] {\n border-color: #f10;\n}\nbody[data-tags~="ruby"] .passage .map,\n.save .smain[data-tags~="ruby"] .num {\n background: #f10;\n color: #000;\n}\nbody[data-tags~="topaz"] .passage a {\n color: #f90;\n text-shadow: 0px 0px 6px #940;\n text-decoration: none;\n}\nbody[data-tags~="topaz"] .passage a:hover,\nbody[data-tags~="topaz"] .passage a:active {\n color: #fc8;\n text-shadow: 0px 0px 9px #c84;\n text-decoration: none;\n}\nbody[data-tags~="topaz"] .passage .main,\nbody[data-tags~="topaz"] input[type="text"] {\n border-color: #f90;\n}\nbody[data-tags~="topaz"] .passage .map,\n.save .smain[data-tags~="topaz"] .num {\n background: #f90;\n color: #000;\n}\nbody[data-tags~="tourmaline"] .passage a {\n color: #f88;\n text-shadow: 1px 1px 4px #482, -1px -1px 4px #482;\n text-decoration: none;\n}\nbody[data-tags~="tourmaline"] .passage a:hover,\nbody[data-tags~="tourmaline"] .passage a:active {\n color: #fcc;\n text-shadow: 1px 1px 7px #6b3, -1px -1px 7px #6b3;\n text-decoration: none;\n}\nbody[data-tags~="tourmaline"] .passage .main,\nbody[data-tags~="tourmaline"] input[type="text"] {\n border-color: #f88;\n}\nbody[data-tags~="tourmaline"] .passage .map,\n.save .smain[data-tags~="tourmaline"] .num {\n background: #f88;\n color: #000;\n}\nbody[data-tags~="golden"] .passage a {\n color: #fe8;\n text-shadow: 0px 0px 6px #982;\n text-decoration: none;\n}\nbody[data-tags~="golden"] .passage a:hover,\nbody[data-tags~="golden"] .passage a:active {\n color: #ffc;\n text-shadow: 0px 0px 9px #dc5;\n text-decoration: none;\n}\nbody[data-tags~="golden"] .passage .main,\nbody[data-tags~="golden"] input[type="text"] {\n border-color: #fe8;\n}\nbody[data-tags~="golden"] .passage .map,\n.save .smain[data-tags~="golden"] .num {\n background: #fe8;\n color: #000;\n}\nbody[data-tags~="emerald"] .passage a {\n color: #9f0;\n text-shadow: 0px 0px 6px #380;\n text-decoration: none;\n}\nbody[data-tags~="emerald"] .passage a:hover,\nbody[data-tags~="emerald"] .passage a:active {\n color: #cf8;\n text-shadow: 0px 0px 6px #7e4;\n text-decoration: none;\n}\nbody[data-tags~="emerald"] .passage .main,\nbody[data-tags~="emerald"] input[type="text"] {\n border-color: #9f0;\n}\nbody[data-tags~="emerald"] .passage .map,\n.save .smain[data-tags~="emerald"] .num {\n background: #9f0;\n color: #000;\n}\nbody[data-tags~="sapphire"] .passage a {\n color: #09f;\n text-shadow: 0px 0px 6px #019;\n text-decoration: none;\n}\nbody[data-tags~="sapphire"] .passage a:hover,\nbody[data-tags~="sapphire"] .passage a:active {\n color: #8cf;\n text-shadow: 0px 0px 6px #46d;\n text-decoration: none;\n}\nbody[data-tags~="sapphire"] .passage .main,\nbody[data-tags~="sapphire"] input[type="text"] {\n border-color: #09f;\n}\nbody[data-tags~="sapphire"] .passage .map,\n.save .smain[data-tags~="sapphire"] .num {\n background: #09f;\n color: #000;\n}\n\nbody[data-tags~="foo"] {\n background: #f00;\n}\nbody[data-tags~="bar"] {\n background: #00f;\n}\n.passage li {\n display: list-item;\n text-align: left;\n}\n.meta {\n display: block;\n float: right;\n width: 55%;\n margin-right: -9em;\n color: #aaa;\n clear: right;\n}\n\n#title {\n font-size:200%;\n background: #f09;\n color: #000;\n text-align: center;\n margin: 2.5em 0 1em 0;\n padding: .5em 0;\n border-top: 6px double #000;\n border-bottom: 6px double #000;\n}\nbody[data-tags~="start"] ul {\n width: 25%;\n margin: auto;\n list-style: none;\n fotn-size: 150%;\n}\n\n.save {\n position: relative;\n width: 100%;\n height: 4.2em;\n margin-bottom: 1em;\n}\n.save .smain {\n position: relative;\n height: 4.2em;\n padding: 0 0 0 .5em;\n}\n.save .name,\n.save .place,\n.save .virtue,\n.save .langs {\n height: 1.4em;\n}\n.save .name,\n.save .virtue,\n.save .langs {\n padding-right: .5em;\n text-align: right;\n}\n.save .name {\n float: right;\n width: 30%;\n}\n.save .place {\n float: left;\n width: 40%;\n}\n.save .virtue {\n float: right;\n width: 60%;\n}\n.save .langs {\n display: block;\n white-space: nowrap;\n position: absolute;\n bottom: 0;\n right: 5.5em;\n}\n.save .num {\n float: right;\n width: 5em;\n height: 100%;\n text-align: left;\n font-variant: small-caps;\n background: #111;\n color: #777;\n padding-left: .5em;\n}\n.save .smain.empty {\n color: #777;\n border-color: #444;\n}\n .save .smain.empty .num {\n color: #777;\n }\n .save .smain.empty .empty {\n display: block;\n text-align: center;\n line-height: 2.1em;\n font-size: 200%;\n }\n.slink {\n position: absolute;\n top: 0;\n right: 0;\n margin-right: -7em;\n width: 7em;\n height: 4em;\n line-height: 4em;\n text-align: center;\n}\n\n.revision-span-in {\n opacity: 0;\n}\n.revision-span:not(.revision-span-out) {\n transition: 1s;\n -webkit-transition: 1s;\n}\n.revision-span-out {\n position:absolute;\n opacity: 0;\n}
try {\n version.extensions['textinput'] = { \n major:1, minor:0, revision:0 \n };\n macros['textinput'] = {\n handler: function(place, macroName, params, parser) {\n v = params[0].replace("$","");\n var input= document.createElement('input');\n input.type = "text";\n d = v+"TextInput";\n input.id = d;\n input.addEventListener('keyup', function()\n {\n state.history[0].variables[v] = document.getElementById(d).value;\n });\n place.appendChild(input);\n }, \n init: function() { var v; var d;},\n };\n} catch(e) {\n throwError(place,"textinput Setup Error: "+e.message); \n}
version.extensions["toggletagMacros"]={major:1,minor:1,revision:0};\nmacros["toggletag"]={\n handler:function(a,b,c){\n var p=e(a);\n var d=document.body;\n if (Wikifier.parse(c[0]) != c[0]) {\n c[0] = eval (Wikifier.parse(c[0]));\n }\n if(p){\n var t=p.getAttribute("data-tags");\n var i=t.indexOf(c[0]);\n if(b!="addtag"&&i>=0){\n var r=t.replace(c[0],"");\n p.setAttribute("data-tags",r);\n d.setAttribute("data-tags",r);\n }else{\n if(b!="removetag"&&i<0){\n var r=t+" "+c[0];\n p.setAttribute("data-tags",r);\n d.setAttribute("data-tags",r);\n }\n }\n }else{\n var t=state.history[0].passage.tags;\n var i=t.indexOf(c[0]);\n if(b!="addtag"&&i>=0){\n t.splice(i,1);\n }else{\n if(b!="removetag"&&i<0){\n t.push(c[0]);\n }\n }\n d.setAttribute("data-tags",t.join(" "));\n }\n function e(f){\n while(f.parentNode&&!f.classList.contains("passage")){\n f=f.parentNode;\n }\n if(f!=document&&f.getAttribute("data-tags")){\n return f;\n }\n return null;\n }\n }\n};\nmacros["addtag"]=macros["toggletag"];macros["removetag"]=macros["toggletag"];
function array_eq (a, b) {\n if (a.length != b.length)\n return false;\n for (var i = 0; i < a.length; i++) {\n if (a[i] != b[i])\n return false;\n }\n return true;\n}\n\nfunction elem_index (arr, val) {\n for (var i = 0; i < arr.length; i++) {\n if (array_eq (arr[i], val))\n return i;\n }\n return -1;\n}\n\nfunction random_from (lo, hi) {\n return lo + Math.floor (Math.random() * hi);\n}\n\nvar cache = [];\nvar mutated = [];\nfunction draw (deck) {\n console.log (cache);\n console.log (mutated);\n var c = elem_index (cache, deck);\n console.log ("first c", c);\n if (c == -1) {\n cache.push (deck);\n mutated.push (deck.slice(0)); // otherwise js's array-assignments-are-references trips us up later when we splice the value\n c = cache.length - 1;\n }\n console.log (c);\n var m = mutated[c];\n console.log (m);\n var r = random_from (0, m.length);\n var result = m.splice(r, 1); // this mutates the original value in `mutated`\n if (m.length == 0) {\n cache.splice (c, 1);\n mutated.splice (c, 1);\n }\n return result;\n}
window.hasSaves = function () {\n var h = state.history[0].variables;\n for (var i = 0; i < h.save.length; i++) {\n if (h.save[i] !== 0)\n return true;\n }\n return false;\n};\nwindow.zeroFill = function (number, width) {\n width -= number.toString().length;\n if (width <= 0) {\n return number + "";\n }\n return Array.apply(null, new Array(width)).map(function () {return "0"}) + number;\n};\n\n version.extensions["replaceMacrosCombined"]={\n major:1,minor:0,revision:0\n };\n var nullobj={\n handler:function(){\n }\n };\n function showVer(n,notrans){\n n.innerHTML="";\n new Wikifier(n,n.tweecode);\n n.setAttribute("data-enabled","true");\n n.style.display="inline";\n n.classList.remove("revision-span-out");\n if(!notrans){\n n.classList.add("revision-span-in");\n if(n.timeout){\n clearTimeout(n.timeout)\n }\n n.timeout=setTimeout(\n function(){\n n.classList.remove("revision-span-in")\n },\n 1)\n }\n }\n function hideVer(n,notrans){\n n.setAttribute("data-enabled","false");\n n.classList.remove("revision-span-in");\n if(n.timeout){\n clearTimeout(n.timeout)\n }\n if(!notrans){\n n.classList.add("revision-span-out");\n n.timeout=setTimeout(\n function(){\n if(n.getAttribute("data-enabled")=="false"){\n n.classList.remove("revision-span-out");\n n.style.display="none";\n n.innerHTML=""\n }\n },\n 1000)\n }else{\n n.style.display="none";\n n.innerHTML=""\n }\n }\n function tagcontents(b,starttags,desttags,endtags,k){\n var l=0,c="",tg,a,i;\n function tagfound(i,e){\n for(var j=0;j<e.length;j++){\n if(a.indexOf("<<"+e[j],i)==i){\n return e[j]\n }\n }\n }\n a=b.source.slice(k);\n for(i=0;i<a.length;i++){\n if(tg=tagfound(i,starttags)){\n l++\n }else{\n if((tg=tagfound(i,desttags))&&l==0){\n b.nextMatch=k+i+tg.length+4;\n return[c,tg]\n }else{\n if(tg=tagfound(i,endtags)){\n l--;\n if(l<0){\n return null\n }\n }\n }\n }\n c+=a.charAt(i)\n }\n return null\n }\n var begintags=[];\n var endtags=[];\n function revisionSpanHandler(g,e,f,b){\n var k=b.source.indexOf(">>",b.matchStart)+2,vsns=[],vtype=e,flen=f.length,becomes,c,cn,m,h,vsn;\n function mkspan(vtype){\n h=insertElement(m,"span",null,"revision-span "+vtype);\n h.setAttribute("data-enabled",false);\n h.style.display="none";\n h.tweecode="";\n return h\n }\n if(this.shorthand&&flen){\n while(f.length>0){\n vsns.push([f.shift(),(this.flavour=="insert"?"gains":"becomes")])\n }\n }else{\n if(this.flavour=="insert"||(this.flavour=="continue"&&this.trigger=="time")){\n vsns.push(["","becomes"])\n }\n }\n if(this.flavour=="continue"&&flen){\n b.nextMatch=k+b.source.slice(k).length;\n vsns.push([b.source.slice(k),vtype])\n }else{\n becomes=["becomes","gains"];\n c=tagcontents(b,begintags,becomes.concat(endtags),endtags,k);\n if(c&&endtags.indexOf(c[1])==-1){\n while(c){\n vsns.push(c);\n c=tagcontents(b,begintags,becomes,endtags,b.nextMatch)\n }\n c=tagcontents(b,begintags,["end"+e],endtags,b.nextMatch)\n }\n if(!c){\n throwError(g,"can't find matching end"+e);\n return\n }\n vsns.push(c);\n if(this.flavour=="continue"){\n k=b.nextMatch;\n b.nextMatch=k+b.source.slice(k).length;\n vsns.push([b.source.slice(k),""])\n }\n }\n if(this.flavour=="remove"){\n vsns.push(["","becomes"])\n }\n console.log(JSON.stringify(vsns));\n cn=0;\n m=insertElement(g,"span",null,e);\n m.setAttribute("data-flavour",this.flavour);\n h=mkspan("initial");\n vsn=vsns.shift();\n console.log(e+" "+vsn[0]);\n h.tweecode=vsn[0];\n showVer(h,true);\n while(vsns.length>0){\n if(vsn){\n vtype=vsn[1]\n }\n vsn=vsns.shift();\n h=mkspan(vtype);\n h.tweecode=vsn[0]\n }\n if(typeof this.setup=="function"){\n this.setup(m,g,f)\n }\n }\n function quantity(m){\n return(m.children.length-1)+(m.getAttribute("data-flavour")=="remove")\n }\n function revisionSetup(m,g,f){\n m.className+=" "+f[0].replace(" ","_");\n showVer(m.firstChild,true)\n }\n function timeSetup(m,g,f){\n function cssTimeUnit(s){\n if(typeof s=="string"){\n if(s.slice(-2).toLowerCase()=="ms"){\n return Number(s.slice(0,-2))||0\n }else{\n if(s.slice(-1).toLowerCase()=="s"){\n return Number(s.slice(0,-1))*1000||0\n }\n }\n }\n throwError(g,s+" isn't a CSS time unit");\n return 0\n }\n var fl=this.flavour;\n var tm=cssTimeUnit(f[0]);\n setTimeout(function timefn(){\n var done=!revise("revise",m);\n if(!done){\n setTimeout(timefn,tm)\n }\n },\n tm)\n }\n function hoverSetup(m){\n m.onmouseover=function(){\n revise("revise",m)\n };\n m.onmouseout=function(){\n revise("revert",m)\n }\n }\n function mouseSetup(m){\n var fl=this.flavour;\n m.onmouseenter=function(){\n var done=!revise("revise",m);\n if(done){\n this.onmouseenter=null\n }\n }\n }\n function linkSetup(m,g,f){\n var fl=this.flavour,l=Wikifier.createInternalLink(),p=m.parentNode;\n l.className="internalLink replaceLink";\n p.insertBefore(l,m);\n l.insertBefore(m,null);\n l.onclick=function(){\n var p,done=false;\n if(m&&m.parentNode==this){\n done=!revise("revise",m);\n scrollWindowTo(m)\n }\n if(done){\n this.parentNode.insertBefore(m,this);\n this.parentNode.removeChild(this)\n }\n }\n }\n function visitedSetup(m,g,f){\n var i,done,shv=state.history[0].variables,os="once seen",d=(m.firstChild&&(this.flavour=="insert"?m.firstChild.nextSibling:m.firstChild).tweecode);\n shv[os]=shv[os]||{};\n if(d&&!shv[os].hasOwnProperty(d)){\n shv[os][d]=1\n }else{\n for(i=shv[os][d];i>0&&!done;i--){\n done=!revise("revise",m,true)\n }\n if(shv[os].hasOwnProperty(d)){\n shv[os][d]+=1\n }\n }\n }\n [ {name:"insert",flavour:"insert",trigger:"link",setup:linkSetup}\n , {name:"timedinsert",flavour:"insert",trigger:"time",setup:timeSetup}\n , {name:"insertion",flavour:"insert",trigger:"revisemacro",setup:revisionSetup}\n , {name:"later",flavour:"insert",trigger:"visited",setup:visitedSetup}\n , {name:"replace",flavour:"replace",trigger:"link",setup:linkSetup}\n , {name:"timedreplace",flavour:"replace",trigger:"time",setup:timeSetup}\n , {name:"mousereplace",flavour:"replace",trigger:"mouse",setup:mouseSetup}\n , {name:"hoverreplace",flavour:"replace",trigger:"hover",setup:hoverSetup}\n , {name:"revision",flavour:"replace",trigger:"revisemacro",setup:revisionSetup}\n , {name:"timedremove",flavour:"remove",trigger:"time",setup:timeSetup}\n , {name:"mouseremove",flavour:"remove",trigger:"mouse",setup:mouseSetup}\n , {name:"hoverremove",flavour:"remove",trigger:"hover",setup:hoverSetup}\n , {name:"removal",flavour:"remove",trigger:"revisemacro",setup:revisionSetup}\n , {name:"once",flavour:"remove",trigger:"visited",setup:visitedSetup}\n , {name:"continue",flavour:"continue",trigger:"link",setup:linkSetup}\n , {name:"timedcontinue",flavour:"continue",trigger:"time",setup:timeSetup}\n , {name:"mousecontinue",flavour:"continue",trigger:"mouse",setup:mouseSetup}\n , {name:"cycle",flavour:"cycle",trigger:"revisemacro",setup:revisionSetup}\n , {name:"mousecycle",flavour:"cycle",trigger:"mouse",setup:mouseSetup}\n , {name:"timedcycle",flavour:"cycle",trigger:"time",setup:timeSetup}\n ].forEach(function(e){\n e.handler=revisionSpanHandler;\n e.shorthand=(["link","mouse","hover"].indexOf(e.trigger)>-1);\n macros[e.name]=e;\n macros["end"+e.name]=nullobj;\n begintags.push(e.name);\n endtags.push("end"+e.name)\n });\n function reviseAll(rt,rname){\n var rall=document.querySelectorAll(".passage ."+rname),ret=false;\n for(var i=0;i<rall.length;i++){\n ret=revise(rt,rall[i])\n }\n return ret\n }\n function revise(rt,r,notrans){\n var ind2,curr,next,ind=-1,rev=(rt=="revert"),rnd=(rt.indexOf("random")>-1),fl=r.getAttribute("data-flavour"),rc=r.childNodes,cyc=(fl=="cycle"),rcl=rc.length-1;\n function doToGainerSpans(n,fn){\n for(var k=n-1;k>=0;k--){\n if(rc[k+1].classList.contains("gains")){\n fn(rc[k],notrans)\n }else{\n break\n }\n }\n }\n for(var k=0;k<=rcl;k++){\n if(rc[k].getAttribute("data-enabled")=="true"){\n ind=k\n }\n }\n if(rev){\n ind-=1\n }\n curr=(ind>=0?rc[ind]:(cyc?rc[rcl]:null));\n ind2=ind;\n if(rnd){\n ind2=(ind+(Math.floor(Math.random()*rcl)))%rcl\n }\n next=((ind2<rcl)?rc[ind2+1]:(cyc?rc[0]:null));\nvar docurr=(rev?showVer:hideVer);var donext=(rev?hideVer:showVer);\nif(curr){if(!(next&&next.classList.contains("gains"))||rnd){docurr(curr,notrans);\ndoToGainerSpans(ind,docurr,notrans)}}if(next){donext(next,notrans);\nif(rnd){doToGainerSpans(ind2+1,donext,notrans)}}return(cyc?true:(rev?(ind>0):(ind2<rcl-1)))\n}macros["revert"]=macros["revise"]=macros["randomise"]=macros["randomize"]={handler:function(a,b,c){var l,rev,rname;\nfunction disableLink(l){l.style.display="none"}function enableLink(l){l.style.display="inline"\n}function updateLink(l){if(l.className.indexOf("random")>-1){enableLink(l);\nreturn}var rall=document.querySelectorAll(".passage ."+rname),cannext,canprev,i,ind,r,fl;\nfor(i=0;i<rall.length;i++){r=rall[i],fl=r.getAttribute("data-flavour");\nif(fl=="cycle"){cannext=canprev=true}else{if(r.firstChild.getAttribute("data-enabled")==!1+""){canprev=true\n}if(r.lastChild.getAttribute("data-enabled")==!1+""){cannext=true\n}}}var can=(l.classList.contains("revert")?canprev:cannext);(can?enableLink:disableLink)(l)\n}function toggleText(w){w.classList.toggle(rl+"Enabled");w.classList.toggle(rl+"Disabled");\nw.style.display=((w.style.display=="none")?"inline":"none")}var rl="reviseLink";\nif(c.length<2){throwError(a,b+" macro needs 2 parameters");return\n}rname=c.shift().replace(" ","_");l=Wikifier.createInternalLink(a,null);\nl.className="internalLink "+rl+" "+rl+"_"+rname+" "+b;var v="";\nvar end=false;var out=false;if(c.length>1&&c[0][0]=="$"){v=c[0].slice(1);\nc.shift()}switch(c[c.length-1]){case"end":end=true;c.pop();break;\ncase"out":out=true;c.pop();break}var h=state.history[0].variables;\nfor(var i=0;i<c.length;i++){var on=(i==Math.max(c.indexOf(h[v]),0));\nvar d=insertElement(null,"span",null,rl+((on)?"En":"Dis")+"abled");\nif(on){h[v]=c[i];l.setAttribute("data-cycle",i)}else{d.style.display="none"\n}insertText(d,c[i]);l.appendChild(d)}l.onclick=function(){reviseAll(b,rname);\nvar t=this.childNodes,u=this.getAttribute("data-cycle")-0,m=t.length,n,lall,i;\nif((end||out)&&u==m-(end?2:1)){if(end){n=this.removeChild(t[u+1]);\nn.className=rl+"End";n.style.display="inline";this.parentNode.replaceChild(n,this)\n}else{this.parentNode.removeChild(this);return}}else{toggleText(t[u]);\nu=(u+1)%m;if(v){h[v]=c[u]}toggleText(t[u]);this.setAttribute("data-cycle",u)\n}lall=document.getElementsByClassName(rl+"_"+rname);for(i=0;i<lall.length;\ni++){updateLink(lall[i])}};disableLink(l);setTimeout(function(){updateLink(l)\n},1)}};macros["mouserevise"]=macros["hoverrevise"]={handler:function(a,b,c,d){var endtags=["end"+b];\nvar t=tagcontents(d,[b],endtags,endtags,d.source.indexOf(">>",d.matchStart)+2);\nif(t){var rname=c[0].replace(" ","_"),h=insertElement(a,"span",null,"hoverrevise hoverrevise_"+rname),f=function(){var done=!reviseAll("revise",rname);\nif(b!="hoverrevise"&&done){this.onmouseenter=null}};new Wikifier(h,t[0]);\nif(b=="hoverrevise"){h.onmouseover=f;h.onmouseout=function(){reviseAll("revert",rname)\n}}else{h.onmouseenter=f}}}};macros["endmouserevise"]=nullobj;\nmacros["endhoverrevise"]=nullobj\n\nmacros.reviseAll =\n { handler: function (place, macroName, params, parser) {\n reviseAll (params[0], params[1]);\n }\n }
window.reshowAll=function reshowAll(e){var t=document.querySelectorAll(".passage ."+e.replace(" ","_")),n=false;for(var r=0;r<t.length;r++){n=reshow(t[r])}return n};function reshow(e){e.innerHTML="";new Wikifier(e,e.tweecode);e.classList.remove("revision-span-out");e.classList.add("revision-span-in");if(e.timeout){clearTimeout(e.timeout)}e.timeout=setTimeout(function(){e.classList.remove("revision-span-in")},1)}macros.pane={handler:function(place,macroName,params,parser){var name=params[0][0]=="$"?eval(Wikifier.parse(params[0])):params[0];var passage=params[1][0]=="$"?eval(Wikifier.parse(params[1])):params[1];var pane=document.createElement("span");var contents=document.createElement("span");pane.id=name.replace(" ","_");contents.className=" "+name.replace(" ","_");contents.tweecode='<<set $_ to $_current.push ("'+name+'")>><<display $_'+name+">><<set $_ to $_current.pop()>>";var h=state.history[0].variables;h["_"+name]=passage;if(typeof h._current=="undefined"){h._current=[]}pane.insertBefore(contents,null);place.insertBefore(pane,null);new Wikifier(contents,contents.tweecode)}};macros.link=macros.linkTo={handler:function(place,macroName,params,parser){var to,text,target;var h=state.history[0].variables;if(typeof h._current=="undefined"){h._current=[]}if(macroName=="link"){if(params.length<2){throwError(place,macroName+" macro needs 2 parameters");return}to=params[0][0]=="$"?eval(Wikifier.parse(params[0])):params[0];text=params[1][0]=="$"?eval(Wikifier.parse(params[1])):params[1];target=h._current[h._current.length-1]}else{if(params.length<3){throwError(place,macroName+" macro needs 3 parameters");return}target=params[0][0]=="$"?eval(Wikifier.parse(params[0])):params[0];to=params[1][0]=="$"?eval(Wikifier.parse(params[1])):params[1];text=params[2][0]=="$"?eval(Wikifier.parse(params[2])):params[2]}var link=Wikifier.createInternalLink();link.className="internalLink paneLink";link.id=to;link.insertBefore(document.createTextNode(text),null);link.onclick=function(){h["_"+target]=to;reshowAll(target)};place.insertBefore(link,null)}};macros.linkMany={handler:function(place,macroName,params,parser){if(params.length<3||params.length%2!=1){throwError(place,macroName+": invalid args, needs [pane passage...] link text");return}var h=state.history[0].variables;if(typeof h._current=="undefined"){h._current=[]}var text=params[params.length-1][0]=="$"?eval(Wikifier.parse(params[params.length-1])):params[params.length-1];var to,target;var link=Wikifier.createInternalLink();link.className="internalLink paneLink";link.insertBefore(document.createTextNode(text),null);link.onclick=function(){while(params.length!=1){target=params.shift();target=text[0]=="$"?eval(Wikifier.parse(target)):target;to=params.shift();to=to[0]=="$"?eval(Wikifier.parse(to)):to;h["_"+target]=to;reshowAll(target)}};place.insertBefore(link,null)}}\nmacros.reshow = {\n handler:function(place,macroName,params,parser) {\n var target=params[0][0]=="$"\n ?eval(Wikifier.parse(params[0]))\n :params[0];\n reshowAll (target);\n }\n}
<<addtag $color>><<pane "map" "map">>
<<addtag $color>><span class="map"></span>
postrender.StoryFooter = function(A) {\n var\n parent = A.parentNode,\n wrapper = document.createElement('div'),\n sidebar = tale.get("sidebar");\n if (state.history[0].passage.tags.indexOf ("start") != -1)\n return;\n if (state.history[0].passage.tags.indexOf ("ui") != -1) {\n sidebar = tale.get("emptysidebar");\n }\n wrapper.className = "main";\n parent.removeChild(A);\n wrapper.appendChild(A);\n if (sidebar.id !== undefined) {\n new Wikifier(parent, sidebar.processText());\n }\n parent.appendChild(wrapper);\n}