Glitch City Laboratories Archives

Glitch City Laboratories closed on 1 September 2020 (announcement). This is an archived copy of an article from Glitch City Laboratories wiki.

A live version of this article is available at the Glitch City Wiki here.

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

You may also download the archive of the wiki in .tar.gz or .xml.gz formats.

Expanded bag item documentation (Generation I)

This article is incomplete. Please feel free to add any missing information about the subject. It is missing: Index number.




This is a list of correspondences between RAM addresses and item slots when making use of the expanded item pack in Pokémon Red, Blue, and Yellow. Changing a given item index number or quantity will directly change the RAM address associated with it.

{|
Bag item/quantityDisassembly labelRed/Blue addressYellow addressDetails
Item 21 quantitywPlayerMoneyD347D346Byte 1 of the player's current money (this value is read as BCD; see below.)
Item 22wPlayerMoneyD348D347Byte 2 of the player's current money (this value is read as BCD; see below.)
Item 22 quantitywPlayerMoneyD349D348Byte 3 of the player's current money (this value is read as BCD; see below.)
Item 23wRivalNameD34AD349The 1st letter of the rival's name.
Item 23 quantitywRivalNameD34BD34AThe 2nd letter of the rival's name.
Item 24wRivalNameD34CD34BThe 3rd letter of the rival's name.
Item 24 quantitywRivalNameD34DD34CThe 4th letter of the rival's name.
Item 25wRivalNameD34ED34DThe 5th letter of the rival's name.
Item 25 quantitywRivalNameD34FD34EThe 6th letter of the rival's name.
Item 26wRivalNameD350D34FThe 7th letter of the rival's name.
Item 26 quantitywRivalNameD351D350The 8th letter of the rival's name. (This should be $50 if playing normally and the rival's name is the maximum length of 7 characters.)
Item 27wRivalNameD352D351The 9th letter of the rival's name.
Item 27 quantitywRivalNameD353D352The 10th letter of the rival's name.
Item 28wRivalNameD354D353The 11th letter of the rival's name.
Item 28 quantitywOptionsD355D354The options visible in the Options menu. Bits 0-3 correspond to text speed, with their value amounting to the amount of frames between each character printed to the screen; 5 corresponds to the "Slow" option, 3 to the "Medium" option, and 1 to the "Fast" option. Bit 6 corresponds to the Battle Style: it is 0 when the style is set to Shift, and 1 when set to Set. Bit 7 corresponds to Battle Animations; however, it is 0 when Battle Animations are on, and 1 when they are off. (reword)
Item 29wObtainedBadgesD356D355The badges the player has obtained, in the form of a binary array. Each bit that is set corresponds to one badge being obtained (e.g. when set to FF, the player has all 8 badges.)
Item 29 quantitywObtainedBadgesD357D356Unused
Item 30wLetterPrintingDelayFlagsD358D357If bit 0 of this address is 0, the delay between which text characters are printed to the screen is limited to one frame. The values of both bit 1 of this address and bit 6 of D730 take priority over this. If bit 1 of this address is 0, there is no delay after a text character is printed, allowing for instant text.
Item 30 quantitywPlayerIDD359D358The upper byte of the player's trainer ID.
Item 31wPlayerIDD35AD359The lower byte of the player's trainer ID.
Item 31 quantitywMapMusicSoundIDD35BD35AThe sound effect/track/cry ID for the current map. 0xFF is usually 'mute', and many other values correspond to town/city etc. themes. The selection of sounds/music depends on wMapMusicROMBank. The easiest method to play the music is by riding and dismounting the Bicycle or using the nameless 0x78 glitch item.
Item 32wMapMusicROMBankD35CD35BThe ROM bank of the music of the current map. Expected banks are 0x02 (overworld 1) and 0x1F (overworld 2). 0x08 (battle) and 0x20 (Pikachu's Beach EN Yellow). Glitch music banks are also possible. The easiest method to play the music is by riding and dismounting the Bicycle or using the nameless 0x78 glitch item.
Item 32 quantitywMapPalOffsetD35DD35CThe current color attribution of the map (D35D (D35C in Pokémon Yellow)) including 'cave darkness', which involves a D35D/D35C value of hex:06. See also play the Safari Zone in the dark glitch.
Item 33wCurMapD35ED35DThe currently loaded map (must be reloaded to apply). May also affect palette and map script bank.
Item 33 quantitywCurrentTileBlockMapViewPointerD35FD35EFirst little endian byte of the pointer to the upper left corner of the current view in the tile block map.
Item 34wCurrentTileBlockMapViewPointerD360D35FSecond little endian byte of the pointer to the upper left corner of the current view in the tile block map.
Item 34 quantitywYCoordD361D360The player's Y coordinate on the current map.
Item 35wXCoordD362D361The player's X coordinate on the current map.
Item 35 quantitywYBlockCoordD363D362Affects the alignment for blocks on the screen. Normally either 0 or 1. It alternates each time the player walks up/down.
Item 36wXBlockCoordD364D363Affects the alignment for blocks on the screen. Normally either 0 or 1. It alternates each time the player walks left/right.
Item 36 quantitywLastMapD365D364The index of the last map the player was in.
Item 37wUnusedD366D366D365Set to the width (in blocks) of the current map (before warping) when taking a warp from an "outside" map (usually when entering a building or a cave). Normally unused.
Item 37 quantitywCurMapTilesetD367D366The tileset used by the current map.
Item 38wCurMapHeightD368D367The height (in blocks) of the current map.
Item 38 quantitywCurMapWidthD369D368The width (in blocks) of the current map.
Item 39wMapDataPtrD36AD369The upper byte of the pointer of to the data for the current map.
Item 39 quantitywMapDataPtrD36BD36AThe lower byte of the pointer to the data for the current map.
Item 40wMapTextPtrD36CD36BThe upper byte of the pointer to the text for the current map.
Item 40 quantitywMapTextPtrD36DD36CThe lower byte of the pointer to the text for the current map.
Item 41wMapScriptPtrD36ED36DThe upper byte of the pointer to the script for the current map.
Item 41 quantitywMapScriptPtrD36FD36EThe lower byte of the pointer to the script for the current map.
Item 42wMapConnectionsD370D36FMap connections (?)
Item 42 quantitywMapConn1PtrD371D370Map connection 1 (?)
Item 43wNorthConnectionStripSrcD372D371The upper byte of wNorthConnectionStripSrc (?)
Item 43 quantitywNorthConnectionStripSrcD373D372The lower byte of wNorthConnectionStripSrc (?)
Item 44wNorthConnectionStripDestD374D373The upper byte of the pointer to the map to the north of the current one.
Item 44 quantitywNorthConnectionStripDestD375D374The lower byte of the pointer to the map to the north of the current one.
Item 45wNorthConnectionStripWidthD376D375The width of the strip connecting to the map north of the current one. (?)
Item 45 quantitywNorthConnectedMapWidthD377D376The width of the map to the north of the current one.
Item 46wNorthConnectedMapYAlignmentD378D377The Y alignment of the map north of the current one.
Item 46 quantitywNorthConnectedMapXAlignmentD379D378The X alignment of the map to the north of the current one.
Item 47wNorthConnectedMapViewPointerD37AD379The upper byte of the pointer to the view of the map north of the current one. (?)
Item 47 quantitywNorthConnectedMapViewPointerD37BD37AThe lower byte of the pointer to the view of the map north of the current one. (?)
Item 48wMapConn2PtrD37CD37BMap connection 2 (?)
Item 48 quantitywSouthConnectionStripSrcD37DD37CThe upper byte of wSouthConnectionStripSrc (?)
Item 49wSouthConnectionStripSrcD37ED37DThe lower byte of wSouthConnectionStripSrc (?)
Item 49 quantitywSouthConnectionStripDestD37FD37EThe upper byte of the pointer to the map to the south of the current one.
Item 50wSouthConnectionStripDestD380D37FThe lower byte of the pointer to the map to the south of the current one.
Item 50 quantitywSouthConnectionStripWidthD381D380The width of the strip connecting to the map south of the current one. (?)
Item 51wSouthConnectedMapWidthD382D381The width of the map to the south of the current one.
Item 51 quantitywSouthConnectedMapYAlignmentD383D382The Y alignment of the map south of the current one.
Item 52wSouthConnectedMapXAlignmentD384D383The X alignment of the map to the south of the current one.
Item 52 quantitywSouthConnectedMapViewPointerD385D384The upper byte of the pointer to the view of the map south of the current one. (?)
Item 53wSouthConnectedMapViewPointerD386D385The lower byte of the pointer to the view of the map south of the current one. (?)
Item 53 quantitywMapConn3PtrD387D386Map connection 3 (?)
Item 54wWestConnectionStripSrcD388D387The upper byte of wWestConnectionStripSrc (?)
Item 54 quantitywWestConnectionStripSrcD389D388The lower byte of wWestConnectionStripSrc (?)
Item 55wWestConnectionStripDestD38AD389The upper byte of the pointer to the map to the west of the current one.
Item 55 quantitywWestConnectionStripDestD38BD38AThe lower byte of the pointer to the map to the west of the current one.
Item 56wWestConnectionStripHeightD38CD38BThe height of the strip connecting to the map west of the current one. (?)
Item 56 quantitywWestConnectedMapWidthD38DD38CThe width of the map to the west of the current one.
Item 57wWestConnectedMapYAlignmentD38ED38DThe Y alignment of the map west of the current one.
Item 57 quantitywWestConnectedMapXAlignmentD38FD38EThe X alignment of the map to the west of the current one.
Item 58wWestConnectedMapViewPointerD390D38FThe upper byte of the pointer to the view of the map west of the current one. (?)
Item 58 quantitywWestConnectedMapViewPointerD391D390The lower byte of the pointer to the view of the map west of the current one. (?)
Item 59wMapConn4PtrD392D391Map connection 4 (?)
Item 59 quantitywEastConnectionStripSrcD393D392The upper byte of wEastConnectionStripSrc (?)
Item 60wEastConnectionStripSrcD394D393The lower byte of wEastConnectionStripSrc (?)
Item 60 quantitywEastConnectionStripDestD395D394The upper byte of the pointer to the map to the east of the current one.
Item 61wEastConnectionStripDestD396D395The lower byte of the pointer to the map to the east of the current one.
Item 61 quantitywEastConnectionStripHeightD397D396The height of the strip connecting to the map east of the current one. (?)
Item 62wEastConnectedMapWidthD398D397The width of the map to the east of the current one.
Item 62 quantitywEastConnectedMapYAlignmentD399D398The Y alignment of the map east of the current one.
Item 63wEastConnectedMapXAlignmentD39AD399The X alignment of the map to the east of the current one.
Item 63 quantitywEastConnectedMapViewPointerD39BD39AThe upper byte of the pointer to the view of the map east of the current one. (?)
Item 64wEastConnectedMapViewPointerD39CD39BThe lower byte of the pointer to the view of the map east of the current one. (?)
Item 64 quantitywSpriteSetD39DD39CThe 1st of eleven identifiers for the sprite set in the current map.
Item 65wSpriteSetD39ED39DThe 2nd of eleven identifiers for the sprite set in the current map.
Item 65 quantitywSpriteSetD39FD39EThe 3rd of eleven identifiers for the sprite set in the current map.
Item 66wSpriteSetD3A0D39FThe 4th of eleven identifiers for the sprite set in the current map.
Item 66 quantitywSpriteSetD3A1D3A0The 5th of eleven identifiers for the sprite set in the current map.
Item 67wSpriteSetD3A2D3A1The 6th of eleven identifiers for the sprite set in the current map.
Item 67 quantitywSpriteSetD3A3D3A2The 7th of eleven identifiers for the sprite set in the current map.
Item 68wSpriteSetD3A4D3A3The 8th of eleven identifiers for the sprite set in the current map.
Item 68 quantitywSpriteSetD3A5D3A4The 9th of eleven identifiers for the sprite set in the current map.
Item 69wSpriteSetD3A6D3A5The 10th of eleven identifiers for the sprite set in the current map.
Item 69 quantitywSpriteSetD3A7D3A6The 11th of eleven identifiers for the sprite set in the current map.
Item 70wSpriteSetIDD3A8D3A7The sprite set ID for the current map.
Item 70 quantitywObjectDataPointerTempD3A9D3A8?
Item 71wObjectDataPointerTempD3AAD3A9?
Item 71 quantitywObjectDataPointerTempD3ABD3AA?
Item 72wObjectDataPointerTempD3ACD3AB?
Item 72 quantitywMapBackgroundTileD3ADD3ACThe tile shown outside the boundaries of the map
Item 73wNumberOfWarpsD3AED3ADNumber of warps in current map
Item 73 quantity-Item 128 quantitywWarpEntriesD3AF-D41DD3AE-D41CCurrent map warp entries
Item 129-256(copy of items 1-128)D31E-D41DD31D-D41CAforementioned addresses


Binary-coded decimal (BCD)

Binary-coded decimal is a system for encoding numbers in which hexadecimal values are read as their visual counterpart in decimal. For instance, $64 in BCD would be interpreted as 64, not 100. It is used most notably for storing the player's money. This means that a value such as $000200 (item 21 has quantity 0, item 22 is an Ultra Ball with quantity 0) will give the player 200 money.

Roaming items

This article is incomplete. Please feel free to add any missing information about the subject. It is missing: Index number.




Roaming items are simply map-specific items found in the expanded item pack. Their corresponding memory addresses are set every time the player enters a map. Since many of those data correspond to pointers, the kinds and quantities of those items are seemingly random, may vary between even similar versions (e.g. English Red and English Blue), and cover a wide range of both normal and glitch items.

The "roaming item area" begins with the quantity of item 37, wCurMapTileset, and it technically extends all the way to the quantity of item 128. However, some memory addresses in this area are left unset if they are unused for a certain map (like the data for a nonexistent map connection). In particular, none of the maps have enough warps to actually fill the item pack up to item 128, so for a large number of items, both the item ID and the quantity remains at 0. The sprite set is also only reloaded if it changed.

Modification of those memory addresses usually has no long-term effect (or no effect at all). As such, swapping those items with unimportant items in the normal inventory is a powerful way of getting glitch items.

  • List of roaming items for Blue

    This article or section is a stub. You can help wiki by [ expanding it].

    Categories