# Glitch City Laboratories Archives

Glitch City Laboratories closed on 1 September 2020 (announcement). This is an archived copy of a thread from Glitch City Laboratories Forums.

You can join Glitch City Research Institute to ask questions or discuss current developments.

You may also download the archive of this forum in .tar.gz, .sql.gz, or .sqlite.gz formats.

## Arbitrary Code Execution Discussion

### 8F crashes game - Page 1

Previous Page

- 1

Next Page

#### 8F crashes game

Posted by: naf102
Date: 2016-02-18 19:35:54
I obtained 8F through the Item Counter Underflow Glitch and my party meets the requirements for it to run code. But every time I attempt to run code through 8F the game crashes. I have no idea why though. Any idea?

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-19 08:13:57
Hi,
Could you tell us more about:
- The game you are playing (R/B or Yellow) and its localization (US/UK, JP, EUR)
- The content of your party (R/B) / active box (Yellow)
- The code you try to execute (= the items you currently have in your bag while using 8F)
We will then be able to help you more ;)

#### Re: 8F crashes game

Posted by: naf102
Date: 2016-02-20 13:59:58
I am playing on a US / UK Pokémon Blue. I currently have a Onix, Pidgey, Tentacool, Meowth, Hitmonlee and Snorlax in that exact order. The code I was trying to run required 64 Ultra Balls, 201 Lemonades, 75 TM55s and Repel x(Pokémon index number) That's what I have in my bag including 8F and 255 Master Balls.

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-20 14:54:49
If I understand well, the order of your items is:
- Master Ball x255
- 8F
- Hyper Ball x64
- Lemonade x201
- TM55 x75
- Repel x(hex)
Because if so it doesn't seem to do something and also lacks a ret instruction to end it. Could you tell us what you want to do, precisely? Also, where did you find this party setup? I couldn't figure out how it jumps to items.

#### Re: 8F crashes game

Posted by: naf102
Date: 2016-02-20 15:12:01
I made a mistake sorry. The order of my items are Master Ball x255, 8F, Repel ( hex ), X Speed x14, Ultra Ball x64, TM05 x72 and Lemonade x201. I didn't have my game on hand to look at my items. And I followed the steps in this link http://forums.glitchcity.info/index.php?topic=6638.0

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-20 15:33:00
Alright, yes indeed this setup works if you make sure you follow all the PP and move requirements. But there are other setup, way more easy to do, like this one:
5 Pokémon
Pidgey as the first Pokémon
Parasect as the second Pokémon
Onix as the third Pokémon
Tentacool as the fourth Pokémon
Kangaskhan as the fifth Pokémon
Pidgey must have 233 HP
(taken from the wiki page)
So, the code now. Are you sure about the number of the TM? What are you trying to do with this code?

#### Re: 8F crashes game

Posted by: naf102
Date: 2016-02-21 11:15:32
Okay, so I changed my party to the party you suggested but the game still crashes once I select use. I'm trying to run the "Catch Em' All" script as a proof of concept so that I can run my own code. And yes, I am sure it is TM05

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-21 11:29:12
I never tried that catch'em all script written in TheZZAZZGlitch's introductive post of the 8F thread, but I'm assuming it works and if you do things correctly (party & items) then it shouldn't crash.
Have you ever tried another code? Like the 'change the second item' code just below? So that we see if you can indeed run code?

#### Re: 8F crashes game

Posted by: naf102
Date: 2016-02-21 13:45:53
Yes I have tried and the same result happens, the game freezes.

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-21 14:11:32
Can you provide screens of your party and items menu? This is really weird.

#### Re: 8F crashes game

Posted by: naf102
Date: 2016-02-21 15:00:35
Okay here there are

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-21 15:37:54
One tricky thing about this setup is that you have to remember to use a PP Up so $D1B6 = 55. But I don't think your problem is in the setup because you would have solved that problem with the other setup.
I really don't get what your problem is. Which emulator do you use? If you have access to a memory viewer, can you check that every suitable value is set? When you activate the 8F item, the following addresses should be as below:
D163 = 06
D164 = 22
D165 = 24
D165 = 18
D166 = 4D
D1B5 = 18
D1B6 = 55
D20C = 24
D20D = 18
D20E = 14
D223 = 68
D224 = 18
D225 = 46
D26C = E9
If it's not the case, that's probably because something altered your save file. If you don't know how to check that, you can send me your save file.

#### Re: 8F crashes game

Posted by: TheZZAZZGlitch
Date: 2016-02-21 17:14:40
The problem is in these 5 requirements:
[tt]6. 24 PP left on the second Pokémon's second move [0xD1B5 = 0x18]
7. 21 PP left on the second Pokémon's third move w/ 1 PP Up used [0xD1B6 = 0x55]
8. 36 PP left on the fourth Pokémon's first move [0xD20C = 0x24]
9. 24 PP left on the fourth Pokémon's second move [0xD20D = 0x18]
10. 20 PP left on the fourth Pokémon's third move [0xD20E = 0x14][/tt]
It turns out that these requirements are a bit unclear, and I wasn't aware of that until just now. What I really meant is:
[tt]6. 24 PP left on the second Pokémon's second move w/ 0 PP Ups used [0xD1B5 = 0x18]
7. 21 PP left on the second Pokémon's third move w/ 1 PP Up used [0xD1B6 = 0x55]
8. 36 PP left on the fourth Pokémon's first move w/ 0 PP Ups used [0xD20C = 0x24]
9. 24 PP left on the fourth Pokémon's second move w/ 0 PP Ups used [0xD20D = 0x18]
10. 20 PP left on the fourth Pokémon's third move w/ 0 PP Ups used [0xD20E = 0x14][/tt]
PP Ups should not be used on moves other than the second Pokémon's third move.

#### Re: 8F crashes game

Posted by: naf102
Date: 2016-02-21 18:33:43
Fixed it thank you two very much ;)

#### Re: 8F crashes game

Posted by: Krys3000
Date: 2016-02-22 13:09:06
Nice! But I really recommend you to use another setup :P
Previous Page

- 1

Next Page