From The Mana World
(New page: =Example of rules: Rule_cave_002= The rules which are used in the example can be found here: User:Argul/automapping/data In the future maybe they can be found in out git repository ...)
 
Line 10: Line 10:


==some pictures==
==some pictures==
[[Image:Example_cave.png‎|left|frame|This is what you might want to have. The lower border is in the Over-layer of course, The rest of the walls are in Ground-layer. The walls are unwalkable: The collision Layer must be set properly.]]
[[Image:Example_cave.png|left|frame|This is what you might want to have. The lower border is in the Over-layer of course, The rest of the walls are in Ground-layer. The walls are unwalkable: The collision Layer must be set properly.]]


[[Image:Example_cave_set.png‎|center|frame|This is what you have to draw with automapping feature. All in one Layer, the special "Set" layer. and of course you need the proper rules.]]
[[Image:Example_cave_set.png|center|frame|This is what you have to draw with automapping feature. All in one Layer, the special "Set" layer. and of course you need the proper rules.]]


[[Image:Example_cave_1.png|left|frame|After the very first rules we have the Ground set.]]
[[Image:Example_cave_1.png|left|frame|After the very first rules we have the Ground set.]]
[[Image:Example_cave_2.png|center|frame|After the next rules we have the standard straight walls. You can see that the position, where the lower wall is, is touched again: There was already a Ground tile in Groundlayer, now there is added a wall tile in the Over Layer.]]
[[Image:Example_cave_2.png|center|frame|After the next rules we have the standard straight walls. You can see that the position, where the lower wall is, is touched again: There was already a Ground tile in Groundlayer, now there is added a wall tile in the Over Layer.]]


==explanation of the file, describing the rules==
==explanation of the file, describing the rules==

Revision as of 08:29, 30 July 2011

Example of rules: Rule_cave_002

The rules which are used in the example can be found here:

User:Argul/automapping/data

In the future maybe they can be found in out git repository as well.

These rules are chosen by chance. They can explain most of the stuff very well.

some pictures

This is what you might want to have. The lower border is in the Over-layer of course, The rest of the walls are in Ground-layer. The walls are unwalkable: The collision Layer must be set properly.
This is what you have to draw with automapping feature. All in one Layer, the special "Set" layer. and of course you need the proper rules.
After the very first rules we have the Ground set.
After the next rules we have the standard straight walls. You can see that the position, where the lower wall is, is touched again: There was already a Ground tile in Groundlayer, now there is added a wall tile in the Over Layer.

explanation of the file, describing the rules

In this section we will have a closer look to the Layers of the file Rules_cave_002.tmx:

The RuleRegions is always shown for better orientation.

File:Rule cave 002 ruleregions.png‎
This is the RuleRegions Layer. We can see there are 4 rules defined within this file. (There are four coherent Regions). In the other Layers we can see how the rules are setup.
File:Rule cave 002 ground.png‎
This is the rule_Ground Layer. Here we see, where tiles will be placed within the Ground Layer.
File:Rule cave 002 ruleset.png‎
This is the RuleSet Layer. Any Tiles outside the Regions defined by the RuleRegions Layer will be ignored. This Layer describes which condition must be matched, to apply the specific rule: For the most left rule: There must be a 3 black RuleTiles north of a RuleTile. (Note: the most south Tile is an empty Tile. This Tile can be anything except all used Tiles. So Here is allowed every Tile except the black RuleTiles.)
File:Rule cave 002 over.png‎
This is the rule_Over Layer.Here we see, where tiles will be placed within the Over Layer.
File:Rule cave 002 collision.png‎
This is the rule_Collision Layer.Here we see, where tiles will be placed within the Collision Layer.
This picture shows the map after applying the described rules. Of course more rules are needed, to complete the map. (have a look at the rules given by the link above). In the next rules, corners will be faced.