summaryrefslogtreecommitdiffstats
path: root/src/control/Script6.cpp
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2021-01-16 15:56:24 +0100
committerSergeanur <s.anureev@yandex.ua>2021-01-16 15:56:24 +0100
commiteb5fdac91838e4a2b09860938b7801b5d604c7cd (patch)
tree08715fbd7dde874ac49780fd098969917f7ff259 /src/control/Script6.cpp
parentFixes for lcs conan (diff)
parentUse of sized bool types for CFont (diff)
downloadre3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.tar
re3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.tar.gz
re3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.tar.bz2
re3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.tar.lz
re3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.tar.xz
re3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.tar.zst
re3-eb5fdac91838e4a2b09860938b7801b5d604c7cd.zip
Diffstat (limited to '')
-rw-r--r--src/control/Script6.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/control/Script6.cpp b/src/control/Script6.cpp
index 02427eed..3a03ea9b 100644
--- a/src/control/Script6.cpp
+++ b/src/control/Script6.cpp
@@ -42,6 +42,19 @@
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: if (mi >= MI_VICE1 && mi <= MI_VICE8 && miami) return true; break;
+ }
+ return false;
+}
+
bool CRunningScript::ThisIsAValidRandomPed(uint32 pedtype, int civ, int gang, int criminal)
{
switch (pedtype) {
@@ -66,19 +79,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);
- }
-}
-
int8 CRunningScript::ProcessCommands1000To1099(int32 command)
{
switch (command) {