Jump to content

GBA AR V3 Code Types


Recommended Posts

In spoiler fo convience.

            Normal RAM Write Codes

00aaaaaa xxxxxxyy    8-bit RAM Write/Fill            Fills the area from Address Rsh 1 to Address Rsh 1 + xxxxxx with yy.
02aaaaaa xxxxyyyy    16-bit RAM Write/Fill            Fills the area from Address Rsh 1 to Address Rsh 1 + xxxx * 2 with yyyy.
04aaaaaa yyyyyyyy    32-bit RAM Write            Writes yyyyyyyy to Address Rsh 1.

            Pointer RAM Write Codes

40aaaaaa xxxxxxyy    8-bit Pointer RAM Write            Writes yy to the address located in Address Rsh 1 + xxxxxx.
42aaaaaa xxxxyyyy    16-bit Pointer RAM Write        Writes yyyy to the address located in Address Rsh 1 + xxxx * 2.
44aaaaaa yyyyyyyy    32-bit Pointer RAM Write        Writes yyyyyyyy to the address located in Address Rsh 1.

            Add Codes

80aaaaaa 000000yy    8-bit Add Code                Adds yy to the byte stored at Address Rsh 1.
82aaaaaa 0000yyyy    16-bit Add Code                Adds yyyy to the halfword stored at Address Rsh 1.
84aaaaaa yyyyyyyy    32-bit Add Code                Adds yyyyyyyy to the word stored at Address Rsh 1.

            Write to IO Registers

C600aaaa 0000yyyy    16-bit IO Register Write        Writes yyyy to 0x0400aaaa.
C700aaaa yyyyyyyy    32-bit IO Register Write        Writes yyyyyyyy to 0x0400aaaa.

            If Equal To

08aaaaaa 000000yy    8-bit If Equal To (1 line)            Executes next code only if yy is equal to the byte stored at Address Rsh 1.
48aaaaaa 000000yy    8-bit If Equal To (2 lines)            Executes next two codes only if yy is equal to the byte stored at Address Rsh 1.
88aaaaaa 000000yy    8-bit If Equal To (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy is equal to the byte stored at Address Rsh 1.
C8aaaaaa 000000yy    8-bit If Equal To (Disable Codes)        All codes are disabled when the byte at Address Rsh 1 is not equal to yy.
0Aaaaaaa 0000yyyy    16-bit If Equal To (1 line)            Executes next code only if yy is equal to the halfword stored at Address Rsh 1.
4Aaaaaaa 0000yyyy    16-bit If Equal To (2 lines)            Executes next two codes only if yy is equal to the halfword stored at Address Rsh 1.
8Aaaaaaa 0000yyyy    16-bit If Equal To (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy is equal to the halfword stored at Address Rsh 1.
CAaaaaaa 0000yyyy    16-bit If Equal To (Disable Codes)        All codes are disabled when the halfword at Address Rsh 1 is not equal to yy.
0Caaaaaa yyyyyyyy    32-bit If Equal To (1 line)            Executes next code only if yy is equal to the word stored at Address Rsh 1.
4Caaaaaa yyyyyyyy    32-bit If Equal To (2 lines)            Executes next two codes only if yy is equal to the word stored at Address Rsh 1.
8Caaaaaa yyyyyyyy    32-bit If Equal To (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy is equal to the word stored at Address Rsh 1.
CCaaaaaa yyyyyyyy    32-bit If Equal To (Disable Codes)        All codes are disabled when the word at Address Rsh 1 is not equal to yy.

            If Not Equal To

10aaaaaa 000000yy    8-bit If not equal To (1 line)                Executes next code only if yy is not equal to the byte stored at Address Rsh 1.
50aaaaaa 000000yy    8-bit If not equal To (2 lines)                Executes next two codes only if yy is not equal to the byte stored at Address Rsh 1.
90aaaaaa 000000yy    8-bit If not equal To (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy is not equal to the byte stored at Address Rsh 1.
D0aaaaaa 000000yy    8-bit If not equal To (Disable Codes)            All codes are disabled when the byte at Address Rsh 1 is not not equal to yy.
12aaaaaa 0000yyyy    16-bit If not equal To (1 line)                Executes next code only if yy is not equal to the halfword stored at Address Rsh 1.
52aaaaaa 0000yyyy    16-bit If not equal To (2 lines)            Executes next two codes only if yy is not equal to the halfword stored at Address Rsh 1.
92aaaaaa 00000yyyy    16-bit If not equal To (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy is not equal to the halfword stored at Address Rsh 1.
D2aaaaaa 0000yyyy    16-bit If not equal To (Disable Codes)            All codes are disabled when the halfword at Address Rsh 1 is not not equal to yy.
14aaaaaa yyyyyyyy    32-bit If not equal To (1 line)                Executes next code only if yy is not equal to the word stored at Address Rsh 1.
54aaaaaa yyyyyyyy    32-bit If not equal To (2 lines)            Executes next two codes only if yy is not equal to the word stored at Address Rsh 1.
94aaaaaa yyyyyyyy    32-bit If not equal To (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy is not equal to the word stored at Address Rsh 1.
D4aaaaaa yyyyyyyy    32-bit If not equal To (Disable Codes)            All codes are disabled when the word at Address Rsh 1 is not not equal to yy.

            If less than (signed)

18aaaaaa 000000yy    8-bit If less than (signed) (1 line)            Executes next code only if yy is less than (signed) the byte stored at Address Rsh 1.
58aaaaaa 000000yy    8-bit If less than (signed) (2 lines)            Executes next two codes only if yy is less than (signed) the byte stored at Address Rsh 1.
98aaaaaa 000000yy    8-bit If less than (signed) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is less than (signed) the byte stored at Address Rsh 1.
D8aaaaaa 000000yy    8-bit If less than (signed) (Disable Codes)        All codes are disabled when the byte at Address Rsh 1 is not less than (signed) yy.
1Aaaaaaa 0000yyyy    16-bit If less than (signed) (1 line)            Executes next code only if yy is less than (signed) the halfword stored at Address Rsh 1.
5Aaaaaaa 0000yyyy    16-bit If less than (signed) (2 lines)            Executes next two codes only if yy is less than (signed) the halfword stored at Address Rsh 1.
9Aaaaaaa 0000yyyy    16-bit If less than (signed) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is less than (signed) the halfword stored at Address Rsh 1.
DAaaaaaa 0000yyyy    16-bit If less than (signed) (Disable Codes)        All codes are disabled when the halfword at Address Rsh 1 is not less than (signed) yy.
1Caaaaaa yyyyyyyy    32-bit If less than (signed) (1 line)            Executes next code only if yy is less than (signed) the word stored at Address Rsh 1.
5Caaaaaa yyyyyyyy    32-bit If less than (signed) (2 lines)            Executes next two codes only if yy is less than (signed) the word stored at Address Rsh 1.
9Caaaaaa yyyyyyyy    32-bit If less than (signed) (Multi-line        All subsequent codes until the z20 code type or end of code list are executed only if yy is less than (signed) the word stored at Address Rsh 1.
DCaaaaaa yyyyyyyy    32-bit If less than (signed) (Disable Codes)        All codes are disabled when the word at Address Rsh 1 is not less than (signed) yy.

            If greater than (signed)

20aaaaaa 000000yy    8-bit If greater than (signed) (1 line)            Executes next code only if yy is greater than (signed) the byte stored at Address Rsh 1.
60aaaaaa 000000yy    8-bit If greater than (signed) (2 lines)        Executes next two codes only if yy is greater than (signed) the byte stored at Address Rsh 1.
A0aaaaaa 000000yy    8-bit If greater than (signed) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is greater than (signed) the byte stored at Address Rsh 1.
E0aaaaaa 000000yy    8-bit If greater than (signed) (Disable Codes)        All codes are disabled when the byte at Address Rsh 1 is not greater than (signed) yy.
21aaaaaa 0000yyyy    16-bit If greater than (signed) (1 line)        Executes next code only if yy is greater than (signed) the halfword stored at Address Rsh 1.
61aaaaaa 0000yyyy    16-bit If greater than (signed) (2 lines)        Executes next two codes only if yy is greater than (signed) the halfword stored at Address Rsh 1.
A1aaaaaa 0000yyyy    16-bit If greater than (signed) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is greater than (signed) the halfword stored at Address Rsh 1.
E1aaaaaa 0000yyyy    16-bit If greater than (signed) (Disable Codes)        All codes are disabled when the halfword at Address Rsh 1 is not greater than (signed) yy.
22aaaaaa yyyyyyyy    32-bit If greater than (signed) (1 line)        Executes next code only if yy is greater than (signed) the word stored at Address Rsh 1.
62aaaaaa yyyyyyyy    32-bit If greater than (signed) (2 lines)        Executes next two codes only if yy is greater than (signed) the word stored at Address Rsh 1.
A2aaaaaa yyyyyyyy    32-bit If greater than (signed) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is greater than (signed) the word stored at Address Rsh 1.
E2aaaaaa yyyyyyyy    32-bit If greater than (signed) (Disable Codes)        All codes are disabled when the word at Address Rsh 1 is not greater than (signed) yy.

            If less than (unsigned)

28aaaaaa 000000yy    8-bit If less than (unsigned) (1 line)            Executes next code only if yy is less than (unsigned) the byte stored at Address Rsh 1.
68aaaaaa 000000yy    8-bit If less than (unsigned) (2 lines)            Executes next two codes only if yy is less than (unsigned) the byte stored at Address Rsh 1.
A8aaaaaa 000000yy    8-bit If less than (unsigned) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is less than (unsigned) the byte stored at Address Rsh 1.
E8aaaaaa 000000yy    8-bit If less than (unsigned) (Disable Codes)        All codes are disabled when the byte at Address Rsh 1 is not less than (unsigned) yy.
2Aaaaaaa 0000yyyy    16-bit If less than (unsigned) (1 line)            Executes next code only if yy is less than (unsigned) the halfword stored at Address Rsh 1.
6Aaaaaaa 0000yyyy    16-bit If less than (unsigned) (2 lines)        Executes next two codes only if yy is less than (unsigned) the halfword stored at Address Rsh 1.
AAaaaaaa 0000yyyy    16-bit If less than (unsigned) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is less than (unsigned) the halfword stored at Address Rsh 1.
EAaaaaaa 0000yyyy    16-bit If less than (unsigned) (Disable Codes)        All codes are disabled when the halfword at Address Rsh 1 is not less than (unsigned) yy.
2Caaaaaa yyyyyyyy    32-bit If less than (unsigned) (1 line)            Executes next code only if yy is less than (unsigned) the word stored at Address Rsh 1.
6Caaaaaa yyyyyyyy    32-bit If less than (unsigned) (2 lines)        Executes next two codes only if yy is less than (unsigned) the word stored at Address Rsh 1.
ACaaaaaa yyyyyyyy    32-bit If less than (unsigned) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is less than (unsigned) the word stored at Address Rsh 1.
ECaaaaaa yyyyyyyy    32-bit If less than (unsigned) (Disable Codes)        All codes are disabled when the word at Address Rsh 1 is not less than (unsigned) yy.

            If greater than (unsigned)

30aaaaaa 000000yy    8-bit If greater than (unsigned) (1 line)        Executes next code only if yy is greater than (unsigned) the byte stored at Address Rsh 1.
70aaaaaa 000000yy    8-bit If greater than (unsigned) (2 lines)        Executes next two codes only if yy is greater than (unsigned) the byte stored at Address Rsh 1.
B0aaaaaa 000000yy    8-bit If greater than (unsigned) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is greater than (unsigned) the byte stored at Address Rsh 1.
F0aaaaaa 000000yy    8-bit If greater than (unsigned) (Disable Codes)    All codes are disabled when the byte at Address Rsh 1 is not greater than (unsigned) yy.
32aaaaaa 0000yyyy    16-bit If greater than (unsigned) (1 line)        Executes next code only if yy is greater than (unsigned) the halfword stored at Address Rsh 1.
72aaaaaa 0000yyyy    16-bit If greater than (unsigned) (2 lines)        Executes next two codes only if yy is greater than (unsigned) the halfword stored at Address Rsh 1.
B2aaaaaa 00000yyyy    16-bit If greater than (unsigned) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is greater than (unsigned) the halfword stored at Address Rsh 1.
F2aaaaaa 0000yyyy    16-bit If greater than (unsigned) (Disable Codes)    All codes are disabled when the halfword at Address Rsh 1 is not greater than (unsigned) yy.
34aaaaaa yyyyyyyy    32-bit If greater than (unsigned) (1 line)        Executes next code only if yy is greater than (unsigned) the word stored at Address Rsh 1.
74aaaaaa yyyyyyyy    32-bit If greater than (unsigned) (2 lines)        Executes next two codes only if yy is greater than (unsigned) the word stored at Address Rsh 1.
B4aaaaaa yyyyyyyy    32-bit If greater than (unsigned) (Multi-line)        All subsequent codes until the z20 code type or end of code list are executed only if yy is greater than (unsigned) the word stored at Address Rsh 1.
F4aaaaaa yyyyyyyy    32-bit If greater than (unsigned) (Disable Codes)    All codes are disabled when the word at Address Rsh 1 is not greater than (unsigned) yy.

            If AND

38aaaaaa 000000yy    8-bit If AND (1 line)                Executes next code only if yy AND the byte stored at Address Rsh 1 is not equal to 0.
78aaaaaa 000000yy    8-bit If AND (2 lines)                Executes next two codes only if yy AND the byte stored at Address Rsh 1 is not equal to 0.
B8aaaaaa 000000yy    8-bit If AND (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy AND the byte stored at Address Rsh 1 is not equal to 0.
F8aaaaaa 000000yy    8-bit If AND (Disable Codes)            All codes are disabled when the byte at Address Rsh 1 AND yy is 00.
39aaaaaa 0000yyyy    16-bit If AND (1 line)                Executes next code only if yy AND the halfword stored at Address Rsh 1 is not equal to 0.
79aaaaaa 0000yyyy    16-bit If AND (2 lines)                Executes next two codes only if yy AND the halfword stored at Address Rsh 1 is not equal to 0.
B9aaaaaa 00000yyyy    16-bit If AND (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy AND the halfword stored at Address Rsh 1 is not equal to 0.
F9aaaaaa 0000yyyy    16-bit If AND (Disable Codes)            All codes are disabled when the halfword at Address Rsh 1 AND yy is 00.
3Aaaaaaa yyyyyyyy    32-bit If AND (1 line)                Executes next code only if yy AND the word stored at Address Rsh 1 is not equal to 0.
7Aaaaaaa yyyyyyyy    32-bit If AND (2 lines)                Executes next two codes only if yy AND the word stored at Address Rsh 1 is not equal to 0.
BAaaaaaa yyyyyyyy    32-bit If AND (Multi-line)            All subsequent codes until the z20 code type or end of code list are executed only if yy AND the word stored at Address Rsh 1 is not equal to 0.
FAaaaaaa yyyyyyyy    32-bit If AND (Disable Codes)            All codes are disabled when the word at Address Rsh 1 AND yy is 00.

            Always... codes
0Eaaaaaa xxxxxxxx    Always skip next line
4Eaaaaaa xxxxxxxx    Always skip next two lines
8Eaaaaaa xxxxxxxx    Always skip remaining codes
CEaaaaaa xxxxxxxx    Always skip all codes

            One line special codes
00000000 00000000    End of code list                No codes after this point are executed.

00000000 0800xx00    Slowdown code                    The AR performs xx loops per code cycle, slowing the game down.

            Two line special codes
00000000 10aaaaaa
000000xx 00000000    8-bit AR Button RAM Write            Writes xx to Address Rsh 1 when the AR Button is pressed.

00000000 12aaaaaa
0000xxxx 00000000    16-bit AR Button RAM Write            Writes xxxx to Address Rsh 1 when the AR Button is pressed.

00000000 14aaaaaa
xxxxxxxx 00000000    32-bit AR Button RAM Write            Writes xxxxxxxx to Address Rsh 1 when the AR Button is pressed.

00000000 18aaaaaa
0000xxxx 00000000    16-bit ROM Patch                Patches 0x08000000 + (Address Rsh 1 >> 2) with xxxx.

00000000 1Aaaaaaa
0000xxxx 00000000    16-bit ROM Patch                Patches 0x08000000 + (Address Rsh 1 >> 2) with xxxx.

00000000 1Caaaaaa
0000xxxx 00000000    16-bit ROM Patch                Patches 0x08000000 + (Address Rsh 1 >> 2) with xxxx.

00000000 1Eaaaaaa
0000xxxx 00000000    16-bit ROM Patch                Patches 0x08000000 + (Address Rsh 1 >> 2) with xxxx.

00000000 40000000    Execute codes normally            All conditionals currently going on do not apply after this point.
00000000 60000000    Execute all following codes        All following codes are executed regardless of anything else.

00000000 80aaaaaa
000000xx vvddiiii    8-bit slide code            Writes dd bytes, starting at the address Address Rsh 1 with the value xx and incrementing the address by iiii and the value by vv each iteration.

00000000 82aaaaaa
0000xxxx vvddiiii    16-bit slide code            Writes dd halfwords, starting at the address Address Rsh 1 with the value xxxx and incrementing the address by iiii * 2 and the value by vv each iteration.

00000000 84aaaaaa
xxxxxxxx vvddiiii
80000000 00000000    32-bit slide code            Writes dd words, starting at the address Address Rsh 1 with the value xxxxxxxx and incrementing the address by iiii * 4 and the value by vv each iteration. The final line is needed to prevent a bug in the AR from occurring.

            Special Codes

C4aaaaaa 00000bcd    Master Code                Hooks the address 08aaaaaa for the code handler. if b is 1, the AR switch must be turned off when the game starts. Otherwise, it doesn't matter. c determines the number of codes the AR processes at a time. d is the type of hook. 0 is BL and 1 is Push LR then BL.

xxxxxxxx 001DC0DE    ID Code                    Used by the AR to auto-detect games. xxxxxxxx should be the word at 0x080000AC.    --

DEADFACE xxxxxxxx    DEADFACE                Changes the encryption seeds.


Action Replay V3 Conditional Codes - iiaaaaaa zzzzzzzz

The 'ii' is composed of <cond> + <value> + <action>.
  <cond>        <value>        <action>
  08 Equal =        00 8bit zz        00 execute next code
  10 Not equal <>    02 16bit zzzz        40 execute next two codes
  18 Signed <        04 32bit zzzzzzzz    80 execute all followingcodes until ELSE or ENDIF
  20 Signed >        06 (always false)    C0 normal ELSE turn off all codes
  30 Unsigned >
  28 Unsigned <                      
  38 Logical AND

Edited by Delta Blast Burn
  • Like 1
Link to comment
Share on other sites

  • 6 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...