So, you're think ready to hack. Okeydoke. Do you know anything about hexadecimal math and numbering? No? Well then, first thing we need to do is get you acquainted with the innards of a hex editor, and introduce you to the raw, machine-level code of the game itself. Are you frightened? You shouldn't be. I'm not going to force you to do anything unpleasant. However, this isn't the most glamorous hacking you can do. For those of you who were expecting to start off with something different, sorry. Knowing this stuff is a neccessary evil - a little practice and learning now can go a long way later in your hacking career. Hate me for it now, thank me for it later. The Hex Editor First things first - you need a hex editor. This is a program that reads, displays, and allows editing of the raw code of any computer file - in our case, the EarthBound ROM. There are an endless stream of hex editors out there, each boasting their own strengths and weaknesses. For purposes of this tutorial, we will be working with Hexposure. It's an all-around solid editor with plenty of features. Only problem is it's a DOS program, meaning XP and Win2K users aren't going to have a lot of luck running it. In lieu of that, there are a couple of options for you - see the downloads panel for more information. One Small Step So here you are... you've downloaded the hex editor, and opened up your ROM. Look around for a moment. What you see is the string of data that composes your game. It looks, to the untrained eye, like a huge blob of random gibberish - letters and numbers with no meaning. Hopefully, I will be able to change that for you. Examine in closer detail one of the small, two digit letter-number combinations. This cluster is known as a "byte," and is one of the basic building blocks of computer data. These bytes, each containing its own specific value, build commands - instructions for how the game runs, displays graphics, plays music. The data in the game - text, sprites, enemy statistics, item names - is also composed of bytes. We look at a byte in terms of base-16 (hexadecimal) math. Hex is a numbering system, much like the base-10 (decimal) system we're all familiar with. In base-10, one counts through 10 numbers (0, 1, 2, 3, 4, 5, 6, 7, 8, and 9) before increasing to the next place (tens, hundreds, thousands, and so forth). As you may have guessed, hex has 16 numbers: 0x0, 0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8, 0x9, 0xA, 0xB, 0xC, 0xD, 0xE, and 0xF. We prefix numbers in hex with "0x" in order to avoid confusion with decimal numbers. A byte can be any number between 0x0, (0) and 0xFF (255). Fear not - you won't have to know how to convert between the two systems. If you ever have need to, just use the functions of your Windows calculator (in scientific mode). Enough math for now. Let's take the first step into the ROM, and actually get to doing something productive! Basic Hex Editing Imagine, for a moment, a large book that lays before you. On each page is two things: a single byte out of the ROM, and a page number. This is much the way in which we navigate the data - each byte has an address - or, page number, as it were - denoting how many bytes from the beginning of the ROM it is. We use these numbers to identify locations of data in the game, all the way from the first byte at address 0x0 to the last byte at address 0x3001FF. Think of these addresses as road signs, indicating your present location, and how far you are from a particular block of data. We keep a listing of identified data blocks and their addresses on the PK Hack Website. Take a look and see where some things are... don't worry, there won't be a quiz. ^_^ --------------------------------------------------------------- •Hexposure is the editor of choice for many hackers who can run DOS programs. Enjoy. •Hex Workshop is an editor with an impressive list of features and capabilities. Too bad that it costs money. You can try it out for a month or so, if you wish. •This program, aptly - if not creatively - named Hex Editor, looks to be a decent editor. I haven't tried it, myself. Somebody try it out and tell me if it works.