aboutsummaryrefslogtreecommitdiff
path: root/engines/titanic/star_control
diff options
context:
space:
mode:
authorPaul Gilbert2017-06-04 20:17:51 -0400
committerPaul Gilbert2017-06-04 20:17:51 -0400
commit39ffcf7a1bbe56f42f977c81bf089a36803d8158 (patch)
treea7f7a3e418dc83383790f57b5bc351e3587bc13f /engines/titanic/star_control
parent032cd3f4eb84fb63d47e72c66812fdf6decf1026 (diff)
downloadscummvm-rg350-39ffcf7a1bbe56f42f977c81bf089a36803d8158.tar.gz
scummvm-rg350-39ffcf7a1bbe56f42f977c81bf089a36803d8158.tar.bz2
scummvm-rg350-39ffcf7a1bbe56f42f977c81bf089a36803d8158.zip
TITANIC: Simplifications in lockMarker2
Diffstat (limited to 'engines/titanic/star_control')
-rw-r--r--engines/titanic/star_control/star_camera.cpp13
1 files changed, 3 insertions, 10 deletions
diff --git a/engines/titanic/star_control/star_camera.cpp b/engines/titanic/star_control/star_camera.cpp
index c12d794f8d..d45f4f094d 100644
--- a/engines/titanic/star_control/star_camera.cpp
+++ b/engines/titanic/star_control/star_camera.cpp
@@ -459,11 +459,10 @@ void CStarCamera::lockMarker2(CViewport *viewport, const FVector &v) {
DMatrix m1;
DVector tempV1 = _matrix._row1;
- DMatrix m2(0, tempV1);
+ DMatrix m2(X_AXIS, tempV1);
tempV1 = v - _matrix._row1;
m1 = tempV1.fn5();
-
m1 = m1.fn4(m2);
m2 = m1.fn1();
@@ -476,14 +475,8 @@ void CStarCamera::lockMarker2(CViewport *viewport, const FVector &v) {
FMatrix m5 = viewport->getOrientation();
DVector tempV3, tempV4;
- tempV4._x = m5._row1._x * 1000000.0 + m4._row1._x;
- tempV4._y = m5._row1._y * 1000000.0 + m4._row1._y;
- tempV4._z = m5._row1._z * 1000000.0 + m4._row1._z;
- tempV3._x = m5._row2._x * 1000000.0 + m4._row1._x;
- tempV3._y = m5._row2._y * 1000000.0 + m4._row1._y;
- tempV3._z = m5._row2._z * 1000000.0 + m4._row1._z;
- m4._row3 = tempV4;
- m4._row2 = tempV3;
+ m4._row3 = tempV4 = m5._row1 * 1000000.0 + m4._row1;
+ m4._row2 = tempV3 = m5._row2 * 1000000.0 + m4._row1;
tempV4._x = m5._row3._x * 1000000.0;
tempV4._y = m5._row3._y * 1000000.0;