diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c66a550 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +live/* diff --git a/TODO.ktx b/TODO.ktx new file mode 100644 index 0000000..e01890f --- /dev/null +++ b/TODO.ktx @@ -0,0 +1,34 @@ +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +Things That This Being Must Do +```````````````````````````````` +For my own benefit, I've put my TODO in this most public of places. +,,,,,,,,,,,,,,,,,,,,,,,, +Things I have to do anyway +```````````````````````` + * Finish Dr. Cole's site, along with mobile styling + +,,,,,,,,,,,,,,,,,,,,,,,, +Polymathic Things +```````````````````````` + * Hustle to get Vashram stand-alone going + * Resume Celestial Carnage - see its TODO + * Implement timesynk's Virtual Machine compiler + +,,,,,,,,,,,,,,,,,,,,,,,, +Fun Things of Precedence +```````````````````````` + * Create timelapse videos for Newsboy and VAD + * Finish up SDL renderer for VAD 0.2 and release it. + * Create a narrative of Carmack's idTech engines for the YouTubes + * Finish LootKeeper and Get It Out There + * Implement last aspects of MediaServe (JavaScript linkage) + * Implement networking of ktk_walker and test it out + +,,,,,,,,,,,,,,,,,,,,,,,, +Extraneous Things of Learning +```````````````````````` + * Learn to read Braille + * Resume learning Japanese + * Begin learning Chinese + * Learn ASL or some equivalent + * Learn Russian diff --git a/aphorism/future_think.ktx b/aphorism/future_think.ktx new file mode 100644 index 0000000..9b6321a --- /dev/null +++ b/aphorism/future_think.ktx @@ -0,0 +1 @@ +Expedite progress -- think in the future, not in the now. The now has had enough thought from the past. Become estranged from the now. diff --git a/aphorism/order_of_precedence.ktx b/aphorism/order_of_precedence.ktx new file mode 100644 index 0000000..e8cc9dc --- /dev/null +++ b/aphorism/order_of_precedence.ktx @@ -0,0 +1,3 @@ +The **Order of Precedence** is to //improve oneself//, //learn//, and //have fun//. One should first seek to improve oneself. Improving oneself often comes through learning. Learning comes best with it is fun. + +If learning is not fun, one must still learn. If improving oneself does not acquire new knowledge, one must still improve. In this way, one must always seek these things, but be willing to do away with the least of them. diff --git a/aphorism/society_1.ktx b/aphorism/society_1.ktx new file mode 100644 index 0000000..9cc83a1 --- /dev/null +++ b/aphorism/society_1.ktx @@ -0,0 +1 @@ +Societies and their idiosyncracies see themselves as the pinnacle of all worlds -- the only possible -- or probable -- formation of society. diff --git a/aphorism/society_2.ktx b/aphorism/society_2.ktx new file mode 100644 index 0000000..63052de --- /dev/null +++ b/aphorism/society_2.ktx @@ -0,0 +1 @@ +To society's human, the first principles of society are seen as immutable properties of general human organization and being. Every possible world is seen through a strict lense of societal-formulative biases -- core fundamentals taken for granted as the required basis for humanity. diff --git a/aphorism/society_3.ktx b/aphorism/society_3.ktx new file mode 100644 index 0000000..dc4e45b --- /dev/null +++ b/aphorism/society_3.ktx @@ -0,0 +1 @@ +Move beyond modern limitations, doubt fundamentals and entertain worlds void of preformulated idiosyncrasies. Imagine and strive towards the altogether different. diff --git a/build.sh b/build.sh index 5db0bcf..40a83bc 100755 --- a/build.sh +++ b/build.sh @@ -1,8 +1,49 @@ #!/bin/bash echo "Placing structure..." mkdir -p live -cp -pf *.php live/ -cp -pf *.css live/ +echo " Copying PHP..." +cp -pfv *.php live/ +echo " Copying javascript..." +mkdir -p live/javascript +cp -pfv javascript/*.js live/javascript/ +echo " Copying CSS..." +mkdir -p live/css +cp -pfv css/*.css live/css/ +echo " Copying fonts..." +mkdir -p live/fonts +cp -pfv fonts/* live/fonts/ +echo " Copying images..." +mkdir -p live/pix +cp -pfv pix/* live/pix/ echo "Building kettext..." ../kettext/kettext.pl menu.ktx > live/menu.html ../kettext/kettext.pl front.ktx > live/front.html +../kettext/kettext.pl proclib.ktx > live/proclib.html +../kettext/kettext.pl TODO.ktx --header.depth=2 > live/TODO.html +echo "Building aphorism..." +mkdir -p live/aphorism +for f in aphorism/* +do + html=`echo $f | sed 's/\(.*\.\)ktx/\1html/'`; + ../kettext/kettext.pl $f --version.none > live/$html +done +echo "Building dox..." +../kettext/kettext.pl dox.ktx > live/dox.html +mkdir -p live/dox +for f in dox/* +do + html=`echo $f | sed 's/\(.*\.\)ktx/\1html/'`; + ../kettext/kettext.pl $f --version.none --header.depth=2 > live/$html +done + +echo "Copying plans..." +../kettext/kettext.pl plans.ktx > live/plans.html +mkdir -p live/plans +for f in ~/.plans/* +do + #html=`echo $f | sed 's/\(.*\.\)plan/\1html/'`; + #base=`basename $html`; + base=`basename $f`; + cp $f live/plans/$base + #../kettext/kettext.pl $f --version.none > live/plans/$base +done diff --git a/css/.style.css.swp b/css/.style.css.swp new file mode 100644 index 0000000..6e5ea30 Binary files /dev/null and b/css/.style.css.swp differ diff --git a/css/.style_pretty.css.swp b/css/.style_pretty.css.swp new file mode 100644 index 0000000..f8a4d8c Binary files /dev/null and b/css/.style_pretty.css.swp differ diff --git a/css/style.css b/css/style.css new file mode 100644 index 0000000..0c817c7 --- /dev/null +++ b/css/style.css @@ -0,0 +1,218 @@ +/* fonts */ +@font-face { + font-family: "Antonio"; + src: url("../fonts/Antonio-Regular.eot"), url("../fonts/Antonio-Regular.eot?#iefix") format("embedded-opentype"), local("Antonio-Regular.ttf"), url("../fonts/Antonio-Regular.ttf") format("truetype"); + font-style: normal; +} +@font-face { + font-family: "Antonio"; + src: url("../fonts/Antonio-Light.eot"), url("../fonts/Antonio-Light.eot?#iefix") format("embedded-opentype"), local("Antonio-Light.ttf"), url("../fonts/Antonio-Light.ttf") format("truetype"); + font-style: italic; +} +@font-face { + font-family: "Antonio"; + src: url("../fonts/Antonio-Bold.eot"), url("../fonts/Antonio-Bold.eot?#iefix") format("embedded-opentype"), local("Antonio-Bold.ttf"), url("../fonts/Antonio-Bold.ttf") format("truetype"); + font-style: bold; +} + +@font-face { + font-family: "ProggyTinySZ"; + src: url("../fonts/ProggyTinySZ.eot"), url("../fonts/ProggyTinySZ.eot?#iefix") format("embedded-opentype"), local("ProggyTinySZ.ttf"), url("../fonts/ProggyTinySZ.ttf") format("truetype"); +} + +/* */ +body { + background-color: #FFF; + font-family: "Source Sans Pro"; +} +/* general helper classes */ +.min { + margin: 0 auto; + width: 1000px; +} +.padder { + padding: 1em; + margin: 0; +} +/* header styling */ +#header { + position: relative; + float: left; + min-height: 128px; + width: 100%; + text-align: center; + color: #9F9F9F; + font-size: 14pt; + line-height: 110%; + background-color: #fff; +} + +.qat_bubble { + width: 800px; + color: #EDDDDD; + background-color: #322222; + margin: 0; + padding: 0; +} + +.qat_bubble p { + padding: 0; + margin: 0; +} + +#puss { + float: right; + z-index: 1; + display: block; + width: 128px; + height: 128px; + background-image:url('../pix/puss.png'); + margin-top: -24px; + background-repeat: no-repeat; +} +/* content styling */ +#container { + padding: 15px 0; + clear: both; + text-align: left; +} +.surf { + padding: 0.2em; + background-color: #D0D0D1; + color: #121; + color: #EDDDDD; + background-color: #322222; + background-color: #CaCf90; +} +/* */ +#menu { + position: relative; + width: 23%; + min-height: 70%; + float: right; + background-color: #FFF; + color: #1F1F1F; + font-size: 16pt; + line-height: 150%; +} +#menu ul { + padding: 0; margin: 0; + list-style: none; + font-family: "Antonio"; +} + +#menu ul li { + width: 100%; + background-color: #D0D0D1; + color: #121; + border-bottom: 1px solid #322222; +} + +#menu ul a { + color: #9f9f60; +} + +#menu h1 { + position: relative; + font-family: "Antonio"; + font-size: 18pt; + padding: 0.1em; + color: #EDDDDD; + background-color: #322222; +} + +#menu a { + display: block; + width: 100%; + text-decoration: none; +} +/* */ +#content { + position: relative; + float: left; + width: 70%; + margin-top: 1em; + padding: 0.25em; + margin-left: 5%; + min-height: 70%; + background-color: #FFFFEE; + color: #1F1F1F; + margin-bottom: 1em; + font-size: 12pt; + line-height: 125%; +} +#content h1, h2, h3, h4, h5, h6 { + position: relative; + font-family: "Antonio"; + padding: 0.5em; + color: #EDDDDD; + background-color: #322222; +} +#content p { + padding-left: 1em; padding-right: 1em; +} + +#content ul { + padding-left: 1em; padding-right: 1em; + margin-left: 2em; +} + +#content pre { + width: auto; + padding: 0.5em; + margin: 2em; + background-color: #D0D0D1; + color: #121; + font-family: "ProggyTinySZ"; + line-height: 70%; + width: 500px; /* specify width */ + white-space: pre-wrap; /* CSS3 browsers */ + white-space: -moz-pre-wrap !important; /* 1999+ Mozilla */ + white-space: -pre-wrap; /* Opera 4 thru 6 */ + white-space: -o-pre-wrap; /* Opera 7 and up */ + word-wrap: break-word; /* IE 5.5+ and up */ +} +#content pre code:after { + content: 'code'; + width: 100%; + display: block; text-align: right; + color: #B0B0B1; + padding: 0; + margin: 0; +} +#content code { + font-family: "ProggyTinySZ"; +} + +#content h1:hover, h2:hover, h3:hover, h4:hover, h5:hover, h6:hover { + color: #CaCf90; + cursor: pointer; +} + +.arrow { + display: inline-block; + position: relative; + margin-left: 1em; + width: 0; + height: 0; + border-top: 10px solid transparent; + border-bottom: 10px solid transparent; + + border-left: 20px solid #7f7f7f; +} + +#content h1:hover .arrow, h2:hover .arrow, h3:hover .arrow, h4:hover .arrow, h5:hover .arrow, h6:hover .arrow { + border-left: 20px solid #CfCf90; +} + +.arrow_open { + display: inline-block; + position: relative; + margin-left: 1em; + width: 0; + height: 0; + border-left: 10px solid transparent; + border-right: 10px solid transparent; + + border-top: 20px solid #CfCf90; +} diff --git a/css/style_pretty.css b/css/style_pretty.css new file mode 100644 index 0000000..4e123e6 --- /dev/null +++ b/css/style_pretty.css @@ -0,0 +1,120 @@ +.shadow_inset { + -webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.8), 0 0 40px rgba(0, 0, 0, 0.4) inset; + -moz-box-shadow:0 1px 4px rgba(0, 0, 0, 0.8), 0 0 40px rgba(0, 0, 0, 0.4) inset; + box-shadow:0 1px 4px rgba(0, 0, 0, 0.8), 0px -20px 40px rgba(0, 0, 0, 0.4) inset; +} +.shadow_inset:before, +.shadow_inset:after { + content: ""; + position: absolute; + z-index: -2; + bottom:15px; + left:10px; + width:50%; + height:20%; + -webkit-box-shadow:0 15px 10px rgba(0, 0, 0, 0.7); + -moz-box-shadow:0 15px 10px rgba(0, 0, 0, 0.7); + box-shadow:0 15px 10px rgba(0, 0, 0, 0.7); + -webkit-transform:rotate(-3deg); + -moz-transform:rotate(-3deg); + -ms-transform:rotate(-3deg); + -o-transform:rotate(-3deg); + transform:rotate(-3deg); +} + +.surf { + -webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.8), 0 0 40px rgba(0, 0, 0, 0.4) inset; + -moz-box-shadow:0 1px 4px rgba(0, 0, 0, 0.8), 0 0 40px rgba(0, 0, 0, 0.4) inset; + box-shadow:0 1px 4px rgba(0, 0, 0, 0.8), 0px 0px 16px rgba(0, 0, 0, 0.4) inset; + -webkit-border-radius:3px 1px 1px 3px; + -moz-border-radius:3px 1px 1px 3px; + border-radius:1px 1px 3px 3px; +} + +.qat_bubble { + position:relative; + padding:16px; + margin:1em 0 1em; + -webkit-border-radius:10px; + -moz-border-radius:10px; + border-radius:10px; + -webkit-box-shadow:0 1px 2px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 0, 0, 0.4); + -moz-box-shadow:0 1px 2px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 0, 0, 0.4); + box-shadow:0 1px 2px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 0, 0, 0.4); +} +.qat_bubble:after { + content:""; + position:absolute; + top: 24px; + right: -32px; + bottom: auto; + left: auto; + border-width:10px 0 10px 32px; /* vary these values to change the angle of the vertex */ + border-style:solid; + border-color: transparent #322222; + /* reduce the damage in FF3.0 */ + display:block; + width:0; +} + +#header { + box-shadow:-1px 1px 1px rgba(0, 0, 0, 0.8), -20px 0px 40px rgba(0, 0, 0, 0.2) inset; +} + +#menu { + -webkit-box-shadow:0 0 40px rgba(0, 0, 0, 0.2) inset; + -moz-box-shadow:0 0 40px rgba(0, 0, 0, 0.2) inset; + box-shadow:-1px 2px 1px rgba(0, 0, 0, 0.8), 0px 0px 40px rgba(0, 0, 0, 0.2) inset; + -webkit-border-radius:3px 1px 1px 3px; + -moz-border-radius:3px 1px 1px 3px; + border-radius:1px 1px 3px 3px; +} + +#content { + -webkit-box-shadow:0 0 40px rgba(0, 0, 0, 0.2) inset; + -moz-box-shadow:0 0 40px rgba(0, 0, 0, 0.2) inset; + box-shadow:-1px 1px 1px rgba(0, 0, 0, 0.8), 0px 0px 40px rgba(0, 0, 0, 0.2) inset; + -webkit-border-radius:3px 1px 1px 3px; + -moz-border-radius:3px 1px 1px 3px; + border-radius:3px 1px 1px 3px; +} + +#menu h1, h2, h3, h4, h5, h6 { + -webkit-box-shadow:1 0px 1px rgba(0, 0, 0, 0.8); + -moz-box-shadow:0 0px 1px rgba(0, 0, 0, 0.8); + box-shadow:-2px 0px 1px rgba(0, 0, 0, 0.8); + margin-left: -10%; + font-weight: bold; +} + +#menu h1 { margin-left: -10%; } + + +#content h1, h2, h3, h4, h5, h6 { + -webkit-box-shadow:1 0px 1px rgba(0, 0, 0, 0.8); + -moz-box-shadow:0 0px 1px rgba(0, 0, 0, 0.8); + box-shadow:-2px 0px 1px rgba(0, 0, 0, 0.8); + margin-left: -10%; + margin-top: 0.5em; + font-weight: bold; +} + +#content h1 { margin-left: -10%; font-size: 24pt; } +#content h2 { margin-left: -9%; font-size: 22pt; } +#content h3 { margin-left: -8%; font-size: 20pt; } +#content h4 { margin-left: -7%; font-size: 18pt; } +#content h5 { margin-left: -6%; font-size: 16pt; } +#content h6 { margin-left: -5%; font-size: 14pt; } + +#content pre { + -webkit-box-shadow: 0px 0 30px rgba(0, 0, 0, 0.1) inset; + -moz-box-shadow: 0px 0 30px rgba(0, 0, 0, 0.1) inset; + box-shadow: 0px 0 30px rgba(0, 0, 0, 0.1) inset; +} + + +.shadow_light { + -webkit-box-shadow:0 0px 1px rgba(0, 0, 0, 0.8); + -moz-box-shadow:0 0px 1px rgba(0, 0, 0, 0.8); + box-shadow:0 0px 1px rgba(0, 0, 0, 0.8); +} diff --git a/css/style_reset.css b/css/style_reset.css new file mode 100644 index 0000000..785ef49 --- /dev/null +++ b/css/style_reset.css @@ -0,0 +1,80 @@ +/* This file resets EVERYTHING */ +html, body, div, span, applet, object, iframe, +h1, h2, h3, h4, h5, h6, p, blockquote, pre, +a, abbr, acronym, address, big, cite, code, +del, dfn, em, font, img, ins, kbd, q, s, samp, +small, strike, strong, sub, sup, tt, var, +dl, dt, dd, ol, ul, li, +fieldset, form, label, legend, +table, caption, tbody, tfoot, thead, tr, th, td { + margin: 0; + padding: 0; + border: 0; + outline: 0; + font-weight: inherit; + font-style: inherit; + font-size: 100%; + vertical-align: baseline; +} +/* remember to define focus styles! */ +:focus { + outline: 0; +} +body { + line-height: 1; + color: black; + background: white; +} +ol, ul { + /*list-style: none;*/ +} +/* tables still need 'cellspacing="0"' in the markup */ +table { + border-collapse: separate; + border-spacing: 0; +} +caption, th, td { + text-align: left; + font-weight: normal; +} +blockquote:before, blockquote:after, +q:before, q:after { + content: ""; +} +blockquote, q { + quotes: "" ""; +} + +strong { + font-weight:bold;color:#0289ce; +} + +em { + font-style:oblique; +} + +p { + margin:15px 0; +} + +.aligncenter, div.aligncenter { + display: block; + margin-left: auto; + margin-right: auto; +} +.alignleft { + float: left; +} +.alignright { + float: right; +} + +h1 {font-size:180%;} +h2 {font-size:150%;} +h3 {font-size:125%;} +h4 {font-size:100%;} +h5 {font-size:90%;} +h6 {font-size:80%;} + +a:link {color:#0289ce;} +a:hover {color:#f64274;} diff --git a/css/style_smooth.css b/css/style_smooth.css new file mode 100644 index 0000000..2562536 --- /dev/null +++ b/css/style_smooth.css @@ -0,0 +1,2 @@ +/* this file stacks on top of style.css and add additional prettiness */ + diff --git a/dox.ktx b/dox.ktx new file mode 100644 index 0000000..67105a3 --- /dev/null +++ b/dox.ktx @@ -0,0 +1,4 @@ +.imply(version.hide) +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +Documents and Articles +```````````````````````````````` diff --git a/dox/initial_source_release.ktx b/dox/initial_source_release.ktx new file mode 100644 index 0000000..bdcfb30 --- /dev/null +++ b/dox/initial_source_release.ktx @@ -0,0 +1,47 @@ +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +Release Your ((Engine's)) Source +```````````````````````````````` +As a game developer and a free software advocate, an inevitable question comes up of whether or not to release one's video game engine under a free software or open source license. The immediate question that comes to mind when commercial video game production is held at the forefront is that such a release could endanger the commercial success or profit of the game due to competing products being released using the same code base. However, while this appears as an initial concern, there are, as far as I understand, no rational reasons for adhering to this belief. + +To highlight the chances of risk, let us first analyze what could happen through a delayed source release pattern. Let us assume that Game A is a non-free video game that is being developed by a Studio. Game A uses Engine Z which does not include the art, sound, and other similar, non-engine related assets. In this way, Game A can be broken down into the Engine and the Assets. + +After the initial release of the game, which is met with moderate success, the Studio decides to release the source code for Engine Z under a free software license. The Assets for the game are not included with the source code, as the users must generate their own content for Engine Z to allow for a new game to function. Various potentials crop up from this release, which are expounded upon and addressed in terms of probability below. +```````````````````````````````` +1. A competing product is made that potentially impacts post-release profit. + +Although this could occur, the potential of it varies greatly depending on how specific the engine is towards particular game mechanics and logic. The more generalized the engine is, the greater potential there is for a new product to be made from said engine. If the engine is specialized, only similar games can be made. + +However, how much probability is there in a new product being made from another engine? Given that there are, as far as my research goes, no successful commercial games that were created from an free software or open source released engine created for a commercial game, it seems fairly improbable. Licensed engines, such as id's various idtech engines, do not count for the reason that at the time their licensing the source code was not released as open source or free software. The absence of this occurance does not guarantee that it could not happen, of course. All the same, there is no compelling argument for this occurring. + +In the event of such a (thus far improbable) commercial game from a free software released engine, what would actually occur? + + 1. Any modifications to the engine's code must be released under the same terms as the free software license, thus keeping knowledge available and increasing user and developer freedom. + 2. Depending on the release time and the type of new game using the free software engine, profit for the original developer may or may not be impacted. Given that developing a game, especially a coherent game with a full body of assets, takes much time and effort, it seems unlikely that any substantial profit impact could even occur. + +In summation, given that no examples exist of a commercial game being made from a previously released commercial game's engine actually succeeding or even existing in the first place, it seems unlikely that it is even a concern. If a competing game was actually released, it would require a full body of new assets that take a great amount of time and effort to create, thus severely reducing chance for commercial competition. Furthermore, any engine modifications for the new game would have to be released under the same license as the original engine, thus maintaining freedom of and access to knowledge as per free software. + +2. Game exploits are created. + +This concern is far more legitimate than the first, for the reason that providing an absolute transparency and access to the engine's inner workings mean that reverse engineering does not need to be done. However, the amount of concern for this is dependent on both the type and the design of the game in question. For most games, exploits are inevitable. If the game is a single-player game or most any non-competitive game, the exploits are irrelevent as they only serve to change the game experience for the player. This does not impact profit. + +However, in the case of multiplayer games, and especially competitive games, exploits impact more than an individual user and are thus a concern. As is known within the gaming world, exploits - or hacks - are inevitable and something you have to deal with. In general, most anti-hacking systems (such as binary checksumming or similar) can be bypassed. The most trustworthy form of defense is, as is common in the gaming world, having democratic votekicking systems or knowledgable administrators to ban or kick exploitative players. + +Given the premise that exploits are ultimately unavoidable, there are methods to counter based on game and network design. For example, if the game uses a centralized server model, wherein a single server ultimately controls the data and logic of all game entities, exploits such as speed hacking can be detected by ensuring the player does not exceed particular movement speeds via particular methods in some given upper limit of ticks. Furthermore, information such as player location, health, and otherwise does not have to be transferred to a given player unless the player is in line-of-sight or within some distance of the other player. Given this, even if the player modifies their client to see health or location, the server does not send enough information unless the situation requires that player knowing that information. + +In a non-centralized server model, such as a client-to-client command relay design as used in RTS games such as Starcraft for Age of Empires, exploitation can be limited in that any significant changes to a client's engine would result in a desyncronization of that client. This results in one player experiencing an entirely different outcome separate from the other players, thus nullifying the reason for exploit. However, as was and is the problem with said design, players can use the commands relayed to acquire information on the competing players' units (maphacks, etc.). The counter is to do some form of checksumming that does not only check the binary checksum, which can be easily counterfeited, but rather checksums some amount of live game data between all clients, notifying all clients when a discrepancy is found. One method would be to use the current command history to check if an exploiting player is seeing more of the game world or accessing more than they should be from their relative position. This could be done from any of the clients connected or from a third-party service that simulates command activity. + +In summation, exploitation is inevitable and releasing source code may increase the frequency. However, any increase of exploitation due to source release is entirely speculative and could actually result in a decrease due to exploitation or security patches being found and created in the first place. Furthermore, the design of an engine will likely be the most authorative method of dealing with exploits, regardless of source code availability or not. Finally, anti-exploit measures, in the form of detection systems, are possible, however the most reliable form is that of community-based policing via admins or votekicking. + +3. Easy Piracy of the Game + +Of the two concerns provided thus far, piracy is the most legitimate concern, as most any protection scheme can be by-passed with greater ease due to source availability. Some methods can be created that reduce the chance of this, such as a centralized server that authenticates users based on a product key or account information, however such methods could also be by-passed. However, I hold that this is little different than the current and historical situation of game piracy. As it stands, DRM-style systems are not effective at preventing piracy and generally do best at hindering legitimate users from playing the game they paid for. + +Combating piracy is a losing game in which the only vaguely effective method is to restrict the freedoms of legitimate purchasers to such an extreme level that would inevitably lead to a decrease in overall profit due to cumbersome and annoying user restriction. + +In summation, even in the non-free world, fighting piracy with DRM is a losing battle that rarely stops illegitimite users and primarily hurts legitimate users. The best combat is to create a fun game with a strong community connection that values and empowers players. If players, regardless of piracy or not, are empowered and valued, they will feel a greater compulsion to support the original developers. +```````````````````````````````` +Given this analysis, it is clear that arguments against source code release of a game's engine ultimately hold little to no water. Competiting products made from the source code are highly unlikely due to the long development window required to create entirely new assets. Exploitation is ultimately the same regardless of source code release or not. Preventing piracy is as it is - a losing battle that fails at any real prevention and usually hurts legitimate players most in the process. + +There may be some cases wherein source code release could impact long-term profit not from the original game itself, as other developers could use the source code rather than a licensed engine to develop a new game. However, they would have to release modified works under the same license. It is worth noting that the original developer could do a closed license version to another company that is non-free so long as it does not use any new code contributed under the open source license. + +In conclusion, source code release, whether immediate or delayed, causes little to no substantial problems for profit, exploitation, or piracy. Left unaddressed is the potential for public relations and community support and development that could result from source code release. diff --git a/fonts/Antonio-Bold.ttf b/fonts/Antonio-Bold.ttf new file mode 100644 index 0000000..20a35d1 Binary files /dev/null and b/fonts/Antonio-Bold.ttf differ diff --git a/fonts/Antonio-Light.ttf b/fonts/Antonio-Light.ttf new file mode 100644 index 0000000..1b3f910 Binary files /dev/null and b/fonts/Antonio-Light.ttf differ diff --git a/fonts/Antonio-Regular.ttf b/fonts/Antonio-Regular.ttf new file mode 100644 index 0000000..9f8759a Binary files /dev/null and b/fonts/Antonio-Regular.ttf differ diff --git a/fonts/ProggyTinySZ.ttf b/fonts/ProggyTinySZ.ttf new file mode 100644 index 0000000..bc4a1ad Binary files /dev/null and b/fonts/ProggyTinySZ.ttf differ diff --git a/fonts/SIL Open Font License.txt b/fonts/SIL Open Font License.txt new file mode 100644 index 0000000..295975a --- /dev/null +++ b/fonts/SIL Open Font License.txt @@ -0,0 +1,43 @@ +Copyright 2010, 2012 Adobe Systems Incorporated (http://www.adobe.com/), with Reserved Font Name 'Source'. All Rights Reserved. Source is a trademark of Adobe Systems Incorporated in the United States and/or other countries. + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others. + +The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the copyright statement(s). + +"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. + +"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. + +5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. \ No newline at end of file diff --git a/index.php b/index.php index 95fb376..fda5573 100644 --- a/index.php +++ b/index.php @@ -1,30 +1,78 @@ +$value) { + if ($get == $page) { + $current_page = $page; + } + } +} +// Get our aphorism +$aphs = scandir('aphorism/'); +$aphorism = "aphorism/".$aphs[2 + (date("d") % (count($aphs)-2))]; + +if ($current_page == "plans") { + if ($_GET["plans"] == '') { + $plans = scandir('plans/'); + for ($i = 2; $i < count($plans); $i++) { + $post .= "".$plans[$i]."
\n"; + } + } else { + $plans = scandir('plans/'); + for ($i = 2; $i < count($plans); $i++) { + if ($plans[$i] == $_GET['plans']) break; + } + + $post .= "

".$_GET['plans']."

"; + $post .= "
"; + if ($i-1 >= 2) { + $post .= '<< '.$plans[$i-1].''; + } + $post .= ' index '; + if ($i+1 < count($plans)) { + $post .= ''.$plans[$i+1].' >>'; + } + $post .= "
"; + $post .= "
".htmlentities(file_get_contents("plans/".$_GET['plans']))."
"; + } +} else if ($current_page == "dox") { + if ($_GET["dox"] == '') { + $dox = scandir('dox/'); + for ($i = 2; $i < count($dox); $i++) { + $post .= "".$dox[$i]."
\n"; + } + } else { + $post .= 'Back to index
'; + $post .= (file_get_contents("dox/".$_GET['dox'])); + } +} + +?> kettek - - - - + + + + + - diff --git a/javascript/folder.js b/javascript/folder.js new file mode 100644 index 0000000..25d096e --- /dev/null +++ b/javascript/folder.js @@ -0,0 +1,78 @@ +/* +This file provides folding of sections of text +*/ +var toggleHidden = function(arrow, target) { + if (target.style.display == "none") { + target.style.display = "block"; + arrow.className = "arrow_open"; + } else { + target.style.display = "none"; + arrow.className = "arrow"; + } +}; +var createFolds = function() { + var context = document.getElementById("content"); + foldHeader(context, "H2"); +}; + +var foldHeader = function(context, type) { + if (!context.hasChildNodes()) return; + var child = context.firstChild; + var prev_child = child; + var header = null; + var section = null; + var open = 0; + + while (child) { + var next_child = child.nextSibling; + if (child.nodeName == type) { + if (section == null) { + header = child; + var arrow = document.createElement("div"); + arrow.className = "arrow_open"; + header.appendChild(arrow); + section = document.createElement("div"); + header.onclick = (function(header, arrow, section) { + return function(e) { + toggleHidden(arrow, section); + } + })(header, arrow, section); + toggleHidden(arrow, section); + open = 1; + } else { + if (header.nextSibling) { + context.insertBefore(section, header.nextSibling); + } else { + context.appendChild(section); + } + header = child; + var arrow = document.createElement("div"); + arrow.className = "arrow_open"; + header.appendChild(arrow); + section = document.createElement("div"); + header.onclick = (function(header, arrow, section) { + return function(e) { + toggleHidden(arrow, section); + } + })(header, arrow, section); + toggleHidden(arrow, section); + open = 1; + } + } else { + if (section != null) { + section.appendChild(child); + } + } + prev_child = child; + child = next_child; + } + if (open == 1) { + if (header.nextSibling) { + context.insertBefore(section, header.nextSibling); + } else { + context.appendChild(section); + } + } + +}; +window.onload = function() { createFolds() }; diff --git a/menu.ktx b/menu.ktx index 7d19a29..919b0e7 100644 --- a/menu.ktx +++ b/menu.ktx @@ -1,11 +1,18 @@ .imply(version.none) - * [[.plan]].href(?plans).alt(Of Action) - * Games - * [[Newsboy]].href(newsboy/).alt(Escape The Net) - * [[CirQuit]].href(CirQuit/).alt(Find Enlightenment) - * [[VAD]].href(VAD).alt(Get Vadding!) - * Projects - * [[kettext]].href(kettext/).alt(markup language) - * [[proclib]].href(proclib/).alt(procedural generation!) - * [[procsicle]].href(procsicle/).alt(PHP process linkage) - * [[noirchat]].href(noirchat/).alt(decentralized chatting at its finest) +==== [[General]] + * [[Articles]].href(?dox).alt(Wordsmithing) + * [[.plans]].href(?plans).alt(Of Action) + * [[TODO]].href(?TODO).alt(A lack of gettin' busy) +==== [[Games]] + * [[Newsboy/]].href(newsboy/).alt(Escape The Net) + * [[CirQuit/]].href(CirQuit/).alt(Find Enlightenment) + * [[VAD/]].href(VAD/).alt(Get Vadding!) +==== [[Projects]] + * [[kettext]].href(?kettext).alt(markup language) + * [[proclib]].href(?proclib).alt(procedural generation!) +==== [[Lab]].alt(less-than-complete things) + * [[procsicle]].href(?procsicle).alt(PHP process linkage and terminal client) + * [[noirchat]].href(?noirchat).alt(decentralized chatting at its finest) + +Tweets by @kts_kettek + diff --git a/pix/puss.png b/pix/puss.png new file mode 100644 index 0000000..dfd5d68 Binary files /dev/null and b/pix/puss.png differ diff --git a/plans.ktx b/plans.ktx new file mode 100644 index 0000000..03515c9 --- /dev/null +++ b/plans.ktx @@ -0,0 +1,5 @@ +.imply(version.none) +,,,,,,,,,,,,,,,,,,,,,,,, +[[plans]].href(?plans) +```````````````````````` +These plan files general contain information pertaining to what I'm working on at some given moment. Expect obtuse jargon without reference. diff --git a/proclib.ktx b/proclib.ktx new file mode 100644 index 0000000..b98226e --- /dev/null +++ b/proclib.ktx @@ -0,0 +1,637 @@ +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +Preface +```````````````````````` +What is proclib? Simply, a library and syntax language for cell-based map generation. + +However, it is much more than that -- it is a C library that allows for the creation of randomized and complex maps filled with a plethora of user-defined structures. + +Structures can be thought of as complex collections of entities/cells. From this, structures can be made up of other structures to increase the variation and complexity needed for a structure. Examples of structures are: castles, moats, ravines, towns, rooms, and much more. + +An example of structure definition syntax is: + + #circle { + # flags CIRCLE + # x 1~3 + # y 1~3 + # size_x 4~8 + # size_y 4~8 + # id_1 1 + #} + +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +Syntax +```````````````````````` +proclib structure definitions are written in plain text files with **very** simple formatting rules. A structures file can contain an ultimately unlimited amount of structures within it, and each structure can have various configurations applied that alter its generation behaviors. + +,,,,,,,,,,,,,,,, +Basic Syntax +```````````````` +Each structure is contained with a structure definition block such as: + + #my_structure { + # x 1 + # y 1 + #} + +Within a structure definition block, the following variables can be set: + + * **flags** -- defines the generation behavior using bitflags. Multiple flags can be set by piping them together (ex. "flags CIRCLE|BORDER|ORIGIN") + * Shape Generation + * //CIRCLE// - Bresenham-like ellipse generation + * //RECT// - basic "box" generation + * Shape Modification + * //BORDER// - creates an interior border using the current shape + * //IGNORE_EMPTY// - ignores cells that are empty (i.e., have no id_s written to them) + * Structure Placement + * //ORIGIN// - places the structure from its center + * //OVERLAP// - overlaps the structure on top of other potential structures + * **size_x, size_y** -- defines the size of the structure. Values may be: + * single numbers (e.g., "4") + * percentages (e.g., "50%" of parent's size) + * ranges of either (e.g., "25%~50%"). + * If omitted, defaults to 0, 0 + * **x, y** -- defines the position of the structure. Values may be: + * single numbers (e.g., "-4", "4") + * percentages (e.g., "-50%", "50%") + * ranges of either (e.g., "-50%~50%"). + * If omitted, defaults to 0, 0 + * **id_1** -- first id of the structure. Values may be: + * single numbers (e.g., "2") + * ranges (e.g., "1~4") + * comma-delimited sets of either (e.g., "2, 1~4") + * **id_2** -- second id of the structure. Follows same rules as id_1 + +Before delving into more complicated aspects of structure definitions, let us use some of the above information to create a simple structure. + +,,,,,,,,,,,, +A Simple Circle +```````````` +A rudimentary example that creates a variable-sized tower in the middle of the screen would be: + + tower { + flags CIRCLE + size_x 12~16 + size_y 9~14 + id_1 0 + } + +This would generate structures similar to the following: + + ........................................ + ....................0................... + .................0000000................ + ................000000000............... + ...............00000000000.............. + ...............00000000000.............. + ..............0000000000000............. + ...............00000000000.............. + ...............00000000000.............. + ................000000000............... + .................0000000................ + ....................0................... + ........................................ + +,,,,,,,,,,,,,,,, +Complex Syntax: Relations +```````````````` +Every structure can have 3 additional sets of information. The first I will cover is **relations**. A relation is, as the name implies, a relationship to another structure. In general, relations are used to create sub-structures within a structure. + +**Relations** are contained with a relations block, and each relation is defined in a similar method as a regular structure. Acceptable settings are: + + * **flags** -- same as structure flags, but override and/or stack on top of the given structure's flags + * **x, y** -- override position settings + * **count** -- defines how many times to generate this relation. Values may be: + * single numbers (e.g., "2") + * ranges (e.g., "2~6"). + * If omitted, defaults to 1. + +Using this new information, let us expand upon the earlier tower. + +,,,,,,,,,,,, +A Simple Tower +```````````` +An ellipse by itself is rather boring, but we can spice things up by using relations to create walls: + tower { + flags CIRCLE + size_x 12~16 + size_y 9~14 + id_1 0 + relations { + tower_walls { + flags CIRCLE|OVERLAP + } + } + } + tower_walls { + flags BORDER + size_x 100% + size_y 100% + id_1 1 + } + +This would generate a structure similar to the following: + ........................................ + ...................1.................... + ................1111111................. + ..............11100000111............... + ..............10000000001............... + .............1100000000011.............. + ..............10000000001............... + ..............11100000111............... + ................1111111................. + ...................1.................... + ........................................ + +,,,,,,,,,,,,,,,, +Complex Syntax: Replace +```````````````` +With the concept of relations out of the way, we can move into the **replace** functionality. + +**Replace** rules are contained in a replace block and define what type of **id_1** and **id_2** tiles may be replaced. The possible values in a replace block are: + + * **id_1** -- list of primary IDs that may be replaced. Values may be: + * single positive numbers (e.g., "4") + * positive ranges (e.g., "1~4") + * comma-delimited sets of either (e.g., "1, 3~8, 12) + * **id_2** -- list of secondary IDs that may be replaced. Values may be the same as id_1. + +For this example, we're going to use another structure to remove a section of walls from the tower. + +,,,,,,,,,,,, +Holy Tower +```````````` + tower { + flags CIRCLE + size_x 12~16 + size_y 9~14 + id_1 0 + relations { + tower_walls { + flags CIRCLE|BORDER|OVERLAP + } + hole { + x 50% + y 50% + } + } + } + tower_walls { + flags BORDER + size_x 100% + size_y 100% + id_1 1 + } + hole { + flags RECT|IGNORE_EMPTY + size_x 100% + id_1 0 + replace { + id_1 1 + } + } + +What we've done here is create a new "hole" structure that replaces any overlapping cell with an id_1 of "1" with "0". We've added this structure as a relation to the tower so that it is applied appropriately. The IGNORE_EMPTY flag is only used to prevent the replacement of empty (unset) tiles. + +The resulting replacement would generate something similar to: + ........................................ + ...................1.................... + ................1111111................. + ..............11100000111............... + ..............10000000001............... + .............1100000000000.............. + ..............10000000000............... + ..............11100000000............... + ................1111000................. + ...................1.................... + ........................................ + +,,,,,,,,,,,,,,,, +Complex Syntax: Paths +```````````````` +The (currently!) final important structure generating concept is that of **paths**. The first key concept is to realize that paths are generated in a separate pass from initial structures. During structure generation, structures are built and then recorded as "live structures". After this, these live structures are checked for any pathing configuration, and if found, a pathing pass is made. The pathing pass itself generates new live structures for every path "step" made (kept separately from the previous!) and handles the building as per normal operations. + +A **path** is a configuration within a structure that defines some form of pathing behavior. This includes from/to destination structures, position offsets, structure to use for pathing, pathing algorithm, and others. Acceptable settings for a path are: + + * **flags** -- these define the behaviors of the pathing + * Algorithms/Movement + * //DUMB// -- doggedly move towards "to" by incrementing or decrementing x and y position. Is stopped by cells that cannot be replaced and are not empty. + * //A*// -- uses A* to intelligently move towards position (NOT IMPLEMENTED (YET!)) + * //WALK// -- only move one cell in one direction at a time (e.g., x+1 OR y+1, not both) + * //WANDER// -- some odd chance to randomly move x or y in a direction. Requires an Algorithm. + * Looping + * //ALL// -- attempt to path find to all targets that match the to pathing syntax + * Etc. + * //FORCE// -- if pathing movement fails too many times(>32), force movement anyway + * //UNIQUE// -- only look for from/to targets that have not been pathed to/from by this structure + * **to** -- pathing syntax for the structure to path to - REQUIRED + * **to_flags** -- flags that define a specific "to" behavior + * //ORIGIN// -- you guessed it, to_x/to_y values are relative to the center of the target + * **to_x, to_y** -- position to path to. Values may be: + * single numbers (e.g., "1", "-1") + * percentages (e.g., "25%") + * ranges (e.g., "-25%~25%", "-5~5") + * sets of any (e.g., "1, 25%, -5~5") + * **from** -- pathing syntax for the structure to path from. If omitted, defaults to the structure making this path. + * **from_flags** -- same as to_flags + * **from_x, from_y** -- same as to_x, to_y + * **x, y** -- positional data that is applied to each pathing step. Values may be: + * single numbers (e.g., "-1") + * ranges (e.g., "-1~1") + * sets of either (e.g., "-1, -1~1") + +,,,,,,,,,,,, +Pathing Syntax +```````````` +Pathing syntax, used for **to** and **from** in pathing, refers to live structures and uses a straight-forward syntax contained in a single string. An example pathing syntax string could be: ":tower:hole" The following are the single-character "commands" used to acquire a live structure. + + * **:** -- if the first character of the string, get the global "root" live structure + * **:** -- otherwise it is used a position delimiter to specify parent->child + * **^** -- get parent of this context's live structure + +These can be combined to acquire live structures in complex structures. Examples: + + * "tower" -- look for a structure named "tower" in the current context. + * ":tower" -- look for a structure named "tower" in the root context. + * "^tower" -- look for a structure named "tower" in the parent of the current context. + * "^^towers:tower:room" -- look for a structure named "room" in "tower" in "towers" in the parent of the parent of the current context. + +Context is assumed to be the live structure containing the path definitions. +Let us use this new-found knowledge to create a road between the towers of two rival wizards. +,,,,,,,,,,,, +The Two Towers +```````````` +This example expands on the preceding example by creating a wall-removing path between two towers. + tower { + flags CIRCLE + size_x 8~12 + size_y 7~10 + id_1 0 + relations { + tower_walls { + flags CIRCLE|OVERLAP + } + } + } + tower_walls { + flags BORDER + size_x 100% + size_y 100% + id_1 1 + } + dirt_path { + flags RECT + size_x 1 + size_y 1 + id_1 0 + replace { + id_1 1 + } + } + towers { + size_x 100% + size_y 100% + relations { + tower { + count 2 + x 10~75% + y 10~75% + } + } + paths { + dirt_path { + flags DUMB|WALK + to tower + to_flags ORIGIN + from tower + from_flags ORIGIN + } + } + } + +This would create a scene similar to: + ...............1........................ + ............1111111..................... + ...........110000011.................... + ..........11000000011................... + ...........110000011.......1............ + ............1111100.....1111111......... + ...............1..00...110000011........ + ...................00..100000001........ + ....................0011000000011....... + .....................00000000001........ + .......................110000011........ + ........................1111111......... + ...........................1............ + +This should give a fairly concise overview of proclib, although there are likely to be massive enhancements and changes in the future. :) +,,,,,,,,,,,,,,,, +Other Examples +```````````````` +,,,,,,,,,,,, +Little House by the Lake +```````````` + ................................................................ + .........8.......8.........8.8.........88......8.8.............. + ......11111111111.........8....8........................8....... + ......10000000001.........8....8................................ + .....8100000000018.8........................8....8.............. + ......11111111111.............8.8...........8...............8... + .......................8........................................ + ......8.......8...........................8.....8...........8..8 + ............................................8................... + ..8........................8......8.........................8... + ...8..8....8.......8....8........8.............................. + ........................................8..............8........ + .......8.....................8....8......................8...... + ..........8..8.........88........................8...8...8..8... + ......8...............8..8.......8.................8.....0....8. + ......88...............8.................8..........000000000000 + ...8.............8...............................000000000000000 + ..8....8...............88.......................0000000000000000 + ............................8.................000000000000000000 + ....8..................8......8.........8....0000000000000000000 + ........8..............8....................00000000000000000000 + ...................................8.......000000000000000000000 + .....8..........8...8.........8............000000000000000000000 + +-------- + + tree { + flags RECT + size_x 1 + id_1 8 + } + lake { + flags CIRCLE|OVERLAP + size_x 50~75% + id_1 0 + } + house { + flags RECT + size_x 9~14 + size_y 4~7 + id_1 0 + relations { + house_walls { + flags RECT + } + } + } + house_walls { + flags BORDER|OVERLAP + size_x 100% + size_y 100% + id_1 1 + } + start { + size_x 64 + size_y 32 + relations { + lake { + count 4~6 + x 50~80% + y 70~80% + } + tree { + count 64~128 + x 0~100% + y 0~100% + } + house { + flags OVERLAP + count 1 + x 10~50% + y 10~50% + } + } + } + +,,,,,,,,,,,, +Lumpy Castle +```````````` +The structure definition for this one is exceptionally bad and could be refactored. + + ................................................................. + ............................................................9.... + ...9.......1.........................9........1.................. + ........1111111............................1111111............... + .......110000011..........................1100000119............. + .......100000001..........................100000001.............. + .......100000001.....................9....100000001......9....... + ......1100000001111111111111111111111111111000000011............. + .......100000000000000000000000000000000000000000001............. + .......100000000000000000000000000000000000000000001............. + .......110000001111111111111111111111111111100000011....9........ + ........11000011...........9...............11000011.............. + .........100001.............................100001............... + .........100001..............1......9.......100001............... + .........100001...........1111111...........100001............... + .........100001...9......110000011..........100001............... + .........100001..........100000001..........100001............... + .........100001........9.100000001..........100001..............9 + .........100001.........11000000011.........100001............... + .........100001..........100000001..........100001............... + .........100001..........100000001..........100001............... + .9.......100001..........110000011..........100001............... + .........100001...........1111111...........100001............... + .........100001.....9........1..............100001............... + ........1100001............................1100001............... + .......110000011..........................110000011.............. + .......100000001..........................100000001.............. + .......100000001..........................100000001....8......... + ......1100000001111111111111111111111111111000000011.88888....... + .......10000000000000000000000000000000000000000001..88888....... + .9.....10000000000000000000000000000000000000000001.8888888...... + .......11000001111111111111111111111111111110000011..88888....... + ........1111111............................1111111...88888....... + ...........1.................................81........8......... + ...........................................88888................. + .............................9.............88888.............9... + ..........................................8888888................ + ...........................................88888................. + ...........................................88888................. + .............................................8................... + .................9........9.......9.............................. + +-------- + + lake { + flags CIRCLE|ORIGIN + size_x 6~9 + id_1 8 + } + tree { + flags RECT|ORIGIN + size_x 1 + id_1 9 + replace { + id_1 9 + } + } + tower_1 { + flags CIRCLE|ORIGIN + size_x 20% + id_1 0 + relations { + tower_walls { + flags OVERLAP + } + } + } + tower_2 { + flags CIRCLE|ORIGIN + size_x 20% + id_1 0 + relations { + tower_walls { + flags OVERLAP + } + } + } + tower_3 { + flags CIRCLE|ORIGIN + size_x 20% + id_1 0 + relations { + tower_walls { + flags OVERLAP + } + } + } + tower_4 { + flags CIRCLE|ORIGIN + size_x 20% + id_1 0 + relations { + tower_walls { + flags OVERLAP + } + } + } + tower_5 { + flags CIRCLE|ORIGIN + size_x 20% + id_1 0 + relations { + tower_walls { + flags OVERLAP + } + } + } + tower_walls { + flags CIRCLE|BORDER + size_x 100% + size_y 100% + id_1 1 + } + long_walls { + size_x 10% + size_y 10% + flags RECT|ORIGIN + id_1 0 + replace { + id_1 1 + } + relations { + long_walls_walls { + } + } + } + long_walls_walls { + flags RECT|BORDER|ORIGIN|OVERLAP + size_x 100% + size_y 100% + id_1 1 + replace { + id_1 0 + } + } + castle { + size_x 90% + size_y 90% + relations { + tower_1 { + x 20% + y 20% + } + tower_2 { + x 20% + y 80% + } + tower_3 { + x 80% + y 20% + } + tower_4 { + x 80% + y 80% + } + tower_5 { + flags ORIGIN + x 50% + y 50% + } + } + paths { + long_walls { + flags DUMB|WALK|FORCE + from tower_1 + from_flags ORIGIN + to tower_2 + to_flags ORIGIN + to_x -25% + } + long_walls { + flags DUMB|WALK|FORCE + from_flags ORIGIN + from_x 0% + from_y 0% + to_flags ORIGIN + to_x 0% + to_y 0% + from tower_1 + to tower_3 + } + long_walls { + flags DUMB|WALK|FORCE + from_flags ORIGIN + from_x 0% + from_y 0% + to_flags ORIGIN + to_x -25% + to_y 0% + from tower_3 + to tower_4 + } + long_walls { + flags DUMB|WALK|FORCE + from_flags ORIGIN + from_x 0% + from_y 0% + to_flags ORIGIN + to_x 0% + to_y 0% + from tower_4 + to tower_2 + } + } + } + start { + size_x 64~80 + size_y 32~48 + relations { + castle { + } + tree { + count 16~32 + x 0~100% + y 0~100% + } + lake { + count 1~2 + x 70~100% + y 70~100% + } + } + } +.imply(header.ids)