Created
December 20, 2022 13:15
-
-
Save anka-213/d72b787c7b247c61c9f9dd4bb1d0c266 to your computer and use it in GitHub Desktop.
Turn wayfinder into a labeled minimap in xkcd 2712
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Comic.wayfinderFarDistance = 80000 | |
Comic.wayfinderSpread = 300 | |
Comic.wayfinderEls.forEach((x,i) => (x.innerText = i, x.style.color = 'red')) | |
M = (v, min, max) => Math.min(Math.max(v,min),max) | |
window.origUpdateWayfinder = window.origUpdateWayfinder || Comic.updateWayfinder | |
Comic.updateWayfinder = Function("return function " + origUpdateWayfinder.toString().replace("+10*", "+this.wayfinderSpread*"))() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment