How to use the Map16 editor
In Lunar Magic, there is a thing called the Map16 editor. It is a fairly powerful tool and would help someone a lot if they were to create a Super Mario World hack. Here is how to use it:

Starting up the Map16 editor
Click on the "Editors" tab of Lunar Magic, then click on "16 by 16 tile map editor". This will bring up the Map16 tile editor.

Basics(Replacing a used tile)
Here I will describe the basics of the Map16 tile editor. The basics will be taught to you by replacing and altering a used tile. The up and down arrow keys switch between pages of the Map16 editor. First, open Level 105 in Lunar Magic, then open the Map16 editor. Click on a tile in the Map16 editor. This is neccessary for the window to recognize that it is being used. Now click on the downward-pointing arrow key on the keyboard. The page will be changed to the first 16 by 16 page (the one before was page 0). Now click on the happy cloud. Lunar Magic should say "Tile 106 selected for editing" to let you know that that tile is selected. Click on "Flip Y". This will flip the tile on the vertical Y axis, which will force tile 106's graphics to be upside-down. Flip X does the same thing,except horizontally rather than vertically. While the tile is upside-down, click on the bottom-left corner of the tile. The small selected portion should show up in the box next to where it says "Edit 8x8 attributes" at the bottom of the window. Besides the 8x8 attributes box, click "Flip X", then "Flip Y". The tile should flip on the aforementioned axises, forming a weird tile. Now click on "Edit 16x16 attributes". Switch the hexidecimal palette number. The cloud tile should change it's palette. That is how you change the palette of a tile. Now click on "Edit 16x16 attributes" again and put in "60" as Tile One,"61" as Tile 2,"62" as Tile 3,and "63" as Tile 4. Use palette 6. Your tile should come up as a deformed question block. To fix the "deformed" problem and force it to look right, click on the upper-right and lower-right 8x8 tiles and flip them on the X axis. The tile should now have the graphics of a question block. Right-click over the cloud tile, and your question block should be pasted over tile 106. If saved with the F9 key, all cloud tiles will have the graphics of a question block, yet still behave as if they were cloud tiles. Let's say you wanted to force all of the cloud tiles to look like question blocks,yet behave as if they were cement blocks. The tile number for the cement block is 130. In that case, you would edit the 16x16 attributes of the cloud tile (106) to mimic the properties of tile 130. Put 130 in the box at the bottom and repaste the newly-made tile over the old tile (with a right click in it's place). To double-check if you have done it right, click on tile 106 and click on "Edit 16x16 attributes". If the tile number at the bottom is 130, you have done it properly. Now press F9, save the frontground and background data (the map16 tiles) back to the ROM, and now all cloud tiles will have the appearance of a question block, but would mimic the actions of tile 130.

Creating a new tile
Using the steps in the "Basics" tutorial, start with a tile which has 4 blue blocks for it's graphics. This tile is defined from the game as an "unused" tile. They are free to use however you see fit.
 
NOTE: page 2 (the first 'blank' page encountered in a fresh SMW ROM) is a 'tileset specific' page of tiles. although it's gameplay properties are always the same, it can have different graphics depending on the tileset. for example you could have a ledge tile which was a rope in one tileset, but a wooden platform in another tileset. if in doubt, avoid this page (although it really is simple). be sure when overwriting tiles in this area that you are not overwriting a 'blank' tile which is not blank on another tileset!!!


Accessing your tiles
From the "Editors" menu,click on the Add Objects Window. Go to "Direct Map16 access" and select your tile from there.

Background
There is not much to background editing. The main difference is that you cannot force a background tile to mimic a foreground tile. Other than this difference,map16 background editing is basically the same as normal map16 editing. Pages 12-1F can be used to store custom-made background tiles. Background tiles are made the same way as custom blocks, except they go in the background. In the Background Tile Map Editor, use the Page Up and Page Down keys to switch between the 16x16 pages used for the background. For example, you could put a question block on one BG page (following the basics tutorial) and have that block appear multiple times or even fill the entire screen by using the Background Tile Map Editor. The Background Tile Map Editor is found in the "Editors" menu.

Advanced
Notes:

1. Some tiles, when mimicked, do not have the same actions as they normally would and will only perform one action, among other effects. An example is the green switch palace block. It will always appear, no matter if the switch for the palace is activated or not. Another example is tile 1EB. You will sink through this tile as if it was never there. This applies to many slopes also.

2. Palette 6 contains an animated color. This will cause certain tiles to flash if they contain this color.

3. Background tiles are stored in 16x16 pages 10 and 11 in hexidecimal.

4. The tiles on pages 10 and up cannot be forced to mimic other tiles,because they are background tile pages. Pages 9 and under are foreground tile pages.

5. You can change the palettes of 8x8 tiles in the "Edit 8x8 attributes" menu.

6. You can alter the palette of a custom block to exactly what you need in the "Change Palettes and Edit Colors" tab in the Level menu.

7. Make sure you have saved at least one level with the most recent Lunar Magic version before using the map16 editor since Lunar Magic inserts some special ASM hacks when you save a level.

8. Layer Priority decides if Mario and other sprites pass under or over a tile.

Creating your own custom block

To create your own tile, you have to have some knowledge of the 8x8 tile editor. Since this is not a document about 8x8 tile editing, I will not describe how to use that editor here. First,overwrite any tile(s) that you will not use in your hack. These tiles have to be from 0 to 1FF,because all of the other tiles are either animated, which the Map16 editor does not support, or are sprites, which are completely different from tiles. Once you have drawn your graphics in and saved, go to the Map16 editor and find a blank tile. You have to be careful which tile you choose, because tilesets switch between stages,and a blank tile on one tileset may overwrite an existing tile on another tileset and screw your hack. Pages 2-F are free pages on a clean,unmodified SMW ROM. Choose a blank tile from one of these pages. Look up the number of your tile(s) in the 8x8 tile editor. Say they are wooden SMB3 block tiles, they overwrite 8x8 blocks 1F0-1F3, in order top-left, top-right, bottom-left, bottom-right. You would choose a blank tile in the 16x16 tile map editor, click on "Edit 16x16 attributes", tile one would be 1F0, tile two would be 1F1, tile three would be 1F2, tile four would be 1F3, and the palette would be changed by either the palette changer in the 16x16 tile editor or what was mentioned in Note 6.

Tutorial copyright Da Metroid,2002, edited by sendy.

