From 7887189b5aa806a38c06253f535b7eb78e250f53 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Sun, 12 Mar 2017 09:51:23 -0400 Subject: TITANIC: Finished CStarControlSub23 class --- engines/titanic/star_control/fvector.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'engines/titanic/star_control/fvector.cpp') diff --git a/engines/titanic/star_control/fvector.cpp b/engines/titanic/star_control/fvector.cpp index aa99e8b4d1..de33bcf2a0 100644 --- a/engines/titanic/star_control/fvector.cpp +++ b/engines/titanic/star_control/fvector.cpp @@ -40,13 +40,14 @@ void FVector::multiply(FVector *dest, const FVector *src) { dest->_z = (src->_y * _x) - (_y * src->_x); } -void FVector::fn3() { +double FVector::fn3() { double hyp = sqrt(_x * _x + _y * _y + _z * _z); assert(hyp); _x *= 1.0 / hyp; _y *= 1.0 / hyp; _z *= 1.0 / hyp; + return hyp; } double FVector::getDistance(const FVector *src) const { -- cgit v1.2.3