Introduction
This script allows you to quickly tile maps together to create continuous regions without using any transfer events. Allow your party to roam free throughout the land. This script can handle just about any combination of maps you throw at it!
Features
Seamlessly tiles multiple maps together to create a world map, dungeon, cave, etc.
You will no longer need any transfer events between linked maps
Maps in a region can be any shape and size so long as they fit together
Automatically loads each maps dimensions from file for easier setup
Only transfers the player between maps when they try to walk off the edge of the map
Will not transfer the player to a new map if the path or destination is impassable
You can have player walk off the edge of the current map before transferring to the new map
You have the option of looping the region on all sides
Dynamically, enable and disable maps as your adventure progresses
Disable access to maps from certain directions
Screenshots
Picture a screen fading from one map to another...
Instructions Installation
Paste the Object Table, Maplinks Region and Maplinks scripts into your project above main.
If you are not using the SDK I recommend that you install the SDK Interpreter Script Fix so that event command script codes will work properly.
Setup
To setup my maplinks script you need to edit its setup method to reflect your project.
For reference here is the demo's setup as well as a breakdown of how to configure yours.
First of all, you must create an Object Table to hold the maps of your region.
The table's x and y sizes should equal the maximum number of maps set along each axis of the table.
If your region has more than one level or floor, you need to create a z axis as well.
The zsize of the three dimensional table should equal the number of floors in the region, dungeon etc.
Code:
maps = Object_Table.new(xsize, ysize)
or
maps = Object_Table.new(xsize, ysize, zsize)
Now you setup each map in your region by adding its id to its proper coordinates to the table.
Code:
maps[x,y], maps[x,y], maps[x,y], maps[x,y] = id, id, id, id
maps[x,y], maps[x,y], maps[x,y], maps[x,y] = id, id, id, id
maps[x,y], maps[x,y], maps[x,y], maps[x,y] = id, id, id, id
maps[x,y], maps[x,y], maps[x,y], maps[x,y] = id, id, id, id
Finally, you have to use the maps table to create your region.
Code:
Region.new('Name', maps, disabled)
This reads the dimensions of each map in your region and joins them into a seamless region.
Compatibility
SDK compliant
Does not require the SDK
Credits and Thanks
Wachunga - Creator of the Original Maplinks Script
G-man - Requested Leave Map Option
Regimos - Major Bug Report
Cheatking - Bug Report
Busbuzz - Bug Report
Author's Notes
I've spent quite some time on this script and I'm still working on improving it. Feel free to post any questions, suggestions or feedback you have. If you find any errors please post your edited setup method and a screenshot of the error dialogue box.
Features Wish List
Up, Down, Jump and Fall
Move up and down between different planes of a region with a simple script call
Jump or fall down onto the floor below; falling causes damage to your party
Regional Maps
Maps drawn automatically by the script
Individual maps appear after you visit them
Can be used in combination with Steph's Map Screenshot Maker to create regional maps from the individual maps within them
Leave Region Option
Leave the region with or without a confirmation message
Version Info
2.0.1 - September 3, 2008 Enhancements to the underlying Object Table and Maplinks Region classes; both have been updated to version 1.1.0
Minor change to the Maplinks Script itself
2.0.0 - August 14, 2008
Major Rewrite
Loads each maps dimensions from file for easier setup
Faster algorithm for transferring between maps
Version Log
1.2.1 - October 25, 2007
Fixed map id 0 bug
Split Difference and Shift methods by x and y axis for faster processing
1.2.0 - October 23, 2007
Option to have looped regions where each edge of the region is connected to the opposite side
Option to have certain maps in a region partially disabled; with access on certain sides only
Completely rebuilt Object_Table class
Removed RGSS.Table
1.1.1 - October 3, 2007
Fixes save/load error in RGSS.Table and Object_Table
1.1.0 - September 22, 2007
Added option to have the player leave the map before transferring
Fixed and enhanced RGSS.Table and Object_Table
Replaced @disabled Object_Table with Array
1.0.1 - August 22, 2007
Changes @disabled table handling for multi-grid maps
Object_Table is now initialized with nil
1.0.0 - August 21, 2007
Original Release
Terms and Conditions
This script is free for personal, public and commercial use.
If you want to use it in your game all I ask is that you credit me as its creator.