Groups provide a way of associating multiple entities (tiles, objects, and/or characters) within a map together.
To create a group, select one or more entities while in the Edit mode of the Map Editor, then either press “G” or right-click on one of the selected entities and choose “Add to Group” from the Grouping submenu. Previously created groups can be managed from the Map Properties panel.
Currently there are only a few uses for the grouping functionality, but more will be added as the engine grows. Continue reading below for descriptions of each use.
You can use groups as a way to hide a set of entities in the Map Editor, for example to hide the roof of a house to allow easier access for editing the house's interior. Refer to the “Group” property on the Map Properties page for details around hiding/showing the groups defined for a map.
The Play Group Animation scripting function allows you to trigger a particular animation simultaneously for a group of entities, for example to raise spikes from a room full of trap tiles or to trigger a cheering animation on a crowd of NPCs.
While mostly an experimental feature at this point, groups can also be used as a way to have the game automatically hide tile layers based on the current location of the player character. This is useful in cases where there is a building with multiple floors and you'd like the tiles and objects of upper floors to be hidden when the player is on a lower floor.
To accomplish this, you would add any walkable tiles on the lower floor to a group (as an example, say “floor1”), and then add any tiles and objects that are part of any upper floors to another group, using the special “-hide” suffix. Following our example, this upper floor group should be named “floor1-hide”. Whenever the player character walks onto a tile in the “floor1” group, any entity in the corresponding “floor1-hide” group will be automatically hidden.