Update 2014-11-04T10:29:49.376Z

This commit is contained in:
Riley Shaw 2014-11-04 05:29:49 -05:00
parent 815a54763a
commit 108661688c
2 changed files with 17 additions and 2 deletions

View File

@ -81,6 +81,7 @@ ex1.grid = ex1.makeGridWithDistribution([['secondCreature', 10], ['simplePlant',
<h3 id="gol">Conway's Game of Life <a class="question" target="_blank" href="http://en.wikipedia.org/wiki/Conway's_Game_of_Life">?</a></h3>
<pre><code class="language-javascript">var gameOfLife = new terra.Terrarium(25, 25, {
trails: 0.9,
periodic: true,
background: [22, 22, 22]
});
@ -383,6 +384,20 @@ var t = new terra.Terrarium(4, 4, {
<li>Default: canvas is appended to <code class="language-markup">document.body</code></li>
</ul>
</li>
<li>
<h4><span class="token keyword">boolean</span> periodic</h4>
<p>Determines if boundaries wrap around; a creature at the top of a periodic map would see the bottom cells as though they were adjacent.</p>
<ul>
<li>Default: false</li>
</ul>
</li>
<li>
<h4><span class="token keyword">string</span> neighborhood</h4>
<p>Defines neighborhood type as either <a href="http://en.wikipedia.org/wiki/Moore_neighborhood"><code class="language-javascript">moore</code></a> or <a href="http://en.wikipedia.org/wiki/Von_Neumann_neighborhood"><code class="language-javascript">vonNeumann</code></a>.</p>
<ul>
<li>Default: moore</li>
</ul>
</li>
<li>
<h4><span class="token keyword">float</span> trails</h4>
<p>Allows for "trails", which visualize system history. A value of 1 shows all past state; trails fade faster as we approach 0.</p>

4
terra.demo.min.js vendored

File diff suppressed because one or more lines are too long