举个例子 : Type E3(代码类型) 3.0.3.1.x (数字代码类型): 00XXXXXX : (如00000130 -> C7000130) ZZZZZZZZ : 将数据 ZZZZZZZZ 写到地址 $4XXXXXX($符号表示后面的值是一个十六进制数)
3.0.3.1.x (16进制加代码类型解释): 第一个字符 3 = 数据大小,这里的Z表示数据,类型E3有8位16进制数占用4字节,所以用计算机里的3表示(0、1、2、3); 第二个字符 0 = 代码类型(0 到 7); 第三个字符 3 = 代码子类型(0 到 3); 第四个字符 1 = 特殊位(0 到 1); 第五个字符 x = 未使用位(0 到 3)。
3.0.3.1.0 转化为2进制 = 11.000.11.1.00
将其反转并拼接在一起 : 00.1.11.000.11 = 0011100011(2进制) = E3(16进制) = 代码类型.
I choose to take this numbering to make it that the Ram 8bits write (Type 0), Ram 16bits write Type 1 andRam 32bits write (Type 2) have the same type number than for AR/GS V1/2. Moreover, If I didn't "reverse" the numbers, we've gotten almost only even code type number, which, IMHO, sounds really strange...
0.0.0.x.x
Fill area (XXXXXXXX) to (XXXXXXXX+YYYYYY) with Byte ZZ.
注意这里的(XXXXXXXX)指代的是原始代码地址02024EA4,意思是用字节 ZZ 将从(02024EA4)到(02024EA4+YYYYYY)的地址区域填满。
YYYYYYZZ(中间代码右边)
1.0.0.x.x
Fill area (XXXXXXXX) to (XXXXXXXX+YYYY*2) with Halfword ZZZZ.
YYYYZZZZ
2.0.0.x.x
Write the Word ZZZZZZZZ to address XXXXXXXX.
ZZZZZZZZ
0.0.1.x.x
Writes Byte ZZ to ([the address kept in XXXXXXXX]+[YYYYYY]).
YYYYYYZZ
1.0.1.x.x
Writes Halfword ZZZZ ([the address kept in XXXXXXXX]+[YYYY*2]).
YYYYZZZZ
2.0.1.x.x
Writes the Word ZZZZZZZZ to [the address kept in XXXXXXXX].
ZZZZZZZZ
0.0.2.x.x
Add the Byte ZZ to the Byte stored in XXXXXXXX.
000000ZZ
1.0.2.x.x
Add the Halfword ZZZZ to the Halfword stored in XXXXXXXX.
0000ZZZZ
2.0.2.x.x
Add the Word ZZZZ to the Halfword stored in XXXXXXXX.
ZZZZZZZZ
3.0.3.0.x
Write the Halfword ZZZZ to the address $4XXXXXX
0000ZZZZ
3.0.3.1.x
Write the Word ZZZZZZZZ to the address $4XXXXXX
ZZZZZZZZ
0.1.0.x.x
If Byte at XXXXXXXX = ZZ then execute next code.
000000ZZ
0.1.1.x.x
If Byte at XXXXXXXX = ZZ then execute next 2 codes.
000000ZZ
0.1.2.x.x
If Byte at XXXXXXXX = ZZ execute all the codes below this one in the same row (else execute none of the codes below).
000000ZZ
0.1.3.x.x
While Byte at XXXXXXXX <> ZZ turn off all codes.
000000ZZ
1.1.0.x.x
If Halfword at XXXXXXXX = ZZZZ then execute next code.
0000ZZZZ
1.1.1.x.x
If Halfword at XXXXXXXX = ZZZZ then execute next 2 codes.
0000ZZZZ
1.1.2.x.x
If Halfword at XXXXXXXX = ZZZZ execute all the codes below this one in the same row (else execute none of the codes below).
0000ZZZZ
1.1.3.x.x
While Halfword at XXXXXXXX <> ZZZZ turn off all codes.
0000ZZZZ
2.1.0.x.x
If Word at XXXXXXXX = ZZZZZZZZ then execute next code.
ZZZZZZZZ
2.1.1.x.x
If Word at XXXXXXXX = ZZZZZZZZ then execute next 2 codes.
ZZZZZZZZ
2.1.2.x.x
If Word at XXXXXXXX = ZZZZZZZZ execute all the codes below this one in the same row (else execute none of the codes below).
ZZZZZZZZ
2.1.3.x.x
While Word at XXXXXXXX <> ZZZZZZZZ turn off all codes.
ZZZZZZZZ
0.2.0.x.x
If Byte at XXXXXXXX <> ZZ then execute next code.
000000ZZ
0.2.1.x.x
If Byte at XXXXXXXX <> ZZ then execute next 2 codes.
000000ZZ
0.2.2.x.x
If Byte at XXXXXXXX <> ZZ execute all the codes below this one in the same row (else execute none of the codes below).
000000ZZ
0.2.3.x.x
While Byte at XXXXXXXX = ZZ turn off all codes.
000000ZZ
1.2.0.x.x
If Halfword at XXXXXXXX <> ZZZZ then execute next code.
0000ZZZZ
1.2.1.x.x
If Halfword at XXXXXXXX <> ZZZZ then execute next 2 codes.
0000ZZZZ
1.2.2.x.x
If Halfword at XXXXXXXX <> ZZZZ disable all the codes below this one.
0000ZZZZ
1.2.3.x.x
While Halfword at XXXXXXXX = ZZZZ turn off all codes.
0000ZZZZ
2.2.0.x.x
If Word at XXXXXXXX <> ZZZZZZZZ then execute next code.
ZZZZZZZZ
2.2.1.x.x
If Word at XXXXXXXX <> ZZZZZZZZ then execute next 2 codes.
ZZZZZZZZ
2.2.2.x.x
If Word at XXXXXXXX <> ZZZZZZZZ disable all the codes below this one.
ZZZZZZZZ
2.2.3.x.x
While Word at XXXXXXXX = ZZZZZZZZ turn off all codes.
ZZZZZZZZ
0.3.0.x.x
If ZZ > Byte at XXXXXXXX then execute next code.
000000ZZ
0.3.1.x.x
If ZZ > Byte at XXXXXXXX then execute next 2 codes.
000000ZZ
0.3.2.x.x
If ZZ > Byte at XXXXXXXX then execute all following codes in the same row (else execute none of the codes below).
000000ZZ
0.3.3.x.x
While ZZ <= Byte at XXXXXXXX turn off all codes.
000000ZZ
1.3.0.x.x
If ZZZZ > Halfword at XXXXXXXX then execute next line.
1.3.1.x.x
If ZZZZ > Halfword at XXXXXXXX then execute next 2 lines.
1.3.2.x.x
If ZZZZ > Halfword at XXXXXXXX then execute all following codes in the same row (else execute none of the codes below).
1.3.3.x.x
While ZZZZ <= Halfword at XXXXXXXX turn off all codes.
2.3.0.x.x
If ZZZZZZZZ > Word at XXXXXXXX then execute next line.
2.3.1.x.x
If ZZZZZZZZ > Word at XXXXXXXX then execute next 2 lines.
2.3.2.x.x
If ZZZZZZZZ > HWord at XXXXXXXX then execute all following codes in the same row (else execute none of the codes below).
2.3.3.x.x
While ZZZZZZZZ <= Word at XXXXXXXX turn off all codes.
0.4.0.x.x , 0.6.0.x.x
If ZZ < Byte at XXXXXXXX then execute next code.
000000ZZ
0.4.1.x.x
If ZZ < Byte at XXXXXXXX then execute next 2 codes.
000000ZZ
0.4.2.x.x , 0.6.2.x.x
If ZZ < Byte at XXXXXXXX then execute all following codes in the same row (else execute none of the codes below).
000000ZZ
0.4.3.x.x
While ZZ => Byte at XXXXXXXX turn off all codes.
000000ZZ
1.4.0.x.x, 1.6.0.x.x
If ZZZZ < Halfword at XXXXXXXX then execute next line.
If ZZZZ < Halfword at XXXXXXXX then execute next 2 lines.
If ZZZZ < Halfword at XXXXXXXX then execute all following codes in the same row (else execute none of the codes below).
0.7.0.x.x
If ZZ AND Byte at XXXXXXXX <> 0 (= True) then execute next code.
000000ZZ
0.7.1.x.x
If ZZ AND Byte at XXXXXXXX <> 0 (= True) then execute next 2 codes.
000000ZZ
0.7.2.x.x
If ZZ AND Byte at XXXXXXXX <> 0 (= True) then execute all following codes in the same row (else execute none of the codes below).
000000ZZ
0.7.3.x.x
While ZZ AND Byte at XXXXXXXX = 0 (= False) then turn off all codes.
000000ZZ
1.7.0.x.x
If ZZZZ AND Halfword at XXXXXXXX <> 0 (= True) then execute next code.
0000ZZZZ
1.7.1.x.x
If ZZZZ AND Halfword at XXXXXXXX <> 0 (= True) then execute next 2 codes.
0000ZZZZ
1.7.2.x.x
If ZZZZ AND Halfword at XXXXXXXX <> 0 (= True) then execute all following codes in the same row (else execute none of the codes below).
0000ZZZZ
1.7.3.x.x
While ZZZZ AND Halfword at XXXXXXXX = 0 (= False) then turn off all codes.
0000ZZZZ
2.7.0.x.x
If ZZZZZZZZ AND Word at XXXXXXXX <> 0 (= True) then execute next code.
ZZZZZZZZ
2.7.1.x.x
If ZZZZZZZZ AND Word at XXXXXXXX <> 0 (= True) then execute next 2 codes.
ZZZZZZZZ
2.7.2.x.x
If ZZZZZZZZ AND Word at XXXXXXXX <> 0 (= True) then execute all following codes in the same row (else execute none of the codes below).
ZZZZZZZZ
2.7.3.x.x
While ZZZZZZZZ AND Word at XXXXXXXX = 0 (= False) then turn off all codes.
ZZZZZZZZ
0.0.0.0.0
x.1.0.x.x
0.2.0.x.x
Writes Byte ZZ to address XXXXXXXX when AR button is pushed.
000000ZZ
1.2.0.x.x
Writes Halfword ZZZZ to address XXXXXXXX.
0000ZZZZ
2.2.0.x.x
Writes Word ZZZZZZZZ to address XXXXXXXX.
ZZZZZZZZ
0.3.0.x.x
Patches ROM address (XXXXXXXX << 1) with Halfword ZZZZ.
0000ZZZZ
1.3.0.x.x
Patches ROM address (XXXXXXXX << 1) with Halfword ZZZZ. Does not work on V1/2 upgraded to V3. Only for a real V3 Hardware?
0000ZZZZ
2.3.0.x.x
Patches ROM address (XXXXXXXX << 1) with Halfword ZZZZ. Does not work on V1/2 upgraded to V3. Only for a real V3 Hardware?
0000ZZZZ
3.3.0.x.x
Patches ROM address (XXXXXXXX << 1) with Halfword ZZZZ. Does not work on V1/2 upgraded to V3. Only for a real V3 Hardware?
0000ZZZZ
x.0.1.x.x
(SP = 0) (means : stops the "then execute all following codes in the same row" and stops the "else execute none of the codes below)".
00000000
x.4.1.x.x
(If SP <> 2 -> SP = 1) (means : start to execute all codes until end of codes or SP = 0). (bypass the number of codes to executes set by the master code).
00000000
0.0.2.x.x
Writes Byte YY at address XXXXXXXX. Then makes YY = YY + Z1, XXXXXXXX = XXXXXXXX + Z3Z3, Z2 = Z2 - 1, and repeats until Z2 < 0.
000000YY
Z1Z2Z3Z3
1.0.2.x.x
Writes Halfword YYYY at address XXXXXXXX. Then makes YYYY = YYYY + Z1, XXXXXXXX = XXXXXXXX + Z3Z3*2,
0000YYYY
Z1Z2Z3Z3
2.0.2.x.x
Writes Word YYYYYYYY at address XXXXXXXX. Then makes YYYYYYYY = YYYYYYYY + Z1, XXXXXXXX = XXXXXXXX + Z3Z3*4, Z2 = Z2 - 1, and repeats until Z2<0.
YYYYYYYY
Z1Z2Z3Z3
Type 62
2.0.3.x.x
Master Code settings.
0000YYYY
Type 62
2.0.3.x.x
Must always be 001DC0DE
001DC0DE
New Encryption seed.
0000XXXX
SP = 0 : normal (execute n codes before giving back the hand to the game). SP = 1 : execute all codes until SP <>1 (or end of codes). SP = 2 : don't execute anymore codes. Each time the GSA starts to execute codes (= each time "it has the hand"), SP = 0. The 'execute all the codes below this one in the same row' makes SP = 1. The '(else execute none of the codes below)' makes SP = 2. The 'turn off all codes' makes an infinite loop (that can't be broken, unless the condition becomes True).