Author Topic: (PSX) FF7 - Battle animation index for playable characters?  (Read 17514 times)

Lazy Bastard

  • *
  • Posts: 290
  • I may be lazy, but I can...zzzZZZzzzZZZzzz...
    • View Profile
    • GameHacking.org
Re: (PSX) FF7 - Battle animation index for playable characters?
« Reply #25 on: 2013-04-19 21:17:04 »
I finally managed to spend at least a few minutes taking a look at another battle model (TIFA.LZS), though I still haven't had any time to modify anything and test the results. For interest's sake, here's Tifa's "Model Settings Data":


Model Settings Section [at offset 0x000073DC]:


Note: The byte size of the first (Unknown) sub-section of this section seems to be consistently 0x68 bytes.



Model Settings [at offset 0x000073DC]:


Unknown:

Code: [Select]
02 00 80 00 2C 01 00 07 00 07 00 00 00 00 E0 FC
7C FC 01 00 00 00 00 00 20 1B 03 00 03 16 0F 00
00 00 00 00 FC 03 00 00 FC 03 00 00 FC 03 00 00
FC 03 00 00 FC 03 00 00 FC 03 00 00 FC 03 00 00
FC 03 00 00 80 01 32 01 80 01 00 00 89 03 98 FC
77 FC 00 00 12 FE 00 00 7D 00 58 FD 06 FB 00 00
D2 FD 00 00 2C 01 00 00


Relative offsets (from the beginning of Model Settings Data) to animation scripts:

Code: [Select]
90 01 00 00
94 01 00 00
9C 01 00 00
A0 01 00 00
B0 01 00 00
C0 01 00 00
C4 01 00 00
CC 01 00 00
D0 01 00 00
D4 01 00 00
E4 01 00 00
E8 01 00 00
EC 01 00 00
F0 01 00 00
F4 01 00 00
00 02 00 00
FC 01 00 00
10 02 00 00
04 02 00 00
98 01 00 00
6C 02 00 00
88 02 00 00
6C 03 00 00
84 03 00 00
10 03 00 00
24 03 00 00
30 03 00 00
3C 03 00 00
4C 03 00 00
10 02 00 00
20 02 00 00
30 02 00 00
44 02 00 00
58 02 00 00
94 02 00 00
94 02 00 00
6C 02 00 00
88 02 00 00
B4 02 00 00
C4 02 00 00
D4 02 00 00
D4 02 00 00
EC 02 00 00
EC 02 00 00
04 03 00 00
04 03 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
90 01 00 00
9C 03 00 00
B4 03 00 00
C0 03 00 00
CC 03 00 00
D8 03 00 00
E4 03 00 00
F0 03 00 00
00 04 00 00
04 04 00 00
FC 03 00 00
90 01 00 00
94 03 00 00
90 01 00 00
90 01 00 00


Animation scripts:

Code: [Select]
-00 FE C0 00
-01 FE C0 00
-10 FE C0 00
-06 F1 00 00
-B3 F9 03 ED E3 EE B2 F9 03 B1 03 B1 E3 EE 00 00
-B3 F9 04 E4 E3 EE B2 F9 04 B0 04 B0 E3 EE 00 00
-0F F2 E5 EE
-10 11 F2 E5 EE 00 00 00
-12 F2 E5 EE
-05 E5 EE 00
-AB 90 01 00 00 08 F4 0F F3 FA E5 A6 EE 00 00 00
-13 E5 EE 00
-18 19 E5 EE
-B4 02 F1 00
-95 07 FE C0
-C4 90 01 06 07 FE C0 00
-04 FA E5 EE
-E7 00 F1 00
-E5 C4 90 01 06 12 E7 00 F1 00 00 00
-E8 FC 03 ED E6 EA 0C 0D EC 0E 04 FA E5 EE 00 00
-E8 FC 03 ED A4 EA 0C 0D EC 0E 04 FA E5 EE 00 00
-E8 FC 03 ED A5 EA 0C 0D EC F4 0F F3 0E 04 FA E5 EE 00 00 00
-E8 FC 03 ED D8 06 15 00 09 EA EB F4 0A F3 04 FA E5 EE 00 00
-E8 FC 03 ED D8 06 15 00 0A EA EB F4 0A F3 04 FA E5 EE 00 00
-FC F0 D8 00 1A 00 1A D1 2C 01 00 00 06 F0 1B BE 02 BE 08 C2 08 1E 1C FA F0 1D E5 EE
-FC 03 ED F7 12 22 04 FA E5 EE 00 00
-FC F0 D8 00 1A 00 1A D1 2C 01 00 00 06 F0 1B F7 04 D8 04 D6 02 16 F4 06 F3 1C FA F0 1D E5 EE 00
-E8 FC 03 ED F7 12 14 F4 3C F3 04 FA E5 EE 00 00
-E8 FC 03 ED F7 12 14 F4 5A F3 04 FA E5 EE 00 00
-FC F0 D8 00 1A 00 1A D1 2C 01 00 00 06 F0 1B F7 04 17 1C FA F0 1D E5 EE
-FC F0 D8 00 1A 00 1A D1 2C 01 00 00 06 F0 1B F7 08 1F 1C FA F0 1D E5 EE
-FC 03 ED 15 F7 01 04 FA E5 EE 00 00
-FC F0 D8 00 1A 00 1A D1 2C 01 00 00 04 F0 1B F7 02 1E 9E 00
-E5 BD 2C 01 00 00 F0 F7 06 20 9E 00
-E5 BD 2C 01 00 00 F0 F7 08 21 9E 00
-E5 BD 2C 01 00 00 F0 F7 02 1E 1C FA F0 1D E5 EE
-FC F0 D8 00 1A 00 1A CC 06 CB FF E8 03 FE FE 00 08 08 F0 1B 1E F7 03 F4 06 F3 1C FA F0 1D E5 EE
-FC F0 D8 00 1A 00 1A D1 2C 01 00 00 04 F0 1B BE 02 BE 08 C2 08 1E 9E 00
-BE 02 BE 08 C2 08 20 1C FA F0 1D E5 EE 00 00 00
-FA F0 1D E5 EE 00 00 00
-E8 FC 00 E0 EA F4 19 F3 EC 1A D1 2C 01 00 00 06 F0 1B 9D 00 2C 9E 00 00
-EA E5 BD 2C 01 00 00 F0 9D 01 2D 9E
-EA E5 BD 2C 01 00 00 F0 9D 02 2E 9E
-EA E5 BD 2C 01 00 00 F0 9D 03 2F 9E
-EA E5 BD 2C 01 00 00 F0 9D 04 30 9E
-EA E5 BD 2C 01 00 00 F0 9D 05 31 9E
-EA E5 BD 2C 01 00 00 F0 9D 06 32 9E
-00 00 00 00
-00 00 00 00
-00 00 00 00

nfitc1

  • *
  • Posts: 3011
  • I just don't know what went wrong.
    • View Profile
    • WM/PrC Blog
Re: (PSX) FF7 - Battle animation index for playable characters?
« Reply #26 on: 2013-04-20 00:31:56 »
Quote from: Lazy Bastard link=topic=14200.msg198620#msg198620

Note: The byte size of the first (Unknown) sub-section of this section seems to be consistently 0x68 bytes.

It is always 68h bytes.

I see a lot of opcodes that I recognize as per the topic I recently created. I was going to go in depth with some of it but I can't figure out a lot of the nuances of them so I'll have to go with vague interpretations of their effects.

C9 is a loop label
CA loops back to C9 while the magic effect thread is running.
C1 always loops back to the C9
E8 is of note as it is what loads the magic effect handler, but another code runs it later (I think)
EC (I think) is what runs the visual effect on the target after the initial animation.

The animate handlers are just all over the place, too. The game takes the index it's given and just goes wacky with it. They each have an independent visual and an effect visual. If I had my code in front of me I'd give some details.


nfitc1

  • *
  • Posts: 3011
  • I just don't know what went wrong.
    • View Profile
    • WM/PrC Blog
Re: (PSX) FF7 - Battle animation index for playable characters?
« Reply #28 on: 2013-04-22 16:50:13 »
Thanks for that, Akari. That adds to my notes nicely. Still a lot of unknowns. Here's a few more things:

Some codes share implementations:
9A & FB
B2 & C9 (B2 isn't a loop pointer though. I haven't found any indication that it's used)
BB, C0, CD, D2, D3, D9 & EF all run the same code that any value less than 8E would run as if they were animations.
EE & FF

I think Christopher's script might prove enlightening, too.