# ResourceMarin's Map Exporter v1.0

#### Marin

##### Owner
Owner
Marin submitted a new resource:

Marin's Map Exporter - Export all your maps with just a few button presses. Export with or without events.

Since I heard Klein's Map Exporter was broken here and there (and have never successfully used it myself), I decided to write my own version.
You can export any and every map, and you can choose if you want the events on that map to be included in the PNG or not. You also have this option for the player, but it won't show up no matter what if the player isn't on that map.

I may include an option to export with map connections as well later on, but I'm not entirely sure how to go about...

#### Nebby

##### Rookie
Member
Glad to have helped with this! :D

#### aiyinsi

##### A wild Minun appeared!
Member
I tried using it in V17.2 (I didn't alter any scripts ... I just added 2 tilesets and a few maps) and got the following error:
Code:
---------------------------
Error
---------------------------
Script 'BitmapCache' line 394: RuntimeError occurred.

Failed to load the bitmap located at: Graphics/Tilesets/emerald outside

from 'BitmapCache' line 394 in load_bitmap'
from 'marins map exporter' line 100 in initialize'
from 'marins map exporter' line 23 in new'
from 'marins map exporter' line 23 in pbExportMap'
from 'marins map exporter' line 47 in pbExportAMap'
from 'marins map exporter' line 41 in loop'
from 'marins map exporter' line 65 in pbExportAMap'
from 'marins map exporter' line 85 in pbDebugMenuActions'
from 'Debug_Menu' line 744 in pbDebugMenu'
from 'Debug_Menu' line 710 in loop'
from 'Debug_Menu' line 746 in pbDebugMenu'
from 'Scene_Map' line 135 in call_debug'
---------------------------
OK
---------------------------

Code:
---------------------------
Error
---------------------------
Script 'Interpreter' line 276: RuntimeError occurred.

Script error within event 1 (coords 24,5), map 42 (lake park):

Exception: RuntimeError

Message: BitmapCache:394:in load_bitmap'Failed to load the bitmap located at: Graphics/Tilesets/emerald outside

***Full script:

pbExportMap

Interpreter:243:in pbExecuteScript'

map exporter:100:in initialize'

map exporter:23:in new'

map exporter:23:in pbExportMap'

(eval):1:in pbExecuteScript'

Interpreter:1606:in eval'

Interpreter:243:in pbExecuteScript'

Interpreter:1606:in command_355'

Interpreter:494:in execute_command'

Interpreter:193:in update'

---------------------------
OK
---------------------------

Last edited:

#### Marin

##### Owner
Owner
According to your map data, the tileset is supposed to beGraphics/Tilesets/emerald outside, but it can’t find it. I can’t help you there, try saving again from RMXP or the Editor.

#### aiyinsi

##### A wild Minun appeared!
Member
Ah I found the issue. Thanks. The script takes the name of the tileset as name pic of the tileset. So I changed the tileset name to the pic name and it works ... thanks

#### Conmh

##### college is time consuming
Member
Hi,
I ran the exporter (most recent version) from the debug menu and got this error. It's similar to the one aiyinsi got.
---------------------------
Error
---------------------------
Script '[BitmapCache]' line 392: RuntimeError occurred.

Failed to load the bitmap located at: Graphics/Tilesets/Outside waterfall

from 'BitmapCache' line 392 in load_bitmap'
from 'Map Exporter' line 108 in initialize'
from 'Map Exporter' line 31 in new'
from 'Map Exporter' line 31 in pbExportMap'
from 'Map Exporter' line 55 in pbExportAMap'
from 'Map Exporter' line 49 in loop'
from 'Map Exporter' line 73 in pbExportAMap'
from 'Map Exporter' line 93 in pbDebugMenuActions'
from 'Debug_Menu' line 821 in loop'
from 'PScreen_PauseMenu' line 254 in pbStartPokemonMenu'
---------------------------
OK
---------------------------
I wouldn't have posted except that I'm using the default "Outside waterfall" tileset for this map. As you might know, the "Outside watefall" tileset uses the same "Outside" graphic as the "Outside" tileset, but has different autotiles and a different entry in the database. This tells me the exporter requires that every tileset in the database have a graphic of the same name.
This is an easy fix. I can just make a copy of the "Outside" graphic named "Outside waterfall".
I thought that it might be an interesting insight, maybe something you'd like to know, and that it might be useful to other people.

#### whichfahim

##### average Pokemon enjoyer
Member
Ah I found the issue. Thanks. The script takes the name of the tileset as name pic of the tileset. So I changed the tileset name to the pic name and it works ... thanks
Hey, I had the same error and my tileset graphic name and tileset name are the same but I'm still getting the same error.
Error:
---------------------------
Error
---------------------------
Script 'BitmapCache' line 394: RuntimeError occurred.

Failed to load the bitmap located at: Graphics/Tilesets/Mars

from 'BitmapCache' line 394 in load_bitmap'
from 'marins map exporter' line 100 in initialize'
from 'marins map exporter' line 23 in new'
from 'marins map exporter' line 23 in pbExportMap'
from 'marins map exporter' line 47 in pbExportAMap'
from 'marins map exporter' line 41 in loop'
from 'marins map exporter' line 65 in pbExportAMap'
from 'marins map exporter' line 85 in pbDebugMenuActions'
from 'Debug_Menu' line 710 in loop'
from 'Scene_Map' line 135 in call_debug'
---------------------------
OK
---------------------------

#### aiyinsi

##### A wild Minun appeared!
Member
Hey, I had the same error and my tileset graphic name and tileset name are the same but I'm still getting the same error.
Error:
---------------------------
Error
---------------------------
Script 'BitmapCache' line 394: RuntimeError occurred.

Failed to load the bitmap located at: Graphics/Tilesets/Mars

from 'BitmapCache' line 394 in load_bitmap'
from 'marins map exporter' line 100 in initialize'
from 'marins map exporter' line 23 in new'
from 'marins map exporter' line 23 in pbExportMap'
from 'marins map exporter' line 47 in pbExportAMap'
from 'marins map exporter' line 41 in loop'
from 'marins map exporter' line 65 in pbExportAMap'
from 'marins map exporter' line 85 in pbDebugMenuActions'
from 'Debug_Menu' line 710 in loop'
from 'Scene_Map' line 135 in call_debug'
---------------------------
OK
---------------------------
are you sure? Capitalisation is also important. And apparently you don't have a Mars.png tileset in your tileset folder.

#### Desbrina

##### Trainer
Member
Just tried using this on V19.1 and getting a few issues

Where tiles are placed on different layers the lower layers are missing. If a tile is placed on layer 2, it doesn't show what's on layer 1, same with layer 3 and below layers

Its overwritten the warp to map debug option

#### Attachments

• exported.png
59 KB · Views: 121
Last edited:

#### Marin

##### Owner
Owner
Just tried using this on V19.1 and getting a few issues

Where tiles are placed on different layers the lower layers are missing. If a tile is placed on layer 2, it doesn't show what's on layer 1, same with layer 3 and below layers

Its overwritten the warp to map debug option
I'll look into it.

#### Marin

##### Owner
Owner
Just tried using this on V19.1 and getting a few issues

Where tiles are placed on different layers the lower layers are missing. If a tile is placed on layer 2, it doesn't show what's on layer 1, same with layer 3 and below layers

Its overwritten the warp to map debug option
You're probably using RMXP's transparency color option, without actually having transparency in your images. That won't work, as it does not take RMXP's transparency color into account.

#### Desbrina

##### Trainer
Member
I just make them transparent in photoshop. Don’t think I’ve ever selected in rmxp

#### Fobby

##### local weirdo
Member
I'm having this problem where this option replaced the warp one

#### Conmh

##### college is time consuming
Member
I can confirm that the export option replaces the warp to map option

Member

## If using 1.5 or earlier, edit the script before use!​

I noticed some users trying to use this plugin, and suddenly, the "Warp to Map" command in the debug menu has disappeared!
Its overwritten the warp to map debug option
I'm having this problem where this option replaced the warp one
I can confirm that the export option replaces the warp to map option
I'm also replying to the messages quoted above, so here's my advice how to restore the warp command:
1. Open the script.rb file in a text processing program (e.g. Notepad, Sublime Text, Notepad++, but NOT Microsoft Word).
2. Search for the line that starts with DebugMenuCommands.register. If you're using e.g. Sublime Text or Notepad++, this is the line number 81.
3. There is the warp value you're looking for. Replace it with something else (except warp, refreshmap, switches, variables, usepc, togglewallpapers, daycare, relicstone or purifychamber`).
4. Don't change any other values in the file (IMPORTANT!).
Was I helpful here? Thank me later.

EDIT: This was posted before 1.6 was released.

Last edited: