summaryrefslogtreecommitdiffstats
path: root/src/control/Script6.cpp
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2021-01-16 11:32:41 +0100
committerNikolay Korolev <nickvnuk@gmail.com>2021-01-16 11:32:41 +0100
commit7ea77d8da41c05ea30716c1663f2b1f852574f1f (patch)
treefce94f05cb5940e2f8867d2bae714a4681ec801a /src/control/Script6.cpp
parentfix (diff)
downloadre3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.tar
re3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.tar.gz
re3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.tar.bz2
re3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.tar.lz
re3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.tar.xz
re3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.tar.zst
re3-7ea77d8da41c05ea30716c1663f2b1f852574f1f.zip
Diffstat (limited to 'src/control/Script6.cpp')
-rw-r--r--src/control/Script6.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/control/Script6.cpp b/src/control/Script6.cpp
index b82c961d..c9828758 100644
--- a/src/control/Script6.cpp
+++ b/src/control/Script6.cpp
@@ -42,6 +42,20 @@
extern const char* scriptfile;
#endif
+bool CRunningScript::ThisIsAValidRandomCop(uint32 mi, int cop, int swat, int fbi, int army, int miami)
+{
+ switch (mi)
+ {
+ case MI_COP: if (cop) return true; break;
+ case MI_SWAT: if (swat) return true; break;
+ case MI_FBI: if (fbi) return true; break;
+ case MI_ARMY: if (army) return true; break;
+ default:
+ return miami && (mi >= MI_VICE1 && mi <= MI_VICE8);
+ }
+ return false;
+}
+
bool CRunningScript::ThisIsAValidRandomPed(uint32 pedtype, int civ, int gang, int criminal)
{
switch (pedtype) {
@@ -66,20 +80,6 @@ bool CRunningScript::ThisIsAValidRandomPed(uint32 pedtype, int civ, int gang, in
}
}
-bool CRunningScript::ThisIsAValidRandomCop(int32 mi, bool cop, bool swat, bool fbi, bool army, bool miami)
-{
- switch (mi)
- {
- case MI_COP: if (cop) return true;
- case MI_SWAT: if (swat) return true;
- case MI_FBI: if (fbi) return true;
- case MI_ARMY: if (army) return true;
- default:
- return miami && (mi >= MI_VICE1 && mi <= MI_VICE8);
- }
- return false;
-}
-
int8 CRunningScript::ProcessCommands1000To1099(int32 command)
{
switch (command) {