Add more J3D_ASSERTs (#2491)

* Fix debug build

* Add more J3D_ASSERTs

* Move J3DShapeMtx to correct header for assert

* Add VSCode task for ninja changes_all
This commit is contained in:
LagoLunatic
2025-06-20 02:41:43 -04:00
committed by GitHub
parent 25d13c76e4
commit ac06966414
24 changed files with 268 additions and 174 deletions
@@ -2,6 +2,7 @@
#define J3DSHAPETABLE_H
#include "JSystem/J3DGraphBase/J3DShape.h"
#include "JSystem/JUtility/JUTAssert.h"
class JUTNameTab;
@@ -25,7 +26,10 @@ public:
virtual ~J3DShapeTable() {}
u16 getShapeNum() const { return mShapeNum; }
J3DShape* getShapeNodePointer(u16 idx) const { return mShapeNodePointer[idx]; }
J3DShape* getShapeNodePointer(u16 idx) const {
J3D_ASSERT(85, idx < mShapeNum, "Error : range over.");
return mShapeNodePointer[idx];
}
private:
friend class J3DModelLoader;