浏览代码

* bug 1165 fixed

mateuszb 12 年之前
父节点
当前提交
4ae4b998a3
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7 0
      client/BattleInterface/CBattleAnimations.cpp

+ 7 - 0
client/BattleInterface/CBattleAnimations.cpp

@@ -705,6 +705,13 @@ bool CShootingAnimation::init()
 		return false;
 	}
 
+	//reverse unit if necessary
+	if (attackingStack && owner->curInt->cb->isToReverse(attackingStack->position, attackedStack->position, owner->creDir[attackingStack->ID], attackingStack->doubleWide(), owner->creDir[attackedStack->ID]))
+	{
+		owner->addNewAnim(new CReverseAnimation(owner, attackingStack, attackingStack->position, true));
+		return false;
+	}
+
 	// Create the projectile animation
 
 	double projectileAngle; //in radians; if positive, projectiles goes up