Jump to content

Using PKHeX: Finding Event Flags and Event Constants


Recommended Posts

Overview
This tutorial is written for users who want to contribute to the research regarding event flags and event constants.
 

Pre-requisites
1. Ability to dump your save (save either dumped from cart, or snagged from emulator etc)
2. Ability to modify your save with PKHeX


Instructions
1. Load up the relevent save onto PKHeX

2. Go to Event Flags and switch to the Research tab.
image.png


3. Load up a save directly before the event using Load Old,
and a save directly after the event using Load New.
For example, I loaded a save directly before and after obtaining the starters.
image.png


4. You may get a prompt about Event constants. Yes and paste them into a new notepad file.
(It is okay if the prompt says there's no event constants differences)
image.png
 

Congratulations, you now have a list of which Event Flags was set and unset (in PKHeX),
and what Event Constants changed (pasted into Notepad)!

With the example above, there is a considerable amount of change between 2 saves,
because the example contained getting a starter, and defeating Bianca and Cheren.
(The fights was unavoidable, so the next save spot had much forced activity in-between)

 


View full tutorial

  • Like 1
Link to comment
Share on other sites

  • 4 years later...

I'm not used to PKHeX so I'm likely doing something wrong or misunderstanding how the Event Flag Research works, but: in Crystal, I saved just before and after talking to Carrie, the Mystery Gift girl in green on floor 5 of the Goldenrod Dept Store. Talking to her is what unlocks the Mystery Gift option in the main menu. Placing the pre-Carrie and post-Carrie saves into the Researcher brings up nothing. Just the Alert "No Event Constant diff found."

Am I using the Researcher wrong? It's not like I understand what the flags or constants mean. It's also possible that the Mystery Gift unlock isn't a flag, but I don't understand how that could be the case.

Link to comment
Share on other sites

  • 4 months later...
On 5/12/2023 at 10:35 PM, SupremeThunderDragon said:

I'm not used to PKHeX so I'm likely doing something wrong or misunderstanding how the Event Flag Research works, but: in Crystal, I saved just before and after talking to Carrie, the Mystery Gift girl in green on floor 5 of the Goldenrod Dept Store. Talking to her is what unlocks the Mystery Gift option in the main menu. Placing the pre-Carrie and post-Carrie saves into the Researcher brings up nothing. Just the Alert "No Event Constant diff found."

Am I using the Researcher wrong? It's not like I understand what the flags or constants mean. It's also possible that the Mystery Gift unlock isn't a flag, but I don't understand how that could be the case.

Event Flag Research only searches in a small subset of the savefile where most events are stored. The flag used to determine whether you unlocked Mystery Gift is not located in that subset. In US savefiles, it is located at address 0x0BE3 (value is 0x00 if unlocked). Event flags tracked by the Researcher start at address 0x29F3.

  • Like 1
Link to comment
Share on other sites

  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...