From cb3dce698c3903f180bfe4a19fca287d3affeea6 Mon Sep 17 00:00:00 2001 From: uruk Date: Sun, 22 Jun 2014 14:10:23 +0200 Subject: CGE2: Rework Hero::len(). --- engines/cge2/hero.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engines/cge2/hero.cpp') diff --git a/engines/cge2/hero.cpp b/engines/cge2/hero.cpp index 5e075d8fa2..fdec752ed2 100644 --- a/engines/cge2/hero.cpp +++ b/engines/cge2/hero.cpp @@ -395,7 +395,7 @@ void Hero::fun() { } int Hero::len(V2D v) { - return ((v.x * v.x + v.y * v.y) * (v.x * v.x + v.y * v.y)); + return sqrt(double(v.x * v.x + v.y * v.y)); } bool Hero::findWay(){ -- cgit v1.2.3