Maps have now a default destination entity

Here is a small improvement that will ease the life of quest creators in Solarus 1.1, the future version of the engine.

You will be able to set a destination entity as the default one of the map. It means that whenever a teletransporter (or some Lua code) sends the hero to a map without specifying a destination entity, the hero will arrive on the default destination. If no destination was explicitly set as the default one, then the first one of the map is the default one.

Many maps are very small in a game (like a house in a village) and contain only one destination. In these cases, you no longer have to give a name to the destination and to link a teletransporter to this destination name. In the map of the village, you can make a teletransporter that goes to that map and leave its destination parameter unspecified.

When you create a new savegame, the starting map and the starting destination on that map also become optional in Solarus 1.1. If you don’t call game:set_starting_location(), the game starts on the first map declared in the resource list and with the default destination entity of that map.

This change is not the most important new feature of Solarus 1.1, but it will reduce the risk of errors and improve flexibility!

Posted in News.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>