summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJcw87 <Jcw87@users.noreply.github.com>2026-02-13 15:06:14 -0800
committerGitHub <noreply@github.com>2026-02-13 15:06:14 -0800
commit68f3531c2d3ee6cc90efe90a358cff1656ba275e (patch)
tree40f85cff455bebdd3521813e206513df3aa7e5ff
parent0e58f214e58a47e6012014109bcba19694666716 (diff)
d_bg_parts debug (#3097)
-rw-r--r--config/ShieldD/symbols.txt11
-rw-r--r--include/JSystem/J3DGraphAnimator/J3DAnimation.h6
-rw-r--r--include/JSystem/J3DGraphAnimator/J3DMaterialAnm.h5
-rw-r--r--include/d/dolzel_base.pch6
-rw-r--r--src/JSystem/J2DGraph/J2DAnimation.cpp1
-rw-r--r--src/JSystem/J2DGraph/J2DPane.cpp1
-rw-r--r--src/JSystem/J3DGraphAnimator/J3DAnimation.cpp1
-rw-r--r--src/d/d_bg_parts.cpp16
8 files changed, 29 insertions, 18 deletions
diff --git a/config/ShieldD/symbols.txt b/config/ShieldD/symbols.txt
index 21baeb9a4d..e3317917a1 100644
--- a/config/ShieldD/symbols.txt
+++ b/config/ShieldD/symbols.txt
@@ -35369,7 +35369,12 @@ __vt__11J3DTexNoAnm = .data:0x80675C6C; // type:object size:0xC scope:global has
@STRING@getTevStr__20dStage_roomControl_cFi@1 = .data:0x80675CCC; // type:object size:0xA scope:local data:string hash:0xB371DD93 dhash:0x5877BE51
@STRING@getTevStr__20dStage_roomControl_cFi@0 = .data:0x80675CD8; // type:object size:0x1F scope:local data:string hash:0xB371DD92 dhash:0x5877BE51
@STRING@getTevStr__20dStage_roomControl_cFi = .data:0x80675CF8; // type:object size:0xA scope:local data:string hash:0x18D914E2 dhash:0x7E1543DD
-lbl_80675D02 = .data:0x80675D02; // type:object size:0x72
+lbl_80675D04 = .data:0x80675D04; // type:object size:0xF scope:local data:string
+lbl_80675D14 = .data:0x80675D14; // type:object size:0x14 scope:local data:string
+lbl_80675D28 = .data:0x80675D28; // type:object size:0xF scope:local data:string
+lbl_80675D38 = .data:0x80675D38; // type:object size:0x14 scope:local data:string
+lbl_80675D4C = .data:0x80675D4C; // type:object size:0x14 scope:local data:string
+lbl_80675D60 = .data:0x80675D60; // type:object size:0x14 scope:local data:string
@STRING@calc__11J3DTexNoAnmCFPUs@1 = .data:0x80675D74; // type:object size:0x11 scope:local data:string hash:0xF4F6EEE8 dhash:0xF4B71B93
@STRING@calc__11J3DTexNoAnmCFPUs@0 = .data:0x80675D88; // type:object size:0x16 scope:local data:string hash:0xF4F6EEE9 dhash:0xF4B71B93
@STRING@calc__11J3DTexNoAnmCFPUs = .data:0x80675DA0; // type:object size:0x11 scope:local data:string hash:0x286C5CD9 dhash:0x4E541C9F
@@ -35382,7 +35387,9 @@ lbl_80675D02 = .data:0x80675D02; // type:object size:0x72
@STRING@getUpdateMaterialID__19J3DAnmTextureSRTKeyCFUs@1 = .data:0x80675E1C; // type:object size:0xF scope:local data:string hash:0x75E2F1C9 dhash:0x31BC78C0
@STRING@getUpdateMaterialID__19J3DAnmTextureSRTKeyCFUs@0 = .data:0x80675E2C; // type:object size:0x14 scope:local data:string hash:0x75E2F1C8 dhash:0x31BC78C0
@STRING@getUpdateMaterialID__19J3DAnmTextureSRTKeyCFUs = .data:0x80675E40; // type:object size:0xF scope:local data:string hash:0x362D1BB8 dhash:0x9C0CF24C
-lbl_80675E4F = .data:0x80675E4F; // type:object size:0x31
+lbl_80675E50 = .data:0x80675E50; // type:object size:0x9 scope:local data:string
+lbl_80675E5C = .data:0x80675E5C; // type:object size:0x16 scope:local data:string
+lbl_80675E74 = .data:0x80675E74; // type:object size:0x9 scope:local data:string
@STRING@setVtxPos__6J3DSysFPv@1 = .data:0x80675E80; // type:object size:0x9 scope:local data:string hash:0x667AC9E7 dhash:0x98DF38F3
@STRING@setVtxPos__6J3DSysFPv@0 = .data:0x80675E8C; // type:object size:0x16 scope:local data:string hash:0x667AC9E6 dhash:0x98DF38F3
@STRING@setVtxPos__6J3DSysFPv = .data:0x80675EA4; // type:object size:0x9 scope:local data:string hash:0x04535496 dhash:0x3417B5FF
diff --git a/include/JSystem/J3DGraphAnimator/J3DAnimation.h b/include/JSystem/J3DGraphAnimator/J3DAnimation.h
index 041ce31875..f38c79ef9a 100644
--- a/include/JSystem/J3DGraphAnimator/J3DAnimation.h
+++ b/include/JSystem/J3DGraphAnimator/J3DAnimation.h
@@ -1,11 +1,13 @@
#ifndef J3DANIMATION_H
#define J3DANIMATION_H
-#include "JSystem/J3DGraphAnimator/J3DModelData.h"
-#include "JSystem/JUtility/JUTAssert.h"
+#include "JSystem/J3DAssert.h"
#include "JSystem/JUtility/JUTNameTab.h"
+#include <dolphin/mtx.h>
#include "global.h"
+class J3DTransformInfo;
+
struct JUTDataBlockHeader {
/* 0x0 */ u32 mType;
/* 0x4 */ u32 mSize;
diff --git a/include/JSystem/J3DGraphAnimator/J3DMaterialAnm.h b/include/JSystem/J3DGraphAnimator/J3DMaterialAnm.h
index 2403c8384a..ff41bc4f01 100644
--- a/include/JSystem/J3DGraphAnimator/J3DMaterialAnm.h
+++ b/include/JSystem/J3DGraphAnimator/J3DMaterialAnm.h
@@ -93,7 +93,10 @@ public:
J3D_ASSERT_NULLPTR(214, pAnmTexPattern != NULL);
}
- virtual void calc(u16* param_0) const { mAnmTexPattern->getTexNo(field_0x4, param_0); }
+ virtual void calc(u16* param_0) const {
+ J3D_ASSERT_NULLPTR(532, param_0);
+ mAnmTexPattern->getTexNo(field_0x4, param_0);
+ }
void operator=(J3DTexNoAnm const& other) {
mAnmTexPattern = other.mAnmTexPattern;
diff --git a/include/d/dolzel_base.pch b/include/d/dolzel_base.pch
index d430859ca2..87dcd80f6b 100644
--- a/include/d/dolzel_base.pch
+++ b/include/d/dolzel_base.pch
@@ -18,15 +18,13 @@
#include "JSystem/JKernel/JKRDisposer.h" // IWYU pragma: export
#include "JSystem/JGadget/linklist.h" // IWYU pragma: export
#include "JSystem/J3DGraphBase/J3DPacket.h" // IWYU pragma: export
-#include "JSystem/J3DGraphAnimator/J3DMaterialAttach.h" // IWYU pragma: export
#include "JSystem/J3DGraphAnimator/J3DShapeTable.h" // IWYU pragma: export
-#include "JSystem/J3DGraphAnimator/J3DMaterialAnm.h" // IWYU pragma: export
#include "JSystem/J3DGraphAnimator/J3DAnimation.h" // IWYU pragma: export
+#include "JSystem/J3DGraphAnimator/J3DMaterialAnm.h" // IWYU pragma: export
+#include "JSystem/J3DGraphAnimator/J3DMaterialAttach.h" // IWYU pragma: export
#include "JSystem/J3DGraphAnimator/J3DJoint.h" // IWYU pragma: export
#include "JSystem/JUtility/JUTGamePad.h" // IWYU pragma: export
#include "JSystem/J3DGraphBase/J3DSys.h" // IWYU pragma: export
-#include "JSystem/J3DGraphAnimator/J3DMaterialAttach.h" // IWYU pragma: export
-#include "JSystem/J3DGraphAnimator/J3DMaterialAnm.h" // IWYU pragma: export
#include "JSystem/JHostIO/JHICommonMem.h" // IWYU pragma: export
#include "JSystem/JHostIO/JORReflexible.h" // IWYU pragma: export
#include "SSystem/SComponent/c_m3d_g_sph.h" // IWYU pragma: export
diff --git a/src/JSystem/J2DGraph/J2DAnimation.cpp b/src/JSystem/J2DGraph/J2DAnimation.cpp
index bf19ea1546..9a0405c4d9 100644
--- a/src/JSystem/J2DGraph/J2DAnimation.cpp
+++ b/src/JSystem/J2DGraph/J2DAnimation.cpp
@@ -3,6 +3,7 @@
#include "JSystem/J2DGraph/J2DAnimation.h"
#include "JSystem/J2DGraph/J2DScreen.h"
#include "JSystem/J3DGraphBase/J3DTexture.h"
+#include "JSystem/J3DGraphBase/J3DTransform.h"
#include "JSystem/JUtility/JUTPalette.h"
#include "JSystem/JUtility/JUTResource.h"
#include <dolphin/os.h>
diff --git a/src/JSystem/J2DGraph/J2DPane.cpp b/src/JSystem/J2DGraph/J2DPane.cpp
index ccaa67aaa4..23f40cd375 100644
--- a/src/JSystem/J2DGraph/J2DPane.cpp
+++ b/src/JSystem/J2DGraph/J2DPane.cpp
@@ -4,6 +4,7 @@
#include "JSystem/J2DGraph/J2DAnimation.h"
#include "JSystem/J2DGraph/J2DOrthoGraph.h"
#include "JSystem/J2DGraph/J2DScreen.h"
+#include "JSystem/J3DGraphBase/J3DTransform.h"
#include "JSystem/JSupport/JSURandomInputStream.h"
#include "JSystem/JUtility/JUTResource.h"
diff --git a/src/JSystem/J3DGraphAnimator/J3DAnimation.cpp b/src/JSystem/J3DGraphAnimator/J3DAnimation.cpp
index 6b9a2d2250..28b80c58f1 100644
--- a/src/JSystem/J3DGraphAnimator/J3DAnimation.cpp
+++ b/src/JSystem/J3DGraphAnimator/J3DAnimation.cpp
@@ -1,6 +1,7 @@
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphAnimator/J3DAnimation.h"
+#include "JSystem/J3DGraphAnimator/J3DModelData.h"
#include "JSystem/J3DGraphBase/J3DStruct.h"
#include "JSystem/JMath/JMath.h"
diff --git a/src/d/d_bg_parts.cpp b/src/d/d_bg_parts.cpp
index 7d4dcd38f2..3799fe52da 100644
--- a/src/d/d_bg_parts.cpp
+++ b/src/d/d_bg_parts.cpp
@@ -7,15 +7,13 @@
#include "JSystem/JKernel/JKRExpHeap.h"
#include "JSystem/JKernel/JKRSolidHeap.h"
-// NONMATCHING
void dBgp_c::material_c::draw() {
- material_c* material;
+ material_c* material = this;
do {
- drawSimple();
- } while ((material = getNext()) != NULL);
+ material->drawSimple();
+ } while ((material = material->getNext()) != NULL);
}
-// NONMATCHING - regalloc
void dBgp_c::modelMaterial_c::drawSimple() {
if (mpMaterial->getInvalid()) {
OSReport_Warning("Share Material Nothing !!\n");
@@ -33,7 +31,7 @@ void dBgp_c::modelMaterial_c::drawSimple() {
int spC = 0;
void* vatCmd = NULL;
- if (getMaterial()->getShape()->checkFlag(1)) {
+ if (modelMaterial->getMaterial()->getShape()->checkFlag(1)) {
modelMaterial = modelMaterial->getChild();
}
@@ -106,7 +104,7 @@ void dBgp_c::modelMaterial_c::set(J3DModelData* i_modelData, J3DMaterial* i_mate
void dBgp_c::model_c::create(J3DModelData* i_modelData, Mtx i_mtx) {
const void* binary = i_modelData->getBinary();
-
+
mId = *(u32*)((char*)binary + 0x1C);
if (mId != 0xFFFF) {
addShare(mId);
@@ -230,7 +228,7 @@ void dBgp_c::share_c::set(u16 i_id) {
if (mCount++ == 0) {
mStatus = 1;
mId = i_id;
-
+
int rt = dComIfG_setObjectRes(getArcName(), 0, (JKRHeap*)NULL);
JUT_ASSERT(446, rt != 0);
}
@@ -295,7 +293,7 @@ int dBgp_c::share_c::execute() {
for (u16 i = 0; i < mModelData->getMaterialNum(); i++) {
J3DMaterial* material = mModelData->getMaterialNodePointer(i);
mMaterial[i].set(mModelData, material, cMtx_getIdentity());
-
+
J3DShape* shape = material->getShape();
shape->hide();