Changes
From Final Fantasy Inside
no edit summary
This file was written by me, L. Spiro, as can be seen by the proper grammar and perfect spelling.
Part II: Functions and Format
This is a basic bit-reading function. It reads “dwTotalBits†from “pbBuffer†starting at the “dwStartBitâ€â€™th bit.
==== GetBitsFixed ====
1.
<code><pre>
Now that we can read the bits in the buffer we have made, it’s time to know what we’re doing!
===== A.=====
The animation data begins with one full frame that is uncompressed, but stored in one of 3 ways. Every frame after that is compressed, but compressed in one of three ways; one way can be decoded using the same method as on the first frame, which is why sometimes the second, third, and even fourth frames can be decoded using the same method as was used on the first frame.
First Frame:
==== GetDynamicFrameOffsetBits ====
The first frame is easy.
Remember that all frames after are stored as relative offsets from the frame before it.
</pre></code>
==== GetEncryptedRotationBits ====
Now all that is left is to decode the rotations.
Rotations change size in multiple ways.
After the function returns, we must translate the rotational INT values to their FLOAT forms (although the function can be modified to do this part itself).
This function will be called in a loop for every frame in the rotation.
==== LoadFrames ====
1.
</pre></code>
2.
==== A Sample Loop ====
This is an example loop that could be used to load a full animation.