07-27-2026, 11:54 PM
(This post was last modified: 3 hours ago by DerVVulfman.)
Map Resizer
Version: 1.1
Also available for RPGMaker XP
Version: 1.1
Also available for RPGMaker XP
Introduction
Tired of being stuck with maps that cannot be any larger than 500x500 or whatever limitation was set within your game editor? This script allows one to tell RPGMaker to take a hike!
With this script, you can force a map to a new width and height of your choice. And that map size remains stored in your maps file data so altering the 'properties' doesn't change anything... unless you alter the size in the map's properties window itself.
If you create dimensions for a map that does not exist in your map tree, no error will occur as it will any settings you created that are invalid.
After execution, t he script/program will end. If your currently viewed map is one of those being resized, merely switch to another map and then return and you will see the new map freshly reloaded and resized!
Features
- Break the maximum size limit
- Works with all three Ruby-based editors
- Change the SUFFIX value to rxdata/rvdata/rvdata2
- Three map resize and drawing modes
Screenshots
It would just be two shots of the map editor, before map resizing and after.
Script
Have Fun!
Code:
#==============================================================================
# ** Map_Resizer
#------------------------------------------------------------------------------
# by DerVVulfman
# version 1.1
# 07-29-2026 (mm/dd/yyyy)
# RGSS(1-3) / RPGMaker XP to VXAce
#==============================================================================
#
# INTRODUCTION:
#
# Tired of being stuck with maps that cannot be any larger than 500x500 or
# whatever limitation was set within your game editor? This script allows
# one to tell RPGMaker to take a hike!
#
# With this script, you can force a map to a new width and height of your
# choice. And that map size remains stored in your maps file data so alter-
# ing the 'properties' doesn't change anything... unless you alter the size
# in the map's properties window itself.
#
# If you create dimensions for a map that does not exist in your map tree,
# no error will occur as it will any settings you created that are invalid.
#
# After execution, t he script/program will end. You may need to exit the
# editor and restart to see the changes within the map.
#
# Originally, it was meant as an exercise for RPGMaker XP as I am more flu-
# end in that editor. But upon looking, I realized that there was nothing
# within that would prevent it from working with the other two Ruby-based
# editors. Certain general settings are dependent upon game engine specs.
#
#
#------------------------------------------------------------------------------
#
# BASIC SETTINGS:
#
# Here, you will get some insight on the basic settings. The settings should
# be self explanatory. But you never know about some game developers. ^_^
#
# * ACTIVATE
# This feature merely turns the system on or off. Set it to 'true' so it
# can perform its job with the defined settings, or 'false' otherwise.
#
# * SUFFIX
# One of the engine specific settings, its here where the file extension
# in defined. In general, ".rxdata" for RPGMaker XP data files, ".rvdata"
# for RPGMaker VX files, and ".rvdata2" for RPGMaker VXAce data files.
#
# * FIX_FILL
# One of the engine specific settings, it is here that a tile (by its ID)
# is defined when the user of this system is resizing a map with Mode 1.
# While Mode 0 creates a base area with the top-left most tile from the
# original map and Mode 2 applies no tiles, Mode 1 asks for a specific
# tile. For RPGMaker XP users, a value of 384 defines the first non-auto
# tile map (generally grass). And a value of 2048 is used by RPGMaker VX
# users for the water autotile from the RTP. As to VXAce users, that is
# possibly based on the tileset in use.
#
# * MIN_WIDTH
# * MIN_HEIGHT
# Two more of the engine specific settings, these two values are meant to
# define the minimum map dimentions (width and height) used by the engine
# and editor in question. It is present solely as a protective measure.
#
# * SAFETY_WIDTH
# SAFETY_HEIGHT
# SAFETY_DEPTH
# Two more of the engine specific settings, these two values are meant to
# Similar in nature to the prior 'MIN_' values, these settings define the
# absolute maximum dimensions of any map; width, height and depth (or the
# number of layers drawn by the tilemap). Again, this is a protective
# measure. But do note the inclusion of SAFETY_DEPTH, so the script may
# permit the use of scripts that allow additional map layers at a time.
#
#
#------------------------------------------------------------------------------
#
# MODES:
#
# When creating an array that resizes a map, you not only supply the dimen-
# sions of a map (with the layers optional) but also define how the map is
# essentially replaced. This is the drawing mode, or just mode.
#
# There are three drawing modes, and they are described below:
#
# * MODE: 0
# The original mode that the script used. When the new map is created, it
# will be recreated to the dimensions given. However, the entire map will
# be filled with the tiles found in the top-left corner of the original
# map. If the top-left corner of the original map is a roof tile, then
# the new map will be recreated with that roof tile.
#
# Of the three modes, it is the most destructive as it doesn't attempt to
# copy the original map over.
#
# * MODE: 1
# This mode will resize your map to the dimensions given and fill the map
# with a pre-defined tile specified with the FIX_FILL setting. Ergo, if a
# tile defined with the FIX_FILL setting identifies barren rocky terrain,
# then the whole map will first be drawn with that tile.
#
# After the map is initially created, this mode will then copy as much of
# the original map with the space provided, subsequently replacing any of
# the tiles previously drawn.
#
# * MODE: 2
# This mode will resize your map and, if space allows, will copy the con-
# tents of the original map into the new. Unlike mode 0 or mode 1, this
# mode will not fill the map with tiles on its own, leaving areas totally
# devoid and empty.
#
#
#==============================================================================
#
# COMPATIBILITY:
#
# Fairly compatible for all Ruby-based RPGMaker engines. No default classes
# were touched.
#
#
#==============================================================================
#
# TERMS OF USE:
#
# Free for use, even in commercial games. Only due credit is required.
#
#
#==============================================================================
#==============================================================================
# ** Map_Resizer
#------------------------------------------------------------------------------
# The configuration portion
#==============================================================================
module Map_Resizer
#--------------------------------------------------------------------------
MAP_LIST = {} # Do Not Touch
#--------------------------------------------------------------------------
# GENERAL SETTINGS
#--------------------------------------------------------------------------
# Basic safety parameter settings that the end user should still be aware.
#
ACTIVATE = false # Enabled/disabled. Set to true to execute
SUFFIX = ".rvdata" # Engine Specific: File suffix in use
FIX_FILL = 2048 # Engine Specific: Tile ID for Mode 1 fill
MIN_WIDTH = 17 # Engine Specific: Editor minimum width
MIN_HEIGHT = 13 # Engine Specific: Editor minimum height
SAFETY_WIDTH = 2000 # Maximum width of any map despite settings
SAFETY_HEIGHT = 2000 # Maximum height of any map despite settings
SAFETY_DEPTH = 3 # Maximum layer depth of any map
# INDIVIDUAL MAPS BY ID
#--------------------------------------------------------------------------
# Hash array where each map is given a 3 or 4-parameter array defining
# how the map is resized. Depth is optional ans assumed 3-layer standard.
#
# * Mode : Map drawing and fill mode: (0-2)
# * Width : Revised width (in tiles) for the given map
# * Height : Revised height (in tiles) for the given map
# * Depth : (optional) Number of layers in the map (ground, lower, etc)
#
#
# Map ID Mode Width Height Depth
# ==== ====== ====== ====== ======
MAP_LIST[1] = [ 1, 35, 30]
# MAP_LIST[2] = [ 0, 30, 30, 3]
end
#==============================================================================
# ** Map_Resizer
#------------------------------------------------------------------------------
# This module will increase and/or decrease the size of designated maps.
#==============================================================================
module Map_Resizer
#--------------------------------------------------------------------------
# * Start execution of all maps to be updated
#--------------------------------------------------------------------------
def self.start
#
# Exit if disabled (and leaving it in?)
return unless ACTIVATE == true
#
# Acquire a list of all valid maps by ID
info = load_data("Data/MapInfos" + SUFFIX)
map_keys = info.keys
#
#
# Sort through maps in the list
for key in MAP_LIST.keys
#
# Skip if no map with key/id exists
next unless map_keys.include?(key)
#
# Process individual map
process_map(key, dimensions(key) )
#
end
#
# Exit execution
exit
#
end
#--------------------------------------------------------------------------
# * Acquire creation mode and new dimensions for the map
# map_id : Map ID
#--------------------------------------------------------------------------
def self.dimensions(key)
#
# Obtain map mode & dimensions
mode = MAP_LIST[key][0]
width = MAP_LIST[key][1]
height = MAP_LIST[key][2]
depth = 3
depth = MAP_LIST[key][3] if MAP_LIST[key][3] != nil
#
# Acquire safety settings
safety_w = SAFETY_WIDTH
safety_h = SAFETY_HEIGHT
safety_d = SAFETY_DEPTH
#
# Ensure safety settings not below minimum
# Yes, I consider someone may BOTCH safety settings
safety_w = MIN_WIDTH if safety_w < MIN_WIDTH
safety_h = MIN_HEIGHT if safety_h < MIN_HEIGHT
safety_d = 3 if safety_d < 3
#
# Ensure map settings not below minumum
width = MIN_WIDTH if width < MIN_WIDTH
height = MIN_HEIGHT if height < MIN_HEIGHT
depth = 3 if depth < 3
#
# Ensure valid maximums
width = safety_w if width > safety_w
height = safety_h if height > safety_h
depth = safety_d if depth > safety_d
#
return [mode, width, height, depth]
#
end
#--------------------------------------------------------------------------
# * Process recreation of individual map
# map_id : Map ID
# dimensions : recreation dimensions for map
#--------------------------------------------------------------------------
def self.process_map(map_id, dimensions)
#
# Get filename and new dimensions
filename = sprintf("Data/Map%03d" + SUFFIX, map_id)
system_mode = dimensions[0]
new_width = dimensions[1]
new_height = dimensions[2]
new_depth = dimensions[3]
#
# Obtain data from already existing map
map = load_data(filename)
old_height = map.height
old_width = map.width
old_data = map.data
#
# Make storage array for top-left tile data
tiledata = get_tiledata(system_mode, old_data, new_depth)
#
# Create new table for data
new_data = Table.new(new_width, new_height, 3)
#
# Populate new table with tile data
for z2 in 0...new_depth
for y2 in 0...new_height
for x2 in 0...new_width
new_data[x2, y2, z2] = tiledata[z2]
end
end
end
#
# Copy the old map data into the new table is defined
new_data = map_reinsert(system_mode, old_data, new_data)
#
# Replace map data and save
map.data = new_data
map.width = new_width
map.height = new_height
save_data(map, filename)
#
end
#--------------------------------------------------------------------------
# * Get tile data for entire map base
# system_mode : type of map rendering
# old_data : original map data
# new_depth : number of map layers
#--------------------------------------------------------------------------
def self.get_tiledata(system_mode, old_data, new_depth)
#
# Create tiledata array
tiledata = Array.new(new_depth)
#
# Branch on mode
case system_mode
when 1 # Fix Fill (uses an identified tile by ID)
tiledata[0] = FIX_FILL
for z2 in 1...new_depth ; tiledata[z2] = 0 ; end
return tiledata
when 2 # No tile
for z2 in 0...new_depth ; tiledata[z2] = 0 ; end
return tiledata
end
for z2 in 0...new_depth
tiledata[z2] = old_data[0, 0, z2]
end
return tiledata
#
end
#--------------------------------------------------------------------------
# * Reinsert the old map within the new map data
# system_mode : type of map rendering
# old_data : original map data
# new_data : resized/new map data
#--------------------------------------------------------------------------
def self.map_reinsert(system_mode, old_data, new_data)
#
# Exit without original map on mode 0
return new_data if system_mode == 0
#
# Acquire new map dimensions
new_width = new_data.xsize
new_height = new_data.ysize
new_depth = new_data.zsize
#
# Populate new table with old table
for z2 in 0...new_depth
for y2 in 0...new_height
for x2 in 0...new_width
# Acquire original tile in coordinates
test_value = old_data[x2,y2,z2]
# Skip if invalid
next if test_value.nil?
# Replace old map tile in position
new_data[x2,y2,z2] = old_data[x2,y2,z2]
end
end
end
#
return new_data
#
end
end
#----------------------------------------------------------------------------
# Executes the script
#----------------------------------------------------------------------------
Map_Resizer.startInstructions
Place below Scene_Debug and above Main. Make sure the ACTIVATE value is set to true when you DO want it to run. And set the SUFFIX value to the proper file extension of your chosen RPG Maker editor's data files.
Other content should be easily understandable.
FAQ
Heh. I didn't expect I'd make something that works carte blanche for all three when I started half an hour ago. Yep, this was a quick script creation with a hella good payout!
Compatibility
Fairly compatible for all Ruby-based RPGMaker engines. No default classes were touched.
Terms and Conditions
Free for use, even in commercial games. Only due credit is required.
Up is down, left is right and sideways is straight ahead. - Cord "Circle of Iron", 1978 (written by Bruce Lee and James Coburn... really...)
Above are clickable links

![[Image: QrnbKlx.jpg]](https://i.imgur.com/QrnbKlx.jpg)
![[Image: sGz1ErF.png]](https://i.imgur.com/sGz1ErF.png)
![[Image: liM4ikn.png]](https://i.imgur.com/liM4ikn.png)
![[Image: fdzKgZA.png]](https://i.imgur.com/fdzKgZA.png)
![[Image: sj0H81z.png]](https://i.imgur.com/sj0H81z.png)
![[Image: QL7oRau.png]](https://i.imgur.com/QL7oRau.png)
![[Image: uSqjY09.png]](https://i.imgur.com/uSqjY09.png)
![[Image: GAA3qE9.png]](https://i.imgur.com/GAA3qE9.png)
![[Image: 2Hmnx1G.png]](https://i.imgur.com/2Hmnx1G.png)
![[Image: BwtNdKw.png%5B]](https://i.imgur.com/BwtNdKw.png%5B)
One odd thing. The ability to merely switch between maps after execution to see the newly resized maps o longer functions. I am at a loss why it doesn't as it had before.