mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-12-23 08:38:52 -05:00
d24c8453db
subrepo: subdir: "libultraship" merged: "a484cda98" upstream: origin: "https://github.com/HarbourMasters/libultraship.git" branch: "main" commit: "a484cda98" git-subrepo: version: "0.4.1" origin: "???" commit: "???"
29 lines
776 B
C++
29 lines
776 B
C++
#include "Skeleton.h"
|
|
|
|
namespace Ship
|
|
{
|
|
void SkeletonV0::ParseFileBinary(BinaryReader* reader, Resource* res)
|
|
{
|
|
Skeleton* skel = (Skeleton*)res;
|
|
|
|
ResourceFile::ParseFileBinary(reader, skel);
|
|
|
|
skel->type = (SkeletonType)reader->ReadByte();
|
|
skel->limbType = (LimbType)reader->ReadByte();
|
|
|
|
skel->limbCount = reader->ReadUInt32();
|
|
skel->dListCount = reader->ReadUInt32();
|
|
|
|
skel->limbTableType = (LimbType)reader->ReadByte();
|
|
|
|
uint32_t limbTblCnt = reader->ReadUInt32();
|
|
skel->limbTable.reserve(limbTblCnt);
|
|
|
|
for (uint32_t i = 0; i < limbTblCnt; i++)
|
|
{
|
|
std::string limbPath = reader->ReadString();
|
|
|
|
skel->limbTable.push_back(limbPath);
|
|
}
|
|
}
|
|
} |