From fa9b4636af8985a9e1574d6e08ac77e47eb72fe2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?C=C3=B4me=20Chilliet?= Date: Fri, 25 Nov 2016 21:40:44 +0800 Subject: [PATCH] Fixed duplicated expressions in ifs --- Source/Person.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Person.cpp b/Source/Person.cpp index 8bcf81e..62796aa 100644 --- a/Source/Person.cpp +++ b/Source/Person.cpp @@ -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; -- 2.39.5