• 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.

Help Thread: Quick Questions & Answers

Status
Not open for further replies.

miksy91

Dark Energy is back in action! ;)
1,480
Posts
15
Years
  • Rookie mistake :/ Thanks!

    Anyway, that has brought to light another issue. The egg giving replaces the 6th pokemon in your party, if you have a full party.

    I didn't think I would need anything extra, as you would have thought that the egg could only be given if you had room. I added a check code to look at the number of pokemon in your party. If you have 6, it jumps past the egg giving bit. However, it doesn't seem to work. I double checked with the Karate King's code, and that also contains the same verification: 1C 01 06 06....

    Why is it not skipping ahead. The PKSV scripts make sense and all seem to link together?

    giveegg2.png
    Hard to say if Karate King's script really does the same thing.. You probably re-loaded the rom when you had saved those changes, right? In case you don't get it working that way, try putting this script for any person event you like so you can re-run it easily everytime you make changes.

    I've stumbled upon the source code for Pokemon Crystal, and since I know some Assembly I thought I could make a neat small modification or addons to the game as programming practice.

    I've changed scripts, moved around a few options for trainers, pretty much everything that can be done by just editing the code. But unfortunately I can't seem to figure out how to add new maps.

    I'm fairly sure the maps are contained in the BLK files from the source code, although I have no clue how to edit them. The information online is incredibly scarse, I found a few people telling me to use Crystalmap, but I don't see how that can work with the source code, since it edits an already existing ROM.

    If anyone has any idea on how to do this, or has a good resource to look at I would really appreciate it. I've tried for two days but I can't seem to figure it out by myself.
    If BLK files contain the hex code of the in-game maps, you can just write maps with CrystalMap and then copy paste the hex code of the maps you make to new BLK files. Then just replace the original BLK files with those you make.
     
    36
    Posts
    9
    Years
    • Seen Apr 4, 2017
    Having a strange problem with my warps. When I leave my house, I go to the proper map (finally, you wouldn't believe how long it took to get that working, right, and I'm still not sure exactly what fixed it) and if I go back inside, I go back to the house map, just fine, but if I leave the house again, the game goes to a black screen and doesn't load the town map. Has this happened to anyone else? I'm not entirely sure why it would work the first time, but not the second. I even made sure I used the exact same warp both times.
     
    130
    Posts
    8
    Years
    • Seen Jun 14, 2023
    I have a couple questions. Using FR rom btw.

    1. [FIXED] I created a new area to give the player the ability to capture all of the starter pokemon. It's a cave on Route 22 in that little hill area in the middle. Whenever I go into the little cave, my character is facing down. I don't know what to do to change it so he's facing up as if he went through the cave entrance. --- Turns out I had the wrong tile under the cave warp.

    2. I remember seeing a thread somewhere that had a bunch of fakemon sprites but I can't remember where it was. If someone has the link can they reply with it?

    3. [FOUND] Is there someone who makes titles screens for FireRed? I would normally do it myself but the steps for FR are quite different than EM.

    4. [FOUND] Has someone made a GBA sprite set for Mega Gyrados? I'm wanting to incorporate it into my storyline as a legendary Pokemon.

    5. Just a bump on my last post. Is there someway to remove the form changes made by the game for Deoxys? I want it to be it's Normal forme.
     
    Last edited:

    Telinc1

    Weirdo Extraordinaire
    168
    Posts
    10
    Years
  • How do you determine if pokemon fire red is bpre?
    English FireRed is always BPRE, no exceptions.
    BPRE is the ROM code. BPR identifies the game (in this case, FireRed) and the E identifies it as being in English (e.g. German FireRed would be BPRG for).
    GBATEK has more information on this (scroll down to "0ACh - Game Code, Uppercase Ascii, 4 characters").
     
    88
    Posts
    8
    Years
    • Seen May 10, 2017
    Hard to say if Karate King's script really does the same thing.. You probably re-loaded the rom when you had saved those changes, right? In case you don't get it working that way, try putting this script for any person event you like so you can re-run it easily everytime you make changes.

    Well, before the game crashed since it must have been going to a random part of the code. Now it gives the egg as intended but replaces the 6th party member, so it must have reloaded ok.

    Surely that checkcode should work for the party count, or have I done something wrong? The karate king code seems to check the pokemon in your party. If = 6, it tells you that you have no room; otherwise, it goes to the part of the code that gives you Tyrogue.
     
    Last edited:
    88
    Posts
    8
    Years
    • Seen May 10, 2017
    v switch

    I have another question and this is likely to be the last one I need to ask before the hack is done (alongside the egg problem).

    I'm adding new moves into Crystal via hex. All have worked fine, but the last move I need does not. I want to add Volt Switch.

    The setup for moves is as follows:
    [Attack Animation] [Effect] [Base Power] [Type] [Accuracy] [PP] [00]

    Theoretically, I thought that the Baton Pass effect, plus a BP of > 0 should both switch out and inflict damage. It does not. After some research, it seems as if the routine for Baton Pass switches out before calculating any damage.

    My question is, how can I change that (via hex), so that the Baton Pass effect inflicts the BP damage first before switching?

    Thanks!
     

    miksy91

    Dark Energy is back in action! ;)
    1,480
    Posts
    15
    Years
  • Surely that checkcode should work for the party count, or have I done something wrong? The karate king code seems to check the pokemon in your party. If = 6, it tells you that you have no room; otherwise, it goes to the part of the code that gives you Tyrogue.
    It should function properly if the code is practically the same thing as that one Karate King has (and if Karate King's script indeed works fine in the game).

    But if for some reason for example checkcode 0x1 isn't functioning properly in Crystal (it does in GS), you can try accessing the party pokemon count directly by other means. According to this forum topic (http://forums.glitchcity.info/index.php?topic=1342.0) the number of pokemon you have in your party is stored in DCD7 in Crystal. So you can use script code "19" (in GS, might also be 1A in Crystal ?) to load the count from there directly into RAM and then compare it to 06. "RAM" is basically the ram address where all kinds of feedback from operations are stored, so checkcode 0x1 should basically do the same thing; load pokemon count into RAM. It could also be so that "if == 0x6 @blaa" isn't actually doing the right kind of comparison although that would be odd as well.

    I have another question and this is likely to be the last one I need to ask before the hack is done (alongside the egg problem).

    I'm adding new moves into Crystal via hex. All have worked fine, but the last move I need does not. I want to add Volt Switch.

    The setup for moves is as follows:
    [Attack Animation] [Effect] [Base Power] [Type] [Accuracy] [PP] [00]

    Theoretically, I thought that the Baton Pass effect, plus a BP of > 0 should both switch out and inflict damage. It does not. After some research, it seems as if the routine for Baton Pass switches out before calculating any damage.

    My question is, how can I change that (via hex), so that the Baton Pass effect inflicts the BP damage first before switching?

    Thanks!
    You can take a look at how the move effects work from disassembly (https://github.com/pret/pokecrystal/blob/master/battle/moves), and try to figure out, how to make Volt Switch have a totally new effect.

    I'd imagine you having to make room for a new entry in move_effects_pointers list, and making it point to a new move_effect that would share the datas of "NormalHit" and "Baton Pass" of which datas you can find in move_effects.asm file. The effects seem to be simply hex bytes, so they can be edited easily. What I don't know though is that where that move_effects_pointers table is located. You could try asking in skeetendo if somebody knows.
     
    Last edited:

    Teh Blazer

    Divider of Zero
    776
    Posts
    15
    Years
  • For those that inserted touched;s mega evolution routine, how did you go about creating the mega evolutions? Did you replace the ?'s or expand the pokedex or just replace old pokemon? I'm trying to brainstorm the best way to add in the mega evolutions but my mind is coming up blank.
     
    14
    Posts
    7
    Years
    • Seen Aug 31, 2017
    Hey, by any chance does anyone have the offset for the mom intro in pokemon ruby where she says "MOM: [Player] Hey, honey! It must be tiring riding with our things in the moving truck..." etc. Including the script for when you jump out of the van and she comes out of the house to greet you?

    I went on advance text and found the script (Dec:1484745 Hex:16A7C9) but when I type it into XSE is comes up with nothing, which leads me to believe it's a different one and that it's a string offset only for the actual text itself but not the additional commands including jumping out the van.

    If anyone could help it'd be greatly appreciated, thank you c:
     
    Last edited:
    88
    Posts
    8
    Years
    • Seen May 10, 2017
    How do the gym leader prize TMs work in Pokemon Crystal? I want to add TM prizes for the Kanto leaders but can't seem to find their scripting.

    For example, if I try to look at Bugsy's script I do the following:

    His person data is at offset x72FF9. His script pointer bytes are 6A 6A. Using this I bring up x72A6A. Using PKSV to view the script, there isn't anything there of note.

    So, I tried to look for the item code for TM49 that he gives, which is 0xF1.... but that isn't anywhere. Even searching for "1F F1 01" (giveitem TM49 x 1) yields nothing.... in the entire code.

    I want to find the existing code for giving TM prizes for beating a leader so I could copy for the leaders who don't have a TM prize, but I can't piece it together. Annoyingly.

    Anyone have any idea?

    Thanks
     

    miksy91

    Dark Energy is back in action! ;)
    1,480
    Posts
    15
    Years
  • How do the gym leader prize TMs work in Pokemon Crystal? I want to add TM prizes for the Kanto leaders but can't seem to find their scripting.

    For example, if I try to look at Bugsy's script I do the following:

    His person data is at offset x72FF9. His script pointer bytes are 6A 6A. Using this I bring up x72A6A. Using PKSV to view the script, there isn't anything there of note.

    So, I tried to look for the item code for TM49 that he gives, which is 0xF1.... but that isn't anywhere. Even searching for "1F F1 01" (giveitem TM49 x 1) yields nothing.... in the entire code.

    I want to find the existing code for giving TM prizes for beating a leader so I could copy for the leaders who don't have a TM prize, but I can't piece it together. Annoyingly.

    Anyone have any idea?

    Thanks
    That's Erika's script at 0x72A6A, and she gives item 0xD2 after being defeated. giveitem code (1F) works for adding an item to player's inventory, but it doesn't include printing text (= "HIRO received [item]."), and it doesn't play a sound effect either. There is however another script code that does all this. The code is nr. 9D in GS, and in pksv it's shown as 'verbosegiveitem'.
     
    88
    Posts
    8
    Years
    • Seen May 10, 2017
    Oh yeah, I looked at a few gym leaders. This one must have been for Erika, not Bugsy. My mistake.

    The point still stands though, there is no give item for her TM either. Neither 1F or 9D commands appear in her script for that TM. There is a reference to D2 01 for Erika, but that is preceded by 9E, which is for loading pokemon data - so it can't be that.

    I'm still at a loss as to how the leader scripts work. When other people give items, it follows the [1F/9D][item][amount] format, so is quite easy to distinguish. The TM prizes don't seem to work like that though.
     

    miksy91

    Dark Energy is back in action! ;)
    1,480
    Posts
    15
    Years
  • Oh yeah, I looked at a few gym leaders. This one must have been for Erika, not Bugsy. My mistake.

    The point still stands though, there is no give item for her TM either. Neither 1F or 9D commands appear in her script for that TM. There is a reference to D2 01 for Erika, but that is preceded by 9E, which is for loading pokemon data - so it can't be that.

    I'm still at a loss as to how the leader scripts work. When other people give items, it follows the [1F/9D][item][amount] format, so is quite easy to distinguish. The TM prizes don't seem to work like that though.
    The script code you're looking for is indeed "9E D2 01". If you take a look at the in-game item list, it says D2 refers to "TM Giga Drain". And since the "end" code (in scripts) is 90 in GS and 91 in Crystal, also all the other script commands, that have their hex code >= 0x90 in GS, have their hex code being that of GS + 1. So 9D --> 9E.

    This happens to work like this because Gamefreak decided to expand the scripting system for Crystal that they had designed for GS by adding some new script command in between all the script commands for GS. I don't know what this new command is or what it is hex code, but you basically have to add 1 to the hex code of all the script commands following that to match the scripting commands of the compendium.
     
    Last edited:
    130
    Posts
    8
    Years
    • Seen Jun 14, 2023
    I'm wanting to change the palettes for the male and female back sprites for the player character when starting a battle. I just need the palette offset for FireRed since I'm keeping the picture.
    Also, the palette offset for the overworld icons. Like, the palette 0 that's mainly used for the male sprite.

    [EDT] Nevermind, found the overworld pallette. And the backsprite palette using NSE. It didn't give me the palette used when selecting the character. If someone could tell me what that one is I would appreciate it.

    [EDIT] Since no one has commented since my last post I won't double post. Is there a way to add a new page to the habitats for FireRed? I'm adding new Pokemon. I'm not sure if Gen 3 hacking suite adds new pages if the page is too full. Nevermind. There's a thing on PGE.

    Is there a tutorial for Advance Map to allow for extended Pokemon?
     
    Last edited:
    14
    Posts
    7
    Years
    • Seen Aug 31, 2017
    Hey, does anyone know why palette 6 for tileset 0 on advance map has colours when the tilesets of the map are 0 and 1, but doesn't have any colours when the tilesets are 0 and 2?

    I thought that palette 0 - 6 were for the first tileset and 7 - 12 were for the second, and that the palettes were constant regardless of the tileset combination of the map

    Also someone told me that palette 12 was for the front screen or something like that, is this true for every tileset (0-57) or only tileset 0?

    Cheers, thanks
     
    130
    Posts
    8
    Years
    • Seen Jun 14, 2023
    Is there a tutorial to be able to put expanded Pokemon in the wild using Advance Map? The tutorial I found is two years old and the program doesn't even go for enough for the offset they specified. I REEEEEEEALLLY don't want to compare the rom each time I want an extended Pokemon in the wild. I have 1.92 if that one is better than 1.95.
     
    88
    Posts
    8
    Years
    • Seen May 10, 2017
    The script code you're looking for is indeed "9E D2 01". If you take a look at the in-game item list, it says D2 refers to "TM Giga Drain". And since the "end" code (in scripts) is 90 in GS and 91 in Crystal, also all the other script commands, that have their hex code >= 0x90 in GS, have their hex code being that of GS + 1. So 9D --> 9E.

    This happens to work like this because Gamefreak decided to expand the scripting system for Crystal that they had designed for GS by adding some new script command in between all the script commands for GS. I don't know what this new command is or what it is hex code, but you basically have to add 1 to the hex code of all the script commands following that to match the scripting commands of the compendium.

    Sorry for the late response Miksy, I encountered a big problem around this time and decided to take a break from Crystal for a while. That information is really helpful and explains a lot, thanks. I guess that is the issue with using info designed for Gold & Silver - not all of it is relevant. Oh well.

    The issue with the egg also seems to have resolved itself. I've been using my phone emulator to test and, despite reloading the rom, it didn't seem to refresh properly. It works fine now though. Bit weird as before I made the changes the game crashed, so I just assumed it must have refreshed. Never mind.
     
    Status
    Not open for further replies.
    Back
    Top