Torch
Loading...
Searching...
No Matches
BK64::CollisionHeader Struct Reference

#include <ModelFactory.h>

Public Attributes

int16_t minIndex [3]
int16_t maxIndex [3]
uint16_t yStride
uint16_t zStride
uint16_t geoCubeScale

Detailed Description

CollisionHeader: the grid parameters for collision lookups. Decomp: BKCollisionList from model.h

Structure Layout (decomp field names): Offset 0x00: unk0[3] (s16[3]) - min[X,Y,Z] Offset 0x06: unk6[3] (s16[3]) - max[X,Y,Z] Offset 0x0C: unkC (s16) - y_stride Offset 0x0E: unkE (s16) - z_stride Offset 0x10: unk10 (s16) - geo_cnt (we calculate from vector.size()) Offset 0x12: unk12 (s16) - scale Offset 0x14: unk14 (s16) - tri_cnt (we calculate from vector.size())

Grid Cell Calculation: cubeX = (worldX - minX) / geoCubeScale cubeY = (worldY - minY) / geoCubeScale cubeZ = (worldZ - minZ) / geoCubeScale cubeIndex = cubeX + cubeY * yStride + cubeZ * yStride * zStride


The documentation for this struct was generated from the following file: