]> git.jsancho.org Git - lugaru.git/commitdiff
Fixed duplicated expressions in ifs
authorCôme Chilliet <come@chilliet.eu>
Fri, 25 Nov 2016 13:40:44 +0000 (21:40 +0800)
committerCôme Chilliet <come@chilliet.eu>
Fri, 25 Nov 2016 13:40:44 +0000 (21:40 +0800)
Source/Person.cpp

index 8bcf81e43f458aa76a694a8bab93c18e1efa2fc2..62796aa03a1736d92417ea956130d91df56bed38 100644 (file)
@@ -5275,7 +5275,7 @@ void Person::DoStuff()
         if (hasvictim) {
             if ((victim != this->shared_from_this()) && !victim->dead && (victim->aitype != passivetype) &&
                 (victim->aitype != searchtype) && (aitype != passivetype) &&
-                (aitype != searchtype) && (victim->id < Person::players.size()) && (aitype != passivetype)) {
+                (aitype != searchtype) && (victim->id < Person::players.size())) {
                 behind = (normaldotproduct(facing, coords - victim->coords) > 0);
             }
         }
@@ -6379,7 +6379,7 @@ int Person::DrawSkeleton()
     calcrot = 0;
     if (skeleton.free)
         calcrot = 1;
-    if (animation[animTarget].attack || isRun() || animTarget == staggerbackhardanim || isFlip() || animTarget == climbanim || animTarget == sneakanim || animTarget == rollanim || animTarget == walkanim || animTarget == backhandspringanim || isFlip() || isWallJump())
+    if (animation[animTarget].attack || isRun() || animTarget == staggerbackhardanim || isFlip() || animTarget == climbanim || animTarget == sneakanim || animTarget == rollanim || animTarget == walkanim || animTarget == backhandspringanim || isWallJump())
         calcrot = 1;
     if (animCurrent != animTarget)
         calcrot = 1;