summaryrefslogtreecommitdiffstats
path: root/src/collision/ColModel.h
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2020-11-14 21:13:32 +0100
committerSergeanur <s.anureev@yandex.ua>2020-11-15 23:36:54 +0100
commit9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c (patch)
tree3dcbab653ba34fa1fdc273887bd377603c4ff4f2 /src/collision/ColModel.h
parentcar AI revision (diff)
downloadre3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.tar
re3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.tar.gz
re3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.tar.bz2
re3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.tar.lz
re3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.tar.xz
re3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.tar.zst
re3-9bb8ebaa1011dc1dc70e3d5bf70c9a55c44b976c.zip
Diffstat (limited to 'src/collision/ColModel.h')
-rw-r--r--src/collision/ColModel.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/src/collision/ColModel.h b/src/collision/ColModel.h
new file mode 100644
index 00000000..cd5ae651
--- /dev/null
+++ b/src/collision/ColModel.h
@@ -0,0 +1,39 @@
+#pragma once
+
+#include "templates.h"
+#include "ColBox.h"
+#include "ColSphere.h"
+#include "ColLine.h"
+#include "ColPoint.h"
+#include "ColTriangle.h"
+
+struct CColModel
+{
+ CSphere boundingSphere;
+ CBox boundingBox;
+ int16 numSpheres;
+ int16 numBoxes;
+ int16 numTriangles;
+ int8 numLines;
+ uint8 level; // colstore slot but probably still named level
+ bool ownsCollisionVolumes;
+ CColSphere *spheres;
+ CColLine *lines;
+ CColBox *boxes;
+ CompressedVector *vertices;
+ CColTriangle *triangles;
+ CColTrianglePlane *trianglePlanes;
+
+ CColModel(void);
+ ~CColModel(void);
+ void RemoveCollisionVolumes(void);
+ void CalculateTrianglePlanes(void);
+ void RemoveTrianglePlanes(void);
+ CLink<CColModel*> *GetLinkPtr(void);
+ void SetLinkPtr(CLink<CColModel*>*);
+ void GetTrianglePoint(CVector &v, int i) const;
+
+ void *operator new(size_t);
+ void operator delete(void *p, size_t);
+ CColModel& operator=(const CColModel& other);
+}; \ No newline at end of file