diff options
author | Paul Gilbert | 2017-07-15 17:29:42 -0400 |
---|---|---|
committer | Paul Gilbert | 2017-07-15 17:29:42 -0400 |
commit | 8d9c9a9078657064763dbb81974858a637d6d506 (patch) | |
tree | 147c0b868f8ecc34e0ad6c4dd9b8025025e5b89f /engines/titanic/star_control | |
parent | 98060e8f60ef27e604bb72d9ead0cae8d29f57d0 (diff) | |
download | scummvm-rg350-8d9c9a9078657064763dbb81974858a637d6d506.tar.gz scummvm-rg350-8d9c9a9078657064763dbb81974858a637d6d506.tar.bz2 scummvm-rg350-8d9c9a9078657064763dbb81974858a637d6d506.zip |
TITANIC: Don't allow the same star to be locked on multiple times
Diffstat (limited to 'engines/titanic/star_control')
-rw-r--r-- | engines/titanic/star_control/star_field.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/engines/titanic/star_control/star_field.cpp b/engines/titanic/star_control/star_field.cpp index 722b448bc9..75a080a352 100644 --- a/engines/titanic/star_control/star_field.cpp +++ b/engines/titanic/star_control/star_field.cpp @@ -193,6 +193,10 @@ void CStarField::fn4(CSurfaceArea *surfaceArea, CStarCamera *camera) { double CStarField::fn5(CSurfaceArea *surfaceArea, CStarCamera *camera, FVector &v1, FVector &v2, FVector &v3) { if (_crosshairs.isEmpty()) + // No crosshairs selection yet + return -1.0; + if (_crosshairs._entryIndex == _crosshairs._matchIndex) + // Trying to re-lock on a previously locked star return -1.0; const CBaseStarEntry *dataP = _markers.getDataPtr(_crosshairs._entryIndex); |