summaryrefslogtreecommitdiffstats
path: root/src/renderer/Rubbish.h
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2021-07-15 17:19:32 +0200
committerSergeanur <s.anureev@yandex.ua>2021-07-17 23:04:26 +0200
commitd0404cbdb77bd82abf578ce28093990db94743f2 (patch)
tree1a7232c3dcdd6c371ab5fbde0fc6bf04c5bc7005 /src/renderer/Rubbish.h
parentMerge pull request #1217 from Nopey/master (diff)
downloadre3-d0404cbdb77bd82abf578ce28093990db94743f2.tar
re3-d0404cbdb77bd82abf578ce28093990db94743f2.tar.gz
re3-d0404cbdb77bd82abf578ce28093990db94743f2.tar.bz2
re3-d0404cbdb77bd82abf578ce28093990db94743f2.tar.lz
re3-d0404cbdb77bd82abf578ce28093990db94743f2.tar.xz
re3-d0404cbdb77bd82abf578ce28093990db94743f2.tar.zst
re3-d0404cbdb77bd82abf578ce28093990db94743f2.zip
Diffstat (limited to 'src/renderer/Rubbish.h')
-rw-r--r--src/renderer/Rubbish.h55
1 files changed, 55 insertions, 0 deletions
diff --git a/src/renderer/Rubbish.h b/src/renderer/Rubbish.h
new file mode 100644
index 00000000..37f895f3
--- /dev/null
+++ b/src/renderer/Rubbish.h
@@ -0,0 +1,55 @@
+#pragma once
+
+class CVehicle;
+
+enum {
+ // NB: not all values are allowed, check the code
+#ifdef SQUEEZE_PERFORMANCE
+ NUM_RUBBISH_SHEETS = 32
+#else
+ NUM_RUBBISH_SHEETS = 64
+#endif
+};
+
+class COneSheet
+{
+public:
+ CVector m_basePos;
+ CVector m_animatedPos;
+ float m_targetZ;
+ int8 m_state;
+ int8 m_animationType;
+ uint32 m_moveStart;
+ uint32 m_moveDuration;
+ float m_animHeight;
+ float m_xDist;
+ float m_yDist;
+ float m_angle;
+ bool m_isVisible;
+ bool m_targetIsVisible;
+ COneSheet *m_next;
+ COneSheet *m_prev;
+
+ void AddToList(COneSheet *list);
+ void RemoveFromList(void);
+};
+
+class CRubbish
+{
+ static bool bRubbishInvisible;
+ static int RubbishVisibility;
+ static COneSheet aSheets[NUM_RUBBISH_SHEETS];
+ static COneSheet StartEmptyList;
+ static COneSheet EndEmptyList;
+ static COneSheet StartStaticsList;
+ static COneSheet EndStaticsList;
+ static COneSheet StartMoversList;
+ static COneSheet EndMoversList;
+public:
+ static void Render(void);
+ static void StirUp(CVehicle *veh); // CAutomobile on PS2
+ static void Update(void);
+ static void SetVisibility(bool visible);
+ static void Init(void);
+ static void Shutdown(void);
+};