User Tools

Site Tools


banjo_kazooie:animations

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
banjo_kazooie:animations [2024/11/26 14:32]
BanjoFreak64 [Element Header]
banjo_kazooie:animations [2024/11/26 16:27] (current)
BanjoFreak64 [Transform Structure]
Line 1: Line 1:
 ======== Animation Data ======== ======== Animation Data ========
  
-Banjo-Kazooie uses animation files comprised of a list of Internal Bone IDs, their transformation type (scale, rotate or translate), and across which frames of an animation these transformations occur. Animation indices can be found by searching ​the [[https://​hack64.net/​wiki/​doku.php?​id=banjo_kazooie:​rom_map | Rom Map]].+Banjo-Kazooie uses animation files comprised of a list of [[https://​hack64.net/​wiki/​doku.php?​id=banjo_kazooie:​model_data#​animation_setup:​~:​text=ii%20ii%5D-,​Internal%20Bone%20ID,​-0x000E|Internal Bone IDs]], their transformation type (scale, rotate or translate), and across which frames of an animation these transformations occur. Animation indices can be found in the [[https://​hack64.net/​wiki/​doku.php?​id=banjo_kazooie:​rom_map | Rom Map]].
  
  
Line 17: Line 17:
 ''<​color #​ed1c24>​00 0F</​color>​ <color #​ffaec9>​00 A5</​color>​ <color #​a800ff>​00 48</​color>​ 00 00''​ ''<​color #​ed1c24>​00 0F</​color>​ <color #​ffaec9>​00 A5</​color>​ <color #​a800ff>​00 48</​color>​ 00 00''​
  
-Loads an animation beginning at frame 15 (0x0F) and ending at frame 165 (0xA5) with 72 (0x48) elements across those frames.+Loads an animation beginning at frame 15 (<color #ed1c24>0x0F</​color>​) and ending at frame 165 (<color #ffaec9>0xA5</​color>​) with 72 (<color #a800ff>0x48</​color>​) elements across those frames.
  
  
Line 31: Line 31:
 ''<​color #​00c6ff>​00 1</​color><​color #​ff8a00>​0</​color>​ <color #​5724ff>​00 09</​color>''​ ''<​color #​00c6ff>​00 1</​color><​color #​ff8a00>​0</​color>​ <color #​5724ff>​00 09</​color>''​
  
-This element targets Internal Bone ID 0x1, rotates the bone around the X axis, and does this at 9 different points between frames 15 and 165.+This element targets Internal Bone ID 1 (<color #​00c6ff>​0x1</​color>​), rotates the bone around the X axis (<color #​ff8a00>​0x0</​color>​), and does this at 9 (<color #​5724ff>​0x9</​color>​) ​different points between frames 15 and 165.
  
 ^ *Transform Type ^ Value ^ ^ *Transform Type ^ Value ^
Line 44: Line 44:
 | Z Translation | 8 | | Z Translation | 8 |
 ===== Transform Structure ===== ===== Transform Structure =====
-Transform structure is repeated for instances [<color #​5724ff>​cc cc</​color>​] where <color #​5724ff>​cc cc</​color>​ = Data Count  from the preceding element header prior to introducing the next element header. The first two bytes of data contain two bitwise parameters ​representing unknown values and fourteen bits which determine the frame of each transformation.+The transform structure details the frames in which a transformation of the bone occurs and by how much the bone moves between frames with respect to the scale of the model (transform factor). ​Transform structure is repeated for instances [<color #​5724ff>​cc cc</​color>​] ​before introducing the next element header ​where [<color #​5724ff>​cc cc</​color>​] = [[https://​hack64.net/​wiki/​doku.php?​id=banjo_kazooie:​animations#​element_header:​~:​text=0x0004-,​%5Bcc%20cc%5D,​-Data%20Count|Data Count]]. The first two bytes of data contain two bits representing unknown values and fourteen bits which determine the frame of transformation.
  
-Bitwise Parameters:+*Bitwise Parameters:
  
-''​[<​color #​99d9ea>​D</​color><​color #​c3c3c3>​E</​color>​ <color #​22b14c>​FF FF FF FF FF FF FF</​color>​]''​+[<color #​ed1c24>​xx xx</​color>​] => ''​[<​color #​99d9ea>​D</​color><​color #​c3c3c3>​E</​color>​ <color #​22b14c>​FF FF FF FF FF FF FF</​color>​]''​
  
 | <color #​99d9ea>​D</​color>​ | Unknown 1 | | <color #​99d9ea>​D</​color>​ | Unknown 1 |
Line 54: Line 54:
 | <color #​22b14c>​FF FF FF FF FF FF FF</​color>​ | Frame of Transformation | | <color #​22b14c>​FF FF FF FF FF FF FF</​color>​ | Frame of Transformation |
  
-Following this information,​ the transformation factor ​can be found located at byte 0x2+So data for each transform structure ​can best be represented like this:
  
 ^ Offset from End of Element Header ^ Value / Syntax ^ Description ^ ^ Offset from End of Element Header ^ Value / Syntax ^ Description ^
-| 0x0002| [<color #​fff200>​gg gg</​color>​] | Transform Factor |+| 0x0000 | [<color #​ed1c24>​xx xx</​color>​] | *Bitwise Parameters for <color #​99d9ea>​Unk1</​color>,​ <color #​c3c3c3>​Unk2</​color>,​ and <color #​22b14c>​Frame of Transformation</​color>​ | 
 +| 0x0002 | [<color #​fff200>​gg gg</​color>​] | Transform Factor |
  
 **Example (60f0.bin, Banjo'​s Backflip at address 0x0C):** **Example (60f0.bin, Banjo'​s Backflip at address 0x0C):**
  
-''<​color #99d9ea>C</​color><​color #​22b14c>​0 ​0F</​color>​ <color #​fff200>​15 E6</​color>''​+''<​color #ed1c24>C0 0F</​color>​ <color #​fff200>​15 E6</​color>''​
  
-At frame 15 (0xF), ​transform ​by a factor of 87.59375 (0x15E6).+At frame 15 (<color #22b14c>0xF</​color>​), two bitwise parameters are set as true (if [<color #​99d9ea>​d</​color>​] = <color #​99d9ea>​1</​color>​ and [<color #​c3c3c3>​e</​color>​] = <color #​c3c3c3>​1</​color>,​ then the remaining two bits must return false to equal 0x<color #​ed1c24>​C</​color>​) and then the bone transforms ​by a factor of 87.59375 (<color #fff200>0x15E6</​color>​).
banjo_kazooie/animations.1732631540.txt.gz · Last modified: 2024/11/26 14:32 by BanjoFreak64