From 9e2e7f90abb05acea217c9dc575ecd33b0f38680 Mon Sep 17 00:00:00 2001 From: KiritoDv Date: Sun, 10 Mar 2024 19:52:26 -0600 Subject: Fixed error validation on sf64 anims --- src/factories/sf64/AnimFactory.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/factories/sf64/AnimFactory.cpp b/src/factories/sf64/AnimFactory.cpp index a57f1f2..f145f5e 100644 --- a/src/factories/sf64/AnimFactory.cpp +++ b/src/factories/sf64/AnimFactory.cpp @@ -11,7 +11,7 @@ SF64::AnimData::AnimData(int16_t frameCount, int16_t limbCount, uint32_t dataOff if((mDataOffset + sizeof(mFrameData) > mKeyOffset) && (mKeyOffset + sizeof(mJointKeys) > mDataOffset)) { throw std::runtime_error("Data and Key offsets overlap"); } - if(mJointKeys.size() != limbCount) { + if(mJointKeys.size() != limbCount + 1) { throw std::runtime_error("Joint Key count does not match Limb count"); } } -- cgit v1.2.3