[0:00]In the past I made recreations of all the mystery gift events for the Gen 3 Pokémon games. Normally you would need to go to an event, but those aren't held anymore, so it's nice to be able to access them now whenever you want. But at the end of the video, I mentioned that there are some things I would like to tackle in the future. And the future is now. Today we're going to talk about translations, randomizations, and more. Let's get started. To talk about the progress of these new ROMs, we have to go back in time for a bit. In the Discord server for my channel, we reached out to the community to ask if people would like to help in the process of translating all the Gen 3 events. And luckily, a lot of people reached out and we made teams for each language. Without them, this wouldn't be possible, so first of all, I would like to give a huge shout out to everyone who helped. We will talk more about these amazing translations in a second, but first let's dive into some custom assembly code. There are a few features I would like to add to the ROMs. First of all, like mentioned before, I would like to add randomization for the eggs and combine them all into one ROM. There are also some Japanese only egg events, so let's localize those as well and use randomization for it. Next up, we have of course the translations for each event, but I would like to minimize the amount of ROMs we need to make, so I'm going to combine all languages for an event in one ROM. And on that same note, I'm going to combine similar Fire Red and Leaf Green and Emerald events in one ROM as well. And lastly, I need to make custom graphics to showcase the different languages. And maybe we'll also make some custom events. Anyway, let's tackle them all one by one and start with the randomization. But how can we realize this? Well, if we look into the past, it is currently not known how the randomization was exactly done. The only thing we have are theories and rumors, like that the Pokémon that was distributed was changed every single minute. But there's not enough information to verify it. It is known, however, that the randomization was done on the server side of the distribution. In these types of wireless events, we have the server that sends out the mystery gift events to the games that are around, which are the clients. It is technically possible to do the randomization on the client side, but this makes it so that the Pokémon itself is tied to the personality value and the IVs. This is not the case for the preserve samples, ruling this possibility out. Let's take a look at how we added randomization to the server. In the Aurora Ticket ROM, there is an unused RNG function. We need to utilize this function to get a random value every time we're about to send the script to the games. To understand this more, let's take a look at how the communication for mystery gift works between the server and the client. In order to send a Wonder Card and RAM script to the games, we need to go through a few steps. The first step is establishing communication with the game. The server looks for clients to communicate with and asks for their game information. Once the game data has been received by the server, it is checked to see if this game is allowed to receive the event. In the previous video, we had to change this check in order for it to allow Emerald, for example. Anyway, if it all matches up, then the server lets the client know that a Wonder Card is coming, and afterwards sends the actual card and script. That is basically it for the communication between the server and the client, but there are some exceptions that can happen here. First of all, if the client already has the exact same Wonder Card it is about to receive, then it is not sent and the server lets the client know that they already have this Wonder Card. Second, if the client has a different Wonder Card, then the server will ask the client if they would like to toss the current one for the new one. Those are the two exceptions that can happen here. Currently, we're only looking at images of this because the assembly code will not make sense right now and will take too long to explain. But what you need to know is that at this point, before the server sends over the RAM script, we need to run our custom code to choose a script based off of the random value. We will, however, take a small look at the custom assembly code I made. We first do an RNG call and use a modulo operation on it to simply select which Pokémon will be sent over. We defined the indexes as followed. Nothing too crazy, right? Lastly, in our assembly code, we edit the part of the X script that determines the Pokémon and its moves. That is basically it for our custom assembly code for the randomization. Now you can get each Pokémon to serve randomization in one single ROM instead of six different ones. And with that, the first step is done. However, randomization can be really annoying. Imagine you want a Wish Chansey really badly, and you keep on getting the stupid Farfetch because the RNG just dislikes you. No worries. I also added button combinations for each of the Pokémon you can get from an event. Let's take a look at the assembly code again. So this is the code we had from before, and over here before it, I make a jump to our new function. In this function, we read out the register where we can see the current status of the different inputs. I first read out this register and reorganize the buttons in a way so that we can use this value directly. It will then return the reorganized value. If your button combination is invalid, then it will just simply use the randomization like before. But if it is good, then it will skip the randomization and give you the Pokémon you want. That's enough assembly code for a minute. Let's take a look at what button combinations give which Pokémon. For the wish X, everything below this point will be invalid, but as you can see, it is made so that bigger groups of Pokémon are still allowed. This is for the Japanese only events because they have more Pokémon. Let's take a look at those right now as well and finish up the X. There are two Japanese only egg events, the PokéPark Eggs and the eggs distributed in Pokémon centers of Japan. There are only four X from the Pokémon Centers of Japan. Oddish with Leech Seed, Meowth with Petal Dance, Poliwhirl with Sweet Kiss, and Bellsprout with Teeter Dance. The PokéPark X have many more Pokémon with 15 in total. These were released in two different ways in Japan. Once was through multiboot, which we recreated before already. Now we will recreate it using mystery gift as well. The randomization and button combinations for both of these events will work the same as the PCNY Wish Eggs from before. Now let's take a look at the Wonder Card for these events. We decided to switch things up a bit compared to the previous Wonder Card we made. Instead of calling the event Wish Egg, it is now Pokémon Center New York. For the Japanese only events, we have Pokémon Center Japan and PokéPark Market Fantasia. With the Wonder Cards now also done, we have made localizations for the English games. Now it's about time to take a look at the translations made by every team. Let's start with Japanese. As you might know, for Japanese, most of the events have already been released officially. These were changed a little bit to make sure there's no date on it anymore. Besides that, we also have some custom ones, like the Eon Ticket. The three egg events with our new headers for each event. And lastly, the Altering Cave. Now let's take a look at the translations for German, French, Italian, and Spanish. For each of these languages, only one mystery gift event was released. The Aurora Ticket. This is what they had to use as a basis to make all the other events. The other ticket events are very similar to this one. We have Mystic Ticket. Old Sea Map. And the Eon Ticket. Next up are the egg events. Like discussed before, they are more custom compared to the tickets, but all the translators did an amazing job to create these for each language. And lastly, we have the Altering Cave. In case you were wondering, we do not have to translate the RAM scripts that is used when talking to the man in green. These scripts are located in each of the games, and we can extract them and use them in our events. And with that, we have each event fully translated. Now it's time to put all these translations into the ROM. But before we go on to look at assembly code again, I would like to once again thank each and every one who contributed to translating these events. We couldn't have made this project without you. Now next up on our list is combining all the languages into one ROM. We could just call the day and release a ROM for each language, but that's no fun. In our custom code, we have to figure out with which language we are communicating with and send out the correct Wonder Card and RAM script. Let's take a look at the communication diagram again from before. We will place our code in two different places here. One is just before sending the Wonder Card, and the other one is just before sending the RAM script. As you remember, we have some code here for the RAM script regarding the randomization for the egg Pokémon. We will simply place the language detection code a bit before the randomization in the X ROMs. Now let's talk about how we will do this language detection. If we go back to our diagrams again, then we can see that the game sends over some game info data. At this step, it either continues or ends the communication between the server and the client. For example, some Emerald events should not be sent over to Fire Red and Leaf Green. We need to do something here as well later, but first let's take a look at the game info data structure. In this structure, we have validation flags and variables to let the server know if we can receive this gift in the first place. But we also have at the bottom here a ROM header game code. This is what we are looking for. You see, each game has a different header game code to differentiate between each other. Besides just telling us what game it is, it will also tell us the language of the game. So what we need to do is check this game header to determine which language and which game we are communicating with. Let's take a look at how I coded this. The function that will determine the language will return a custom value of 8 bits long. The first half will determine which game we are communicating with, and the second half the language. The first thing we do in the code is determine which game we are communicating with. The first two letters are the same for Fire Red, Leaf Green and Emerald games. So we can check both letters at the same time, and if it matches up, we can move on to the next letter. The third letter determines which game it is. R is for Fire Red, G is for Leaf Green, and E is for Emerald. Like mentioned before, we use half of the 8-bit value to determine which game we are communicating with. We will use zero for Fire Red and Leaf Green and one for Emerald. Now we can move on to the last letter. This can be either J, E, F, I, D, or S. I gave each letter an index so that we can later easily determine which Wonder Card we need to send. So in the next part of the code, we simply go through each of these six letters and add the correct index to our variable. Using this value, we can now select the correct Wonder Card and RAM script for each language and send it to the games. With that done, we can now send the correct Wonder Cards to each language, or almost every language. For some reason, the Japanese games don't want to initiate communication with our server ROM. So what's going on? If we look at the code in the games, we can see that it only sends game data if the serial number of the one acting as server is equal to this value. This is the case for all European languages. But for Japanese, however, we need to use this value instead. So if we change the value in the mystery gift ROM to this as well, then it can communicate with the Japanese games. But it then only works for Japanese. So is it even possible to make one ROM available for all languages? Of course it is. Here's how we did it. Let's take a look at our fun diagrams again. But in the beginning, we add our serial code. Instead of always using the serial code for Japanese, or for the international one, we alternate between the two every two messages. Like this, we can offer support to both Japanese and all other languages with one ROM. Let's take a look at the assembly code. R1 holds the serial code that we need to alternate between. But there's not enough space here to make that happen. Let's delete two lines of code and make a jump to our custom code. Here we use a variable that is incremented every time we try to initiate communication. If it is less than two, then we use the serial code for the international games. But if it is greater than two and not equal to four, then the Japanese serial code is used, and it will keep repeating every four cycles. Now that we have completed our code, we need to restore the code that we deleted and jump back to where we were. And afterwards, things will just resume as normal. Like this, all languages are supported in one ROM. Now to finish off these ROMs, let's talk about the graphics. Currently, it just says the English names of the events, but that is not so fun. Aurora Ticket, for example, is called very differently throughout each of the six languages. We need to change this. You might have noticed it already a few times before in the video, but I would like to fade out and fade in the graphics. But how can we do something like that? Let's first again talk about how the graphics are exactly structured. Each graphic is made out of little 8x8 cubes, or 64 pixels in total. For one cube, we need a total of 32 bytes because each four bits represents a color of the color palette for a pixel. Now let's talk about what we want to achieve. There might be an easier way to do it, but this is what I came up with. I'm going to slowly change the colors of the palette to the color of the background, then switch out the graphic in memory, and lastly change the colors of the palette back to what is used in the graphic. We only have a limited time to do this because we also have these darker purple bars going across the screen. The plan is that when the purple bar is past the text, we slowly fade out and fade in before the next line shows up. Like this, every possible language is represented on the screen of the distribution ROM. And that finishes the translations and randomization for each ROM. Every event that was ever released and even unreleased events are now localized for each language. Now last on our list, let's take a look at the clock. We still have enough time. Let's take a look at some custom events. The first custom event is the Regidolls. These are dolls that were only released in Japan as an E-Reader card for Ruby and Sapphire. The only way to get these in Emerald is to use record mixing with games that already have these dolls. Let's change that and make it easier to get. The script will give you all three Reggie dolls in one go, and has error handling in case you have too many dolls from home. For example, if you can only receive two out of the three dolls, then the deliveryman will hold the last doll for you until you are ready to receive it. The text even changes to let you know it is about one singular doll instead of multiple. Now we have one more event in store for you. It is none other than a custom event to give you a Potion or a Poké Ball, because you can never have too many of these things. The Poké Ball is the best ball, and was I supposed to get that? On rare occurrences, the deliveryman makes a mistake and gives you an item you weren't supposed to get. I won't spoil all the items you can get here, that's something you can play around with all by yourself. Both of these events are of course also translated and have custom graphics in the Mystery Gift ROM as well. If you want to use any of these events, you can download the files with instructions on my GitHub page using the link in the description. And with that, we've covered all events. I want to once again thank each and every member of the translation team. This project wouldn't be possible without all of you helping us translate each event. I also want to give special thanks to UndeadXReality. He tested and prepared all ROMs and helped to get it ready for the release today. And lastly, I would like to thank all of you for watching. And I'll see you in the next one.
Transcript source
YouTube auto captions
This transcript was extracted from YouTube's auto-generated caption track. The transcript below is server-rendered so it can be read, searched, cited, and shared without opening the original YouTube player.
Pull quotes
[0:00]In the past I made recreations of all the mystery gift events for the Gen 3 Pokémon games.
[0:00]Normally you would need to go to an event, but those aren't held anymore, so it's nice to be able to access them now whenever you want.
[0:00]But at the end of the video, I mentioned that there are some things I would like to tackle in the future.
[0:00]To talk about the progress of these new ROMs, we have to go back in time for a bit.
Use this transcript
Related transcript hubs
Watch on YouTube
Share
MORE TRANSCRIPTS



