From 471c76a9a75a41615f6fd0788cb36f0da18f961f Mon Sep 17 00:00:00 2001 From: Retro-Junk Date: Tue, 6 Sep 2016 21:50:33 +0300 Subject: FULLPIPE: Fix rounding error in MctlGraph::makeQueue --- engines/fullpipe/motion.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engines/fullpipe') diff --git a/engines/fullpipe/motion.cpp b/engines/fullpipe/motion.cpp index 490e593bbc..b910c815a2 100644 --- a/engines/fullpipe/motion.cpp +++ b/engines/fullpipe/motion.cpp @@ -2332,7 +2332,7 @@ MessageQueue *MctlGraph::makeQueue(StaticANIObject *obj, int xpos, int ypos, int double dst1 = sqrt((double)((ypos - nod->_y) * (ypos - nod->_y) + (xpos - nod->_x) * (xpos - nod->_x))); int dst = linkInfoDest.link->_graphDst->_z - nod->_z; - mctlMQ1.distance2 = (int)(nod->_z + (dst1 * (double)dst / linkInfoDest.link->_length)); + mctlMQ1.distance2 = nod->_z + (int)(dst1 * (double)dst / linkInfoDest.link->_length); putToLink(&mctlMQ1.pt2, linkInfoDest.link, 1); -- cgit v1.2.3