summaryrefslogtreecommitdiffstats
path: root/src/control/Script.h
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2019-07-07 09:45:07 +0200
committerGitHub <noreply@github.com>2019-07-07 09:45:07 +0200
commitb515ce4730891ea11540369241d9d6d7b0749057 (patch)
tree5f04ec2612812056b5bcada9e8e6fe1172e02ca0 /src/control/Script.h
parentMerge pull request #115 from erorcun/erorcun (diff)
parentAdded CUpsideDownCarCheck and CStuckCarCheck (diff)
downloadre3-b515ce4730891ea11540369241d9d6d7b0749057.tar
re3-b515ce4730891ea11540369241d9d6d7b0749057.tar.gz
re3-b515ce4730891ea11540369241d9d6d7b0749057.tar.bz2
re3-b515ce4730891ea11540369241d9d6d7b0749057.tar.lz
re3-b515ce4730891ea11540369241d9d6d7b0749057.tar.xz
re3-b515ce4730891ea11540369241d9d6d7b0749057.tar.zst
re3-b515ce4730891ea11540369241d9d6d7b0749057.zip
Diffstat (limited to 'src/control/Script.h')
-rw-r--r--src/control/Script.h16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/control/Script.h b/src/control/Script.h
index 7b62a1b0..42e41c70 100644
--- a/src/control/Script.h
+++ b/src/control/Script.h
@@ -101,16 +101,24 @@ class CUpsideDownCarCheck
public:
void Init();
+ bool IsCarUpsideDown(int32);
+ void UpdateTimers();
+ bool AreAnyCarsUpsideDown();
+ void AddCarToCheck(int32);
+ void RemoveCarFromCheck(int32);
+ bool HasCarBeenUpsideDownForAWhile(int32);
};
struct CStuckCarCheckEntry
{
int32 m_nVehicleIndex;
CVector m_vecPos;
- int32 m_nStartTime;
- float m_fDistance;
+ int32 m_nLastCheck;
+ float m_fRadius;
uint32 m_nStuckTime;
bool m_bStuck;
+
+ inline void Reset();
};
class CStuckCarCheck
@@ -119,6 +127,10 @@ class CStuckCarCheck
public:
void Init();
+ void Process();
+ void AddCarToCheck(int32, float, uint32);
+ void RemoveCarFromCheck(int32);
+ bool HasCarBeenStuckForAWhile(int32);
};
class CTheScripts