Table of Contents

Raw format commands

In RPG Maker 2000/2003, commands internally possess three elements to be able to tell what the command should do:

For instance, a Change Vehicle Graphic command that would change the sprite of the ship to the fourth sprite of the Vehicles CharSet would be written like this: 10650, "Vehicles", 1, 3, where 10650 corresponds to the command code, Vehicles to the string parameter, and 1 and 3 to the numeric parameters.

The string and numeric parameters may not be used by all commands or may be optional depending on how which command parameters are used.

It can sometimes be needed to write a command in raw format if it is not possible to directly write it through RPG Maker 2000 and RPG Maker 2003. For instance, commands added or modified by the Maniac Patch or EasyRPG are not directly accessible through the default editors, and you may need to write them in raw formats if you do not have the appropriate tools to write them in an accessible way.

This page lists different methods that can be used to write and edit commands in raw format.

EasyRPG Editor

ℹ️ As the EasyRPG Editor remains early in development, its interface could change in the future.

In the EasyRPG Editor, when consulting the code of an event, it is possible to right click and select Add raw… to create a new command using the raw format, or Edit raw… can also be selected if the right click was done on an existing command.

After doing so, a window to write or edit the command in raw format should open, which should contain the following fields:

Maniac Patch editor with TPC

If the Maniac Patch editor alongside its tool TPC have been installed, it is possible to use TPC to write raw commands.

In the Maniac Patch editor, when consulting the code of of an event, it is possible to press F2 on an existing command to edit it, or F3 can be pressed to write a new command, in both cases by opening the TPC program.

Once opened, the TPC program will allow you to write a command by typing text. From there, it is possible to write @raw followed by the command code, the string argument between quotation marks (the content between quotation marks left empty if not used by the command), followed by any numeric arguments, all separated by a comma.

For instance, to write the Change Vehicle Graphic command from earlier, it can be written as:

@raw 10650, "Vehicles", 1, 3

When editing the code of an existing command, the Maniac Patch editor will only use raw format if the command does not has an official TPC syntax. While this does not pose a big issue if the TPC syntax of the command already supports all of its parameters, it may not always be the case, in which case using the common TPC syntax will just remove the additional parameters of the command.

edb or emu file editing with lcf2xml

It is possible to use the lcf2xml tool to convert lmu and ldb files to the human readable formats emu and edb, which are formatted in the same way than xml.

lcf2xml acts as drag-and-drop program which will convert any lmu or ldb file dragged onto it into the emu or edb format and back, allowing users to edit map files and database files easily.

When looking at the text of a emu or edb file, you can find command blocks that are organised this way:

<code>10650</code>
<indent>0</indent>
<string>Vehicles</string>
<parameters>1 3</parameters>

With the <code> field corresponding to the command code, <string> corresponding to the string parameter and <parameters> corresponding to the numeric arguments, with each argument separated by a space. The <indent> parameter dictates on which loop or conditional branch level your command should be placed: if you are editing a command or writing a new command, it is best to reuse or copy the indent level set by the nearest commands.

If you are uncertain where the code you want to write or edit is located in the file, you can always place a comment nearby the code you want to adjust using the normal editor, and then after file conversion, doing CTRL + F to find back the code you want to edit.