MapObjDolpic decompilation + THitActor fixes#78
MapObjDolpic decompilation + THitActor fixes#78ryanbevins wants to merge 2 commits intodoldecomp:mainfrom
Conversation
include/MoveBG/MapObjDolpic.hpp
Outdated
| public: | ||
| TMonumentShine(const char*); | ||
|
|
||
| virtual ~TMonumentShine() { } |
There was a problem hiding this comment.
Compiler automatically generates virtual destructors if the base has one so please remove all of these empty virtual dtors -- the original code likely didn't have those either
include/Strategic/HitActor.hpp
Outdated
|
|
||
| // fabricated | ||
| u32 getActorType() const { return mActorType; } | ||
| u8 isActorTypeOf(u32 base) const |
There was a problem hiding this comment.
Lets not be hasty with adding this to HitActor, leave it in the cpp file you've been working on. This inline doesn't make any sense so we'll probably have to gather more data and think about it for a bit
src/MoveBG/MapObjDolpic.cpp
Outdated
| if (unk13C == 0) { | ||
| gpItemManager->makeShineAppearWithDemo( | ||
| "\x83\x56\x83\x83\x83\x43\x83\x93\x81\x69\x83\x82\x83\x6A\x83\x85\x83\x81\x83\x93\x83\x67\x83\x56\x83\x83\x83\x43\x83\x93\x97\x70\x81\x6A", | ||
| "\x83\x82\x83\x6A\x83\x85\x83\x81\x83\x93\x83\x67\x83\x56\x83\x83\x83\x43\x83\x93\x83\x4A\x83\x81\x83\x89", |
There was a problem hiding this comment.
This is japanese text, please decode it with ShiftJIS and make the literal human-readable (lol) japanese
src/MoveBG/MapObjDolpic.cpp
Outdated
| set100: | ||
| unk138.a = 100; | ||
| unk154 = 1000; | ||
| done:; |
There was a problem hiding this comment.
Nah, this is 100% fake, send a decomp.me scratch
src/MoveBG/MapObjDolpic.cpp
Outdated
| } else { | ||
| gpItemManager->makeShineAppearWithDemo( | ||
| "\x83\x56\x83\x83\x83\x43\x83\x93\x81\x69\x83\x68\x83\x8B\x83\x73\x83\x62\x83\x4E\x8F\xE0\x83\x65\x83\x83\x83\x8C\x83\x72\x8B\xC7\x97\x70\x81\x6A", | ||
| "\x83\x68\x83\x8B\x83\x73\x83\x62\x83\x4E\x8F\xE0\x83\x65\x83\x83\x83\x8C\x83\x72\x8B\xC7\x83\x4A\x83\x81\x83\x89", |
There was a problem hiding this comment.
Again, these two places have japanese text, please decode
|
|
||
| mMActor->setBck("democannon_dpt"); | ||
| J3DFrameCtrl* frameCtrl = mMActor->getFrameCtrl(0); | ||
| frameCtrl->mCurrentFrame = (f32)frameCtrl->mEndFrame; |
There was a problem hiding this comment.
Use getters/setters here and you won't need the _pad trick. And in general, I'd prefer for the _pad thing to not be used, because that way it's easier to find stuff that needs more undiscovered inlines
- Remove all empty virtual dtors (compiler auto-generates them) - Move isActorTypeOf helper from HitActor.hpp to local static in cpp - Decode all ShiftJIS hex escapes to literal Japanese characters - Remove fake matching (goto control flow, stack padding hacks) - Use TNameRefGen::search<Type> instead of manual searchF - Remove out-of-line TTurboNozzleDoor dtor (weak/inline symbol)
5bd4995 to
9d10b67
Compare
Report for GMSJ01 (e218eda - 9d10b67)📈 Matched code: 26.47% (+0.11%, +3920 bytes) ✅ 33 new matches
...and 3 more new matches 📈 12 improvements in unmatched items
|
Summary
isActorTypeOf()inline helper to THitActor for boolean materialization matching