summaryrefslogtreecommitdiffstats
path: root/src/animation/AnimBlendHierarchy.cpp
diff options
context:
space:
mode:
authoreray orçunus <erayorcunus@gmail.com>2020-06-22 03:02:44 +0200
committereray orçunus <erayorcunus@gmail.com>2020-06-22 03:20:56 +0200
commitf3ed6659c32ec61c2c4c806707655e0c58123e4c (patch)
tree1d71dd86ef08d87e4ed703302224d330cecf4ae2 /src/animation/AnimBlendHierarchy.cpp
parentkilling peds increase chaos level (diff)
downloadre3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.tar
re3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.tar.gz
re3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.tar.bz2
re3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.tar.lz
re3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.tar.xz
re3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.tar.zst
re3-f3ed6659c32ec61c2c4c806707655e0c58123e4c.zip
Diffstat (limited to 'src/animation/AnimBlendHierarchy.cpp')
-rw-r--r--src/animation/AnimBlendHierarchy.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/animation/AnimBlendHierarchy.cpp b/src/animation/AnimBlendHierarchy.cpp
index 7388352f..d3d6287a 100644
--- a/src/animation/AnimBlendHierarchy.cpp
+++ b/src/animation/AnimBlendHierarchy.cpp
@@ -44,7 +44,7 @@ CAnimBlendHierarchy::CalcTotalTime(void)
#endif
totalLength = Max(totalLength, sequences[i].GetKeyFrame(sequences[i].numFrames-1)->deltaTime);
- for(j = sequences[i].numFrames-1; j > 0; j--){
+ for(j = sequences[i].numFrames-1; j >= 1; j--){
KeyFrame *kf1 = sequences[i].GetKeyFrame(j);
KeyFrame *kf2 = sequences[i].GetKeyFrame(j-1);
kf1->deltaTime -= kf2->deltaTime;
@@ -66,7 +66,7 @@ CAnimBlendHierarchy::CalcTotalTimeCompressed(void)
#endif
totalLength = Max(totalLength, sequences[i].GetKeyFrameCompressed(sequences[i].numFrames-1)->deltaTime/60.0f);
- for(j = sequences[i].numFrames-1; j > 0; j--){
+ for(j = sequences[i].numFrames-1; j >= 1; j--){
KeyFrame *kf1 = sequences[i].GetKeyFrameCompressed(j);
KeyFrame *kf2 = sequences[i].GetKeyFrameCompressed(j-1);
kf1->deltaTime -= kf2->deltaTime;