summaryrefslogtreecommitdiffstats
path: root/src/core/Radar.cpp
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2020-09-26 12:30:22 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2020-09-26 12:30:22 +0200
commitb42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9 (patch)
tree84d1bb921722801784283e70667b93b8a7ee4dc1 /src/core/Radar.cpp
parentMerge remote-tracking branch 'upstream/master' (diff)
downloadre3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.tar
re3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.tar.gz
re3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.tar.bz2
re3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.tar.lz
re3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.tar.xz
re3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.tar.zst
re3-b42d9e3e7c1caf6ad06ad81eb34cc27e09bd9bb9.zip
Diffstat (limited to 'src/core/Radar.cpp')
-rw-r--r--src/core/Radar.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/core/Radar.cpp b/src/core/Radar.cpp
index 05002a3f..af28aae7 100644
--- a/src/core/Radar.cpp
+++ b/src/core/Radar.cpp
@@ -1100,6 +1100,10 @@ int CRadar::SetCoordBlip(eBlipType type, CVector pos, int32 color, eBlipDisplay
if (!ms_RadarTrace[nextBlip].m_bInUse)
break;
}
+#ifdef FIX_BUGS
+ if (nextBlip == NUMRADARBLIPS)
+ return -1;
+#endif
ms_RadarTrace[nextBlip].m_eBlipType = type;
ms_RadarTrace[nextBlip].m_nColor = color;
ms_RadarTrace[nextBlip].m_bDim = 1;
@@ -1121,6 +1125,10 @@ int CRadar::SetEntityBlip(eBlipType type, int32 handle, int32 color, eBlipDispla
if (!ms_RadarTrace[nextBlip].m_bInUse)
break;
}
+#ifdef FIX_BUGS
+ if (nextBlip == NUMRADARBLIPS)
+ return -1;
+#endif
ms_RadarTrace[nextBlip].m_eBlipType = type;
ms_RadarTrace[nextBlip].m_nColor = color;
ms_RadarTrace[nextBlip].m_bDim = 1;
@@ -1452,6 +1460,10 @@ CRadar::ToggleTargetMarker(float x, float y)
if (!ms_RadarTrace[nextBlip].m_bInUse)
break;
}
+#ifdef FIX_BUGS
+ if (nextBlip == NUMRADARBLIPS)
+ return;
+#endif
ms_RadarTrace[nextBlip].m_eBlipType = BLIP_COORD;
ms_RadarTrace[nextBlip].m_nColor = 0x333333FF;
ms_RadarTrace[nextBlip].m_bDim = 1;