Merge pull request #486 from thecodingmachine/doc_for_collides

Adding documentation for "collides" property
This commit is contained in:
David Négrier 2020-12-14 17:01:39 +01:00 committed by GitHub
commit 7e2e530f9f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 25 additions and 1 deletions

View file

@ -124,6 +124,31 @@
</ul>
<p class="text-center"><img src="docs/tiled_screenshot_1.png" alt="" style="width: 70%"></p>
<h3 id="building-walls" class="pixel-title">Building walls and "collidable" areas</h3>
<p>By default, the characters can traverse any tiles. If you want to prevent your characeter from
going through a tile (like a wall or a desktop), you must make this tile "collidable". You can do
this by settings the <code>collides</code> property on a given tile.</p>
<p>To make a tile "collidable", you should:</p>
<ol>
<li>select the relevant tileset and switch to "edit" mode:<br/>
<img src="docs/collides-1.png" alt="">
</li>
<li>right click on a tile of the tileset to select it:<br/>
<img src="docs/collides-2.png" alt="">
</li>
<li>on the left pane in the custom properties section, right click and select "Add properties":<br/>
<img src="docs/collides-3.png" alt=""><br/>
Please add a <code>collides</code> property. The type of the property must be <strong>bool</strong>.
</li>
<li>finally, check the checkbox for the <code>collides</code> property:<br/>
<img src="docs/collides-4.png" alt="">
</li>
</ol>
<p>Repeat for every tile that should be "collidable".</p>
<h3 id="defining-a-default-entry-point" class="pixel-title">Defining a default entry point</h3>
<p>In order to define a default start position, you MUST create a layer named &quot;start&quot; on your map.
This layer MUST contain at least one tile. The players will start on the tile of this layer.
@ -135,7 +160,6 @@
not visible to the end user because they are hidden below the "bottom" layer that displays the floor
of the map.</p>
<h3 id="defining-exits" class="pixel-title">Defining exits</h3>
<p>In order to place an exit on your scene that leads to another scene:</p>
<ul>

BIN
website/dist/docs/collides-1.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 290 KiB

BIN
website/dist/docs/collides-2.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 144 KiB

BIN
website/dist/docs/collides-3.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 129 KiB

BIN
website/dist/docs/collides-4.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB