View Single Post
  #78    
Old March 3rd, 2013, 03:12 PM
knizz's Avatar
knizz
 
Join Date: Aug 2007
I think I didn't explain my earlier post properly. It is a list of commands for this animation-bytecode and the format of their arguments. "1C xxxx xx xx xx" = "The command 1C is followed by four arguments that are 2, 1, 1 and 1 bytes wide respectively."
I'll demonstrate it using this code by tajaros as example:
Spoiler:

Code:
00 E3 27 00 E4 27 00 E5 27 0A 00 0C 0C 08 02 24 7B 3E 08 02 05 01 00 02 00
00 00 04 00 00 00 05 03 41 E5 0A 08 02 04 00 00 3C 00 02 00 0C 00 19 CE 00
C0 04 1E 19 CE 00 C0 04 1E 19 CE 00 C0 02 D4 61 3E 08 02 01 00 00 04 19 19
CE 00 C0 04 14 19 CE 00 C0 04 0F 19 CE 00 C0 04 0A 04 06 1C CE 00 C0 06 05
05 02 04 62 3E 08 02 03 00 00 10 00 10 00 04 02 02 04 62 3E 08 02 03 00 00
F0 FF F0 FF 19 70 00 C0 05 02 24 7B 3E 08 02 05 01 00 04 00 04 00 00 00 00
00 0B 00 0D 00 97 27 02 50 35 3E 08 02 01 00 00 19 9B 00 C0 05 04 02 02 50
35 3E 08 02 01 01 00 05 03 D1 8C 09 08 02 05 00 00 02 00 00 00 04 00 01 00
03 F9 89 09 08 02 05 01 00 05 00 00 00 06 00 01 00 02 50 35 3E 08 02 01 02 
00 02 98 7C 3E 08 83 04 00 00 00 00 01 00 01 00 19 74 00 3F 05 08
Formatted code
Code:
00 27E3
00 27E4
00 27E5
0A 00
0C 080C
02 083E7B24 02 05
    0001
    0002
    0000
    0004
    0000
05
03 080AE541 02 04
    0000
    003C
    0002
    000C
19 00CE C0
04 1E
19 00CE C0
04 1E
19 00CE C0
02 083E61D4 02 01
    0000
04 19
19 00CE C0
04 14
19 00CE C0
04 0F
19 00CE C0
04 0A
04 06
1C 00CE C0 06 05
05
02 083E6204 02 03
    0000
    0010
    0010
04 02
02 083E6204 02 03
    0000
    FFF0
    FFF0
19 0070 C0
05
02 083E7B24 02 05
    0001
    0004
    0004
    0000
    0000
0B 00
0D
00 2797
02 083E3550 02 01
    0000
19 009B C0
05
04 02
02 083E3550 02 01
    0001
05
03 08098CD1 02 05
    0000
    0002
    0000
    0004
    0001
03 080989F9 02 05
    01 00
    05 00
    00 00
    06 00
    01 00
02 083E3550 02 01
    0002
02 083E7C98 83 04
    00 00
    00 00   
    01 00
    01 00
19 0074 3F
05
08
Arguments of the 02 command:
Code:
083E7B24: objtemplate
    unknown1  0000
    unknown2  0000
    oamdata   08231CE4 (=oam_empty)
    animtbl1  08231CF0 (=animtable_empty_1)
    gfxtbl    00000000
    animtbl2  08231CFC (=animtable_empty_2)
    callback  080B99D4
Code:
083E61D4: objtemplate
    unknown1  27E4
    unknown2  27E4
    oamdata   083ACB60
    animtbl1  08231CF0 (=animtable_empty_1)
    gfxtbl    00000000
    animtbl2  083E61C8
        [0] 083E6138
            0010 0010
            0000 0000
            0004 0004
            3C00 0000
            0100 0100
            0000 0000
            7FFD 0000
            0000 0000
            FFFC FFFC
            0500 0000
            0004 0004
            0500 0000
            7FFD 000A
            0000 0000
            7FFF 0000
            0000 0000
        [1] 083E6178
            0010 0010
            0000 0000
            0008 0008
            1E00 0000
            0100 0100
            0000 0000
            FFFC FFFC
            0500 0000
            0004 0004
            0500 0000
            7FFE 0003
            0000 0000
        [2] 083E61A8
            0010 0010
            0000 0000
            0008 0008
            1E00 0000
            FFF8 FFF8
            1E00 0000
            7FFF 0000
            0000 0000
    callback  080AE71C
Code:
083E6204: objtemplate
    unknown1  27E5
    unknown2  27E5
    oamdata   083AC9D8
    animtbl1  083E6200
        [0] 083E61EC
            0000 0003
            0010 0003
            0020 0003
            0030 0003
            FFFF 0000
    gfxtbl    00000000
    animtbl2  08231CFC (=animtable_empty_2)
    callback  080AE774
Code:
083E3550: objtemplate
    unknown1  0000
    unknown2  0000
    oamdata   08231CE4 (=oam_empty)
    animtbl1  08231CF0 (=animtable_empty_1)
    gfxtbl    00000000
    animtbl2  08231CFC (=animtable_empty_2)
    callback  080A5340
Code:
083E7C98: objtemplate
    unknown1  0x2797
    unknown2  0x2797
    oamdata   083ACA38
    animtbl1  08231CF0 (=animtable_empty_1)
    gfxtbl    00000000
    animtbl2  083E7BF8
        [0] 083E7BA0
            …
        [1] 083E7BB0
            …
        [2] 083E7BC8
            …
        [3] 083E7BE0
            …
    callback  080BA780
__________________
Firered IDA 6.1 DB: https://www.dropbox.com/s/hvvmxxoo1dkmdzc/firered.idb
VBA-M with lua scripting support (no longer in development)
Reply With Quote