-
Notifications
You must be signed in to change notification settings - Fork 39
General properties
Here is the description of the general properties of maps, layers, objects, and tiles to be used in Tiled. All properties in this doc are OPTIONAL.
In order to set the below properties in Tiled editor, click on Map > Map Properties...
, then add your properties in Custom Properties
panel.
-
world_map
[boolean]
: if true, will set this map as a World Map style. It basically activates mode7 and relevant scale factors. -
footprint
[boolean]
: if true, the hero will leave footprints on the floor. -
background_key
[string]
: the battle background key name in the case of a battle on this map. -
expected_party_level
[number]
: the average party level expected to be on this map. Useful in the enemy encounter rate calculation. -
sanctum
[object]
: if this map belongs to a town that has a sanctum, you need to fill this property.-
map_key
[string]
: the map key name that will be used to teleport the hero in case of battle defeat. -
collision_layer
[number]
: the target collision layer that will be set when teleporting the hero in case of battle defeat. -
tile_position
[object]
: the target x and y tile position for the hero to be when teleporting in case of battle defeat.-
x
[number]
: the tile x position destination. -
y
[number]
: the tile y position destination.
-
-
-
retreat_data
[array]
: an array of objects containing the Retreat psynergy data. Your map may have multiple entrance points. Set one object per entrance point, the engine will pick the correct one automatically.-
x
[number]
: the tile x position to retreat. -
y
[number]
: the tile y position to retreat. -
collision_layer
[number]
: the destination collision layer to retreat. -
direction
[string]
: the direction to be set when retreating. It can be"right"
,"up_right"
,"up"
,"up_left"
,"left"
,"down_left"
,"down"
or"down_right"
.
-
-
real_tile_width
[number]
: the map tile width to be considered in the engine. This is useful when the tile size in Tiled is different from the desired one in the engine. -
real_tile_height
[number]
: the map tile height to be considered in the engine. This is useful when the tile size in Tiled is different from the desired one in the engine. -
game_events
[array]
: an array containing Game Event objects info. These events will be fired on map load. See Game Events section to see how to fill this property. -
before_config_game_events
[array]
: an array containing Game Event objects info. These events will be fired on map load, but before layers configuration and NPC/IO creation, so be careful when using it. This property is generally useful when changing storage vars that will affect IO or an NPC. See Game Events section to see how to fill this property. -
before_camera_fade_game_events
[array]
: an array containing Game Event objects info. These events will be fired after map load, but before camera fade. This property is generally useful when you want to pre-position the camera on map start. See Game Events section to see how to fill this property. -
tile_event/[key_name]
[object]
: an object containing info about a Tile Event.[key_name]
in property name can be replaced by anything. Repeat this property as much as needed. See Tile Events section to see how to fill this property. -
npc/[key_name]
[object]
: an object containing info about a NPC.[key_name]
in property name can be replaced by anything. Repeat this property as much as needed. See NPCs (Map) section to see how to fill this property. -
interactable_object/[key_name]
[object]
: an object containing info about an Interactable Object.[key_name]
in property name can be replaced by anything. Repeat this property as much as needed. See Interactable objects (Map) section to see how to fill this property. -
game_event/[key_name]
[object]
: an object containing info about a single Game Event. The event set here won't be fired automatically, it needs to be explicitly called.[key_name]
in property name can be replaced by anything. Repeat this property as much as needed. See Game Events section to see how to fill this property.
In order to set the below properties in Tiled editor, click on a tile layer in Layers panel, then add your properties in Custom Properties
panel.
-
over
[boolean|number]
: this property will control whether this layer should be over the hero or not. Please find its behavior in the following topics:- If you don't set this property or set it to
false
, this layer will always be below the hero. - If you set
true
, this layer will always be above the hero and also above the layers that haveover
property set as a number type. - If you pass a number, the engine will do the following:
- If the passed number is the same as the hero's current collision layer index or smaller, this layer will be placed below the hero.
- If the passed number is bigger than the hero's current collision layer index, this layer will be placed above the hero.
- If you don't set this property or set it to
-
blend_mode
[string]
: specifies the blend mode of this layer. It can beSCREEN
orNORMAL
. -
opacity
[number]
: controls the opacity of this layer in-game. Values between 0 and 1. Default is 1. -
reveal_layer
[boolean]
: if set to true, this layer will be initially invisible when mounting this map. When casting Reveal psynergy, this layer visibility will be toggled. -
hidden
[boolean|string]
: if set to true, this layer will be initially invisible. You may want to combine this property with teleport tile eventon_event_toggle_layers
property or"layer_visibility"
game event. This property also accepts a string value, in this case, it must be a storage value key, and the value of this boolean storage value will be read on map load. Default is false. If you passed a storage variable to it and changed its value on the fly withset_value
Game Event, please consider enablingcheck_layers_visibility
on it.
In order to set the below properties in Tiled editor, click on a tile in Tilesets panel, then add your properties in Custom Properties
panel.
-
disable_footprint
[boolean]
: if true and footprints are enabled for this map, the hero won't show footprints when walking over the tile that this property is set. -
half_crop
[boolean]
: if true and the current map is a world map type, the hero will have the lower half of his body cropped when walking over the tile that this property is set. -
background_key
[string]
: sets the battle background that will be displayed if a battle starts when the hero is walking over the tile that this property is set. -
allow_sand
[boolean]
: if true, the hero will be allowed to melt into sand over this tile.
In order to set the below properties in Tiled editor, click on a object layer in Layers panel, then add your properties in Custom Properties
panel.
By default, object layers are treated as collision layers, so every object you add to it will become a collision structure. If no property is passed, the object layer must have its name set as a value convertible to a number, this number will represent the collision index of the layer.
-
encounter_zone
[boolean]
: if set to true, this layer will specify some encounter zones of the map. The zones by themselves are rectangular objects created in this layer. -
base_rate
[number]
: this is only valid ifencounter_zone
property is set to true. Specifies the base encounter rate of all zones in this layer. Zone base rates have priority over this one. -
bounding_box
[boolean]
: if set to true, this layer will specify the bounding boxes of this map. This is useful when a single Tiled map file has multiple maps on it. So if you want to lock the camera inside a map on this file, just create a rectangle object for this map delimiting its area. Please notice that all objects that belong to a specific map must be entirely inside the bounding box. -
layer_index
[number]
: explicitly specifies the collision layer index of this layer. Can't be used withjoin_with_layer
property. This is useful when you want to give a custom name for the layer that's not a number. -
join_with_layer
[number]
: specifies which collision layer index you want to join this collision layer with. Can't be used withlayer_index
property. This is useful when you have a lot of collision objects in a collision layer index, then you separate them into different object layers to better organize your map. -
bgm_regions
[boolean]
: if set to true, this layer must contain objects of rectangle type that will delimit regions that if the hero is inside it, some specified BGMs will start playing. Otherwise, if the hero is outside these regions, the BGMs will stop. Please check"bgms_list"
property under "Object properties" section.
In order to set the below properties in Tiled editor, click on an object in the map, then add your properties in Custom Properties
panel.
-
split_polygon
[boolean]
: this property can only be applied to polygon objects. If set to true, it will split this polygon into chunks of the size of a tile. By doing this, the engine knows how to disable or enable collision in a particular tile. This is useful, for example, when you have moving jump events, like the ones over a pillar, so when moving a pillar, the new position where you can jump on will have the collision disabled, the old one will be enabled. -
base_rate
[number]
: this is only valid ifencounter_zone
property is set to true in the layer that this object is in. The object that this property is set represents an encounter zone. It specifies the base encounter rate of this zone. This base rate has priority over the layer base rate. -
parties
[array]
: this is only valid ifencounter_zone
property is set to true in the layer that this object is in. The object that this property is set represents an encounter zone. It specifies the list of enemy parties' key names that can be found in this zone. -
background_key
[string]
: this is only valid ifencounter_zone
property is set to true in the layer that this object is in. The object that this property is set represents an encounter zone. It specifies a custom battle background for this zone. -
affected_by_reveal
[boolean]
: if set to true, this object can have its collision activation toggled by Reveal psynergy. -
collide_on_reveal
[boolean]
: this is only valid ifaffected_by_reveal
property is set to true. If set to true, this object will start with collision disabled and then enabled when casting Reveal psynergy. -
controller_variable
[string]
: set in this property a boolean storage variable key name in order to control the collision of this object. If this variable is true, this object will collide with the hero.affected_by_reveal
property has no effect if the storage variable passed here is set tofalse
. If changing the passed storage variable on the fly withset_value
Game Event, please consider enablingcheck_collision_structures
on it. -
quit_sand
[boolean]
: if true, the hero will exit sand mode and return to normal if he collides with this object. -
bgms_list
[array]
: this is only valid if it's set on an object that belongs to a layer marked as a BGM region (please check"bgm_regions"
under "Object Layer properties" section). This property holds an array of BGM keys registered in the database that will be played when the hero is inside this object. This object must be a rectangle.
- Home
- Introduction for developers
- Tutorials
- Game initialization settings
- Map settings
-
Game Events
- Add item to party event
- Audio play event
- Battle event
- Branch event
- Camera fade event
- Camera follow event
- Camera move event
- Camera shake event
- Casting aura event
- Change collision layer event
- Char animation play event
- Char blend mode event
- Char exp event
- Char fall event
- Char hue event
- Char item manipulation event
- Char level change event
- Char rotation event
- Char shadow visibility event
- Char tween position event
- Chest event
- Colorize char event
- Colorize map event
- Control bgm event
- Create storage var event
- Custom collision body event
- Destroyer event
- Dialog event
- Djinn get event
- Djinn set status event
- Emoticon event
- Event activation event
- Event caller event
- Event holder event
- Event loop event
- Exit Sand mode event
- Face direction event
- Flame char event
- Generic sprite event
- Grant ability event
- IO anim play event
- IO tween position event
- Item checks event
- Jump event
- Layer tween event
- Layer visibility event
- Look event
- Main chars join split event
- Map blend mode event
- Map opacity event
- Move event
- Outline char event
- Particles event
- Party join event
- Permanent status event
- Psynergy stone event
- Set char activation event
- Set char collision event
- Set char visibility event
- Set IO activation event
- Set IO collision event
- Set IO visibility event
- Set NPC collision event
- Set party coins event
- Set value event
- Storage change event
- Summon event
- Teleport event
- Tile event manage event
- Timer event
- Tint char event
- Databases
- Code reference