• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Pokered for Dummies

PiaCRT

Orange Dev
937
Posts
13
Years
  • THIS GUIDE IS NO LONGER ACCURATE PLEASE REFER TO THE INSTALL.MD FOR POKERED

    Additional Tutorials:
    How to add Gender Select by Mateo

    NOTE: This is a work in progress guide. I am adding onto it as I learn.

    Ever wanted to make your own Gameboy game from scratch? One that you could play on an emulator, but hacking ended up being way too frustrating for you?

    Well now there's pokered, a complete disassembly of Pokemon Red version for the Nintendo Gameboy.

    However, as amazing as pokered is there is not much in the way of guides for using it, besides installation and some obvious things like changing graphics. So that's why I'm writing Pokered for Dummies.

    I'm learning all about this great hacking alternative myself. Once upon a time I looked for an alternative to hacking and I found RPG Maker XP with the Pokemon Essentials engine. However, the engine is only compatible with Windows and it was very difficult to make something besides a third gen styled game.

    pokered is 100% open source and you can do anything within hardware limitations in it. No more decompressing, finding new pointers, repointing, assembly hacking, etc. I literally changed 2 lines of code and replaced an image to get this:

    mint_has_gone_gameboy__by_piacarrot-d7zivbc.png


    And that is just the scum of the barrel for you. Think of the possibilities with this engine. Diagonal movement? Custom battle interfaces? New animations? Follow me? Use your imagination! And we will be covering all that is available to us in this guide.

    Table of Contents
    1.---Is pokered for you?
    2.---Installing pokered
    3.---Finding and Editing text
    3A--Labels and text scripting
    4.---Editing simple Graphics
    5.---Maps
    6.---Wild Battles
    7.---Trainer Battles
    8.---Events


    Chapter 1. Is pokered for you?

    pokered is a disassembly of Pokemon Red Version by Gamefreak for the Nintendo Gameboy. It's a rather dated game, nearly 20 years old. With that said, the hardware of the Gameboy is very limited compared to, say, a Gameboy Advance or a Nintendo DS. Heck, the game is barely over a Megabyte in size when compiled, while Gameboy Advance ROMs are 16 to 32MB.

    With this said, pokered is still very versatile for both newbies and rom hacking veterans. The engine still features Z80 assembly rather heavily but is now labelled and fixed up in places that were previously impossible to deal with, such as Gen 1 sprite editing. Many strings of text are centralized and can be edited in a Text editor like Notepad++. Sprites are now compiled as .png files, easy to edit with no hassle involved.

    Now, another problem is the palette limitations. While you can add color to the game, it is not supported by the Gameboy natively. If you want to check out pokered with color, see Danny-E 33's pokered with generation 2 elements here: https://github.com/dannye/pokered-gen-II

    This guide does not go over Danny-E 33's version so do not ask me what to do if you come across a problem with it.

    Anyway, Pokemon Red uses monochrome colors, as in black, white and grey. You can reference the image in the intro for an example.

    So really your limitations here are colors and size. Even with color the Gameboy can only do so much. Tilesets can't be extended although you can make new ones. And remember the gameboy runs off the Z80 Assembly language, which if I'm not mistaken TI calculators still use this language. If you want to add new features you'll need to learn how to use this language.

    That concludes this short chapter in the guide. Next we'll get to installing pokered.

    Chapter 2. Installing pokered

    This chapter heavily references the Install.md on IImarckus' github, which can be found here: https://github.com/iimarckus/pokered/blob/master/INSTALL.md
    Please use his guide if using Mac OS X or Linux. This guide goes purely on Windows.

    First off you'll need to install cygwin 32-bit, which can be found here: https://cygwin.com/install.html

    When installing you'll need to select what dependencies you'll need, and you need atleast the following:
    • make
    • git
    • gettext
    • python
    • python-setuptools

    You will then need to install Rednex Gameboy Development System, which can be found here:
    http://iimarck.us/etc/rgbds.zip

    Open the zip, and then open the folder in the zip. Now, take all the .exe files and place them in the following location on your PC.

    Code:
    C:\cygwin\usr\local\bin

    All the .exe files should be in the bin folders. Do not make any additional folders or you will need to mess with your cygwin PATH.

    Now open the cygwin terminal which should be in your Programs. Type in each of these lines:
    Code:
    git clone git://github.com/iimarckus/pokered.git
    cd pokered
    git submodule init
    git submodule update
    easy_install git://github.com/drj11/pypng.git@master#egg=pypng

    After this, you should test it to make sure you've done everything right.

    Type in the following:
    Code:
    make red

    Bonus: make will create both red and blue roms, make blue will make a blue rom, and make red will simply make a red rom.

    bmA7OoA.png


    Give it a moment, and it should compile the rom in the pokered folder in cygwin. If it spits out an error you will need to fix your PATH. The following code will fix your PATH. Make sure you are in cygwin terminal.

    Code:
    export "PATH=$PATH:/cygdrive/C/cygwin/usr/local/bin/

    Now for this to work make sure the .exe files from rgbds are in the bin folder, not the rgbds folder from the zip!

    After that your environment in Cygwin should be ready to go. Now we can start having some fun.

    Chapter 3. Finding and editing text

    I'm sure the first thing you guys want to do is edit graphics or text, so these next two chapters will be covering those.

    If you're looking for a specific string of text that you want to change go to the github repository, at the top of the page is a search bar. Search for a couple words from the text you want to change and it should give you a match. Now just find the same file in your cygwin pokered folder and edit it as you please. I will go into editing text completely and making new text momentarily.

    3A. Labels and text scripting

    UUTFgla.png


    If you crack open oakspeech.asm in the text folder you'll see something like this:
    Code:
    _OakSpeechText1::
    	text "Hiya, there!"
    	line "Welcome to the"
    	cont "world of #MON!"
    
    	para "My name is PIA!"
    	line "I am a humble"
    	cont "schoolteacher."
    	prompt

    Of course this is just my edited version of Oak's speech but it's to show you how easy it is to change. If you have a line already you simply label cont and it will make another line. prompt is used before a sequence and ends the conversation, in this case it transitions from Oak to Nidorino. para is used to start a new paragraph. Don't worry about offsets, the compiler seems to do it for you.

    text initiates the conversation, acts as the first para
    line is the line after the first in the para
    cont is every line afterwards
    para begins a paragraph
    prompt ends a conversation
    done ends the script

    When we get to events I will be covering this so much more in depth, this is just a quick reference for editing conversations like Oak's!


    Chapter 4. Editing simple graphics

    Editing graphics is a simple process, with all images in pokered being in .png format, you can edit them in a program as simple as paint. I recommend Paint XP personally, as Paint 7 or 8 aren't as useful for these kinds of images.

    Not much to say about editing them, you can't change the image size unless the corresponding code is edited to support it. This can be a tedious process.

    Here is an example from me simply editing red and blue's sprite file in the gfx/sprites folder:
    URrWVRT.png


    The process took a couple minutes since I had to recolor the originals to monochrome. Which brings up an important reminder.

    DO NOT USE ANY COLORS BESIDES THE 2 SHADES OF GREY, THE ONE BLACK AND THE WHITE BACKGROUND!!!

    If you do, it will NOT compile as it should.

    Chapter 5. Maps

    EDIT: USE RANGI'S POLISHED MAP, IT NOW SUPPORTS POKERED

    Unfortunately until the map editor is fixed for windows I can not add on to this section. Apparently you can map in a rom and then dump the map files to import into the disassembly, although this sounds complicated on its own.

    EDIT: For now, map in a normal Red ROM using Pokemap or Classicmap, open the pokered map .blk for the map you want to edit in a hex editor. Open the modified Red rom in a hex editor, find the offset of the map you edited, and copy the hex from the rom to the .blk.

    Map offsets stolen from Koolboyman's Red Map...
    Spoiler:

    Chapter 6. Wild Battles

    Wild Pokemon are really simple to edit. In your data folder there will be another folder titled "wildPokemon," this contains all wild pokemon data. Study the various .asm files to see how they are done. For our example we'll be looking at the waterpokemon.asm file:

    Code:
    WaterMons:
    	db $00
    
    	db $05
    	db 5,TENTACOOL
    	db 10,TENTACOOL
    	db 15,TENTACOOL
    	db 5,TENTACOOL
    	db 10,TENTACOOL
    	db 15,TENTACOOL
    	db 20,TENTACOOL
    	db 30,TENTACOOL
    	db 35,TENTACOOL
    	db 40,TENTACOOL

    As you can see it's all Tentacool, at different levels. Really no different from editing wild pokemon in Advance Map or something. You may see some files with "IF Yellow" statements in them, generally just look for the ones under Red version, and if they don't exist edit what is available to you.

    Chapter 7. Trainer Battles

    This section is a bit messy, since trainers don't have names minus BLUE, PROF. OAK, the gym leaders and elite four members. From what I can tell all data pertaining to trainer battles is in trainer_parties.asm, located in the data folder. As to who is who you'll have to know the game a bit or have a guide ready.

    Code:
    YoungsterData: ; 39d99 (e:5d99)
    	db 11,RATTATA,EKANS,0
    	db 14,SPEAROW,0
    	db 10,RATTATA,RATTATA,ZUBAT,0
    	db 14,RATTATA,EKANS,ZUBAT,0
    	db 15,RATTATA,SPEAROW,0
    	db 17,SLOWPOKE,0
    	db 14,EKANS,SANDSHREW,0
    	db 21,NIDORAN_M,0
    	db 21,EKANS,0
    	db 19,SANDSHREW,ZUBAT,0
    	db 17,RATTATA,RATTATA,RATICATE,0
    	db 18,NIDORAN_M,NIDORINO,0
    	db 17,SPEAROW,RATTATA,RATTATA,SPEAROW,0
    if _YELLOW
    	db 24,SANDSHREW,0
    endc

    It seems for normal trainers all their Pokemon are the same level, which tbh doesn't sound right, while Lance for example has individual levels:

    Code:
    LanceData: ; 3a522 (e:6522)
    	db $FF,58,GYARADOS,56,DRAGONAIR,56,DRAGONAIR,60,AERODACTYL,62,DRAGONITE,0

    When I get into events I'll try to explain how to designate specific trainers for a battle.

    Chapter 8. Events
    Chapter x. Credits

    Thanks to everyone who contributed to pokered for the awesome engine.
    Thank you Mateo, IImarckus, Kanzure for helping with information for this guide.
    Gamefreak for the awesome game.
    Pokemon Mint Fantasy/Poketto/Island Walker for custom graphics.

    Link to the Skeetendo IRC if you'd like to ask the people who made pokered a question or to thank them: irc://nucleus.kafuka.org/#skeetendo
     
    Last edited:

    Phasesaber

    Software Engineer turned Pokemon Hacker
    20
    Posts
    9
    Years
    • Seen Apr 25, 2024
    Looks like an interesting way to make a game, too bad there isn't one for GBA.
     
    3,830
    Posts
    14
    Years
    • Age 27
    • OH
    • Seen Feb 26, 2024
    Wow! Thank you so much for posting this.
    I've been wanting to give this a spin, but there wasn't an easy way for me to get started.
    Now I can! :)
     

    IceGod64

    In the Lost & Found bin!
    624
    Posts
    15
    Years
  • I was attempting to follow your guide, but I think I've run into a discrepancy.

    In step 2, can you explain going through the cygwin installer in a little more detail? There's this big section about choosing what packages to install, and it says nothing about choosing dependencies.
     

    Danny-E 33

    The Loneliest Cubone
    259
    Posts
    12
    Years
    • Seen today
    Now, another problem is the palette limitations. While you can add color to the game, it is not supported by the Gameboy natively.
    Of course it is!

    Anyway, Pokemon Red uses monochrome colors, as in black, white and grey. You can reference the image in the intro for an example.
    If your emulator is giving you black and white (like your screenshot) then you need to fix your settings!
    Pokemon Red is a Super Gameboy game and indeed already takes advantage of the SGB color features.

    If you want to check out pokered with color, see Danny-E 33's pokered with generation 2 elements here: https://github.com/dannye/pokered-gen-II
    My hack doesn't add color features to the game, it simply expands on them.

    You can see for yourself all the palettes that already defined in the game:
    https://github.com/iimarckus/pokered/blob/master/data/super_palettes.asm

    Also, you should update your RGBDS link:
    https://github.com/bentley/rgbds/releases

    Also, you should update your irc link:
    https://kiwiirc.com/client/irc.freenode.net/?#pret
     
    Last edited:
    104
    Posts
    11
    Years
    • Seen Nov 28, 2023
    this is a very good tutorial,, can we use this to add phy/spec split to pokemon red?

    now i really wish there is a tutorial like this for pokecrystal :o
     

    The ???

    The one true question mark
    289
    Posts
    11
    Years
  • whoa that's really awesome..
    Just a few questions, now since this is the WHOLE SOURCE, can't that be FULLY modified to make it Fire Red like? I mean can it be a .gba?
     

    Danny-E 33

    The Loneliest Cubone
    259
    Posts
    12
    Years
    • Seen today
    No.
    Yes, it is the full source but GB/C and GBA games are written in two different languages.
     
    1
    Posts
    8
    Years
    • Seen May 11, 2015
    I have another problem with the installing of pokered
    Everytime I type in "easy_install git://github.com/drj11/pypng.git@master#egg=pypng" it shows me the error "-bash: easy_install: command not found"
    I don't know why it shows me that, because I followed all the steps the right way
    What am I supposed to do?
     
    56
    Posts
    8
    Years
    • Seen Nov 27, 2016
    I had the same problem initially following a video tutorial, and the video tutorial gave me an alternate route, which I found on another forum:

    "--I don't know why it's not working.
    I've tried installing it through the command window, but it still says the same thing.--

    --1) Open the Cygwin installer, and go to the "select packages" window.
    2) Select the package named "curl" and install.
    3) From the Cygwin Terminal, type:
    Code:
    curl -O (I can't link the url at my post count lol. perhaps I can PM it?)
    and then:
    Code:
    python ez_setup.py
    4) Now you can type:
    Code:
    easy_install pypng--"
     

    ProClifo

    The Village Pirate Cat
    86
    Posts
    15
    Years
  • I keep getting this error when I type make red and make blue and I don't know what to do

    VFZQP7S.png


    I tried the solution in the OP but this is all that happened:

    V45HJmv.png
     

    PiaCRT

    Orange Dev
    937
    Posts
    13
    Years
  • If you have the 64 bit version I believe the folder names have some slight differences. You might need to adjust as needed.
     
    36
    Posts
    14
    Years
    • Seen Oct 19, 2023
    Hey folks! Do any of you know the maximmum amount of trainer battles that can be set without changing anything else other than adding more battles?
     
    130
    Posts
    8
    Years
    • Seen Jun 14, 2023
    So, I just tried to do this and I'm getting the same issue as ProClifo. I am using the 64 bit version and it already has the path correct. But it still shows it to be an invalid option. I tried the way that was meant to be done and then I tried Pia Carrot's way. It said the easy_install command isn't found. Can anyone help me? I really want to mess around with this version of Red.

    [EDIT] After looking at a different site, I found that the rgbds was old (OP if you're reading this, update your OP). I did "make" and it hasn't done anything past "rgbasm -D "_RED" -h -o audio_red.o audio.asm"
    Also, is there a guide to install PokeRed with gen 2 aspects? It gives the exact same directions as the original Pokered.

    [EDIT] Ok so, after letting it sit for around 10 minutes, it finally finished making red. And I figured how to install pokered with gen 2 stuffs.
     
    Last edited:
    2
    Posts
    7
    Years
    • Seen Nov 11, 2017
    How can I expand a menu border? I need to change Pokédex to Покедекс, but this word contains 8 letters, not 7.
     
    Back
    Top