By default, RPG Maker displays one map when you are in the map scene. However, this map can be manipulated at runtime.
This script allows you to connect maps together, providing a seamless transition from one map to another (because there is no actual transition). You can create a map in separate parts and then connect it all together to produce one large map.
The editor has a limitation of 250000 tiles, or a 500×500 map. Using map connections allows you to overcome this limitation in the game.
Script: download here
To connect maps together, use note-tags in each map to specify which maps should be connected to it:
<connect map: map_id offset_x offset_y>
The map_id is the ID of the map that you want to connect to the current map, and the offset_x and offset_y is the position that the new map will be placed.
x-values shift it horizontally. Positive x-values shift it to the right, negative-x values shift it to the left.
y-values shift it vertically. Positive y-values shift it down, negative y-values shift it up.
Here is an example demonstrating how to connect map 2 to map 1 side-by-side.
This script provides two types of positioning for map connecting. Only one may be used at any time. By default it is “recursive positioning” but you can change this in the configuration.
- Absolute Positioning. This mode specifies all offsets to be in absolute coordinates, where the origin is fixed at the upper-left corner of the current map you are editing.
- Recursive Positioning. This mode specifies all offsets to be relative to the parent map. The origin is located at the upper left corner of each map.For example, if map 2 connects to map 1, and map 1 connects to map 2, then we can have a looping map. A special “recurse limit” argument is provided in order to tell the map when to stop looping. By default, this is 1.
<connect map: map_id offset_x offset_y recurse_limit>
There are several things to keep in mind about connected maps
- They all use the same tileset, so you cannot connect two maps with two different tilesets (you can, but the tileset will automatically change to the current map’s tileset)
- You must begin from the top-left and connect maps to the right or bottom. You cannot connect maps to the left or top.
- Negative offsets are supported, but they will simply truncate your map if you shift it to the left or top.
- Maps with different dimensions will result in empty, impassable black spots. You can decorate it with a parallax image so it isn’t just a black spot, but space doesn’t fill up by itself.
- All event ID’s are automatically adjusted, as are event commands. However, script calls are not updated, so if you are using any script calls that deal with events, you may need to re-consider your design.
- Any other property that relies on separate instances of the map are also gone (parallax maps, for example\
So unfortunately this is a very simple implementation of joining maps together. A better solution will be needed in order to fully combine maps together with separate tilesets, parallaxes, and so on.