mirror of
https://github.com/zeldaret/tww.git
synced 2026-08-19 13:24:12 -04:00
merge in changes to main
This commit is contained in:
+91
-10
@@ -50,32 +50,46 @@ DynamicModuleControlBase::DynamicModuleControlBase() {
|
||||
}
|
||||
|
||||
BOOL DynamicModuleControlBase::link() {
|
||||
#if VERSION != VERSION_DEMO
|
||||
OSThread* thread = OSGetCurrentThread();
|
||||
if (thread != &mainThread) {
|
||||
OSReport_Error("DynamicModuleControlBase::link not mainthread %08x\n", thread);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (mLinkCount == 0) {
|
||||
do_load();
|
||||
if (do_link() == false) {
|
||||
return false;
|
||||
}
|
||||
#if VERSION == VERSION_DEMO
|
||||
mDoLinkCount++;
|
||||
#else
|
||||
if (mDoLinkCount < 0xFFFF) {
|
||||
mDoLinkCount++;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#if VERSION != VERSION_DEMO
|
||||
JUT_ASSERT(100, mLinkCount < 65535);
|
||||
#endif
|
||||
#if VERSION == VERSION_DEMO
|
||||
mLinkCount++;
|
||||
#else
|
||||
if (mLinkCount < 0xFFFF) {
|
||||
mLinkCount++;
|
||||
}
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
BOOL DynamicModuleControlBase::unlink() {
|
||||
#if VERSION != VERSION_DEMO
|
||||
OSThread* thread = OSGetCurrentThread();
|
||||
if (thread != &mainThread) {
|
||||
OSReport_Error("DynamicModuleControlBase::unlink not mainthread %08x\n", thread);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (mLinkCount != 0) {
|
||||
mLinkCount--;
|
||||
@@ -106,16 +120,19 @@ bool DynamicModuleControlBase::force_unlink() {
|
||||
}
|
||||
|
||||
void DynamicModuleControlBase::dump() {
|
||||
u16 doLinkCount;
|
||||
u16 linkCount;
|
||||
DynamicModuleControlBase* current = getFirstClass();
|
||||
size_t totalSize = 0;
|
||||
JUTReportConsole_f("\nDynamicModuleControlBase::dump()\n");
|
||||
JUTReportConsole_f("Do Ln Size Name\n");
|
||||
while (current != NULL) {
|
||||
doLinkCount = current->mDoLinkCount;
|
||||
linkCount = current->mLinkCount;
|
||||
if (doLinkCount != 0 || linkCount != 0) {
|
||||
#if VERSION == VERSION_DEMO
|
||||
u32 doLinkCount = current->mDoLinkCount;
|
||||
u32 linkCount = current->mLinkCount;
|
||||
#else
|
||||
u16 doLinkCount = current->mDoLinkCount;
|
||||
u16 linkCount = current->mLinkCount;
|
||||
#endif
|
||||
if (current->mDoLinkCount != 0 || current->mLinkCount != 0) {
|
||||
u32 size = current->getModuleSize();
|
||||
const char* name = current->getModuleName();
|
||||
if (size < 0xFFFFFFFF) {
|
||||
@@ -130,7 +147,9 @@ void DynamicModuleControlBase::dump() {
|
||||
JUTReportConsole_f("%3d%3d ???? ????? %-4s %s\n", doLinkCount, linkCount, type,
|
||||
name);
|
||||
}
|
||||
#if VERSION != VERSION_DEMO
|
||||
current->dump2();
|
||||
#endif
|
||||
}
|
||||
current = current->getNextClass();
|
||||
}
|
||||
@@ -143,9 +162,11 @@ DynamicModuleControl::DynamicModuleControl(char const* name) {
|
||||
unk_24 = 0;
|
||||
mName = name;
|
||||
mResourceType = 0;
|
||||
#if VERSION != VERSION_DEMO
|
||||
unk_33 = 0;
|
||||
mChecksum = 0;
|
||||
mSize = 0;
|
||||
#endif
|
||||
mAsyncLoadCallback = NULL;
|
||||
}
|
||||
|
||||
@@ -171,6 +192,10 @@ JKRArchive* DynamicModuleControl::mountCallback(void* param_0) {
|
||||
return sArchive;
|
||||
}
|
||||
|
||||
void DynamicModuleControl::mountCreate() {
|
||||
mDoDvdThd_callback_c::create((mDoDvdThd_callback_func)DynamicModuleControl::mountCallback, NULL);
|
||||
}
|
||||
|
||||
bool DynamicModuleControl::initialize() {
|
||||
sFileCache = NULL;
|
||||
sAllocBytes = 0;
|
||||
@@ -194,6 +219,47 @@ static u32 calcSum2(u16 const* data, u32 size) {
|
||||
return sum;
|
||||
}
|
||||
|
||||
#if VERSION == VERSION_DEMO
|
||||
bool DynamicModuleControl::do_load() {
|
||||
if (mModule != NULL) {
|
||||
return true;
|
||||
}
|
||||
char buffer[64];
|
||||
snprintf(buffer, 64, "%s.rel", mName);
|
||||
if (mModule == NULL && sArchive != NULL) {
|
||||
if (mModule == NULL) {
|
||||
mModule = (OSModuleHeader*)JKRGetResource('MMEM', buffer, sArchive);
|
||||
if (mModule != NULL) {
|
||||
mResourceType = 1;
|
||||
}
|
||||
}
|
||||
if (mModule == NULL) {
|
||||
mModule = (OSModuleHeader*)JKRGetResource('AMEM', buffer, sArchive);
|
||||
if (mModule != NULL) {
|
||||
mResourceType = 2;
|
||||
}
|
||||
}
|
||||
if (mModule == NULL) {
|
||||
mModule = (OSModuleHeader*)JKRGetResource('DMEM', buffer, sArchive);
|
||||
if (mModule != NULL) {
|
||||
mResourceType = 3;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (mModule == NULL) {
|
||||
mModule = (OSModuleHeader*)sFileCache->getResource('rels', buffer);
|
||||
if (mModule != NULL) {
|
||||
mResourceType = 3;
|
||||
}
|
||||
}
|
||||
if (mModule == NULL) {
|
||||
// "DynamicModuleControl::do_load() Resource load failure [%s]\n"
|
||||
OSReport_Error("DynamicModuleControl::do_load() リソース読み込み失敗 [%s]\n", mName);
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
#else
|
||||
bool DynamicModuleControl::do_load() {
|
||||
if (mModule != NULL) {
|
||||
return true;
|
||||
@@ -287,6 +353,7 @@ bool DynamicModuleControl::do_load() {
|
||||
}
|
||||
return true;
|
||||
}
|
||||
#endif
|
||||
|
||||
BOOL DynamicModuleControl::do_load_async() {
|
||||
if (mAsyncLoadCallback == NULL) {
|
||||
@@ -312,12 +379,17 @@ BOOL DynamicModuleControl::do_load_async() {
|
||||
|
||||
bool DynamicModuleControl::do_unload() {
|
||||
if (mModule != NULL) {
|
||||
#if VERSION == VERSION_DEMO
|
||||
JKRFileLoader::removeResource(mModule, NULL);
|
||||
#else
|
||||
JKRFree(mModule);
|
||||
#endif
|
||||
mModule = NULL;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
#if VERSION != VERSION_DEMO
|
||||
void DynamicModuleControl::dump2() {
|
||||
if (mModule != NULL) {
|
||||
OSSectionInfo* section = (OSSectionInfo*)mModule->info.sectionInfoOffset;
|
||||
@@ -326,6 +398,7 @@ void DynamicModuleControl::dump2() {
|
||||
mModule->impSize);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
BOOL DynamicModuleControl::do_link() {
|
||||
OSGetTime();
|
||||
@@ -333,8 +406,10 @@ BOOL DynamicModuleControl::do_link() {
|
||||
do_load();
|
||||
}
|
||||
if (mModule != NULL) {
|
||||
JUT_ASSERT(613, mModule->info.sectionInfoOffset < 0x80000000);
|
||||
JUT_ASSERT(VERSION_SELECT(501, 613, 613, 613), mModule->info.sectionInfoOffset < 0x80000000);
|
||||
#if VERSION != VERSION_DEMO
|
||||
JUT_ASSERT(615, (u32)mModule + mModule->fixSize < 0x82000000);
|
||||
#endif
|
||||
OSGetTime();
|
||||
OSGetTime();
|
||||
if (mModule->info.version >= 3) {
|
||||
@@ -402,7 +477,7 @@ BOOL DynamicModuleControl::do_link() {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
JUT_ASSERT(724, FALSE);
|
||||
JUT_ASSERT(VERSION_SELECT(610, 724, 724, 724), FALSE);
|
||||
}
|
||||
OSGetTime();
|
||||
sAllocBytes = sAllocBytes + getModuleSize();
|
||||
@@ -413,13 +488,19 @@ BOOL DynamicModuleControl::do_link() {
|
||||
}
|
||||
|
||||
error:
|
||||
#if VERSION != VERSION_DEMO
|
||||
unk_33 = 0;
|
||||
#endif
|
||||
if (mBss != NULL) {
|
||||
JKRHeap::free(mBss, NULL);
|
||||
JKRFree(mBss);
|
||||
mBss = NULL;
|
||||
}
|
||||
if (mModule != NULL) {
|
||||
#if VERSION == VERSION_DEMO
|
||||
JKRFileLoader::removeResource(mModule, NULL);
|
||||
#else
|
||||
JKRHeap::free(mModule, NULL);
|
||||
#endif
|
||||
mModule = NULL;
|
||||
}
|
||||
return FALSE;
|
||||
@@ -484,7 +565,7 @@ extern "C" void ModuleUnresolved() {
|
||||
}
|
||||
|
||||
extern "C" void ModuleConstructorsX(void (**_ctors)()) {
|
||||
JUT_ASSERT(850, _ctors);
|
||||
JUT_ASSERT(VERSION_SELECT(726, 850, 850, 850), _ctors);
|
||||
while (*_ctors != 0) {
|
||||
(**_ctors)();
|
||||
_ctors++;
|
||||
@@ -492,7 +573,7 @@ extern "C" void ModuleConstructorsX(void (**_ctors)()) {
|
||||
}
|
||||
|
||||
extern "C" void ModuleDestructorsX(void (**_dtors)()) {
|
||||
JUT_ASSERT(864, _dtors);
|
||||
JUT_ASSERT(VERSION_SELECT(740, 864, 864, 864), _dtors);
|
||||
while (*_dtors != 0) {
|
||||
(**_dtors)();
|
||||
_dtors++;
|
||||
|
||||
@@ -138,7 +138,7 @@ JAIZelBasic::JAIZelBasic() {
|
||||
field_0x0200 = 0;
|
||||
field_0x0205 = 0;
|
||||
field_0x0066 = 0;
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
field_0x00bf = 0;
|
||||
field_0x0028 = 0;
|
||||
field_0x0062 = 0;
|
||||
@@ -248,7 +248,7 @@ void JAIZelBasic::resetRecover() {
|
||||
field_0x0206 = 0;
|
||||
field_0x0207 = 0;
|
||||
field_0x0201 = 0;
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
field_0x00bf = 0;
|
||||
#endif
|
||||
}
|
||||
@@ -995,7 +995,7 @@ void JAIZelBasic::setCameraGroupInfo(u8 param_1) {
|
||||
if (field_0x00bd) {
|
||||
return;
|
||||
}
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if (field_0x00bf) {
|
||||
return;
|
||||
}
|
||||
@@ -1041,7 +1041,7 @@ void JAIZelBasic::changeSeaBgm() {
|
||||
if (field_0x022d == 0) { return; }
|
||||
if (field_0x01f8 != 0) { return; }
|
||||
if (mbLandingDemoStarted) { return; }
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if (field_0x0062) { return; }
|
||||
#endif
|
||||
if (!checkDayTime() && checkSeaBgmID() != JA_BGM_SEA_STORM) { return; }
|
||||
@@ -1404,7 +1404,7 @@ void JAIZelBasic::setSceneName(char* param_1, s32 roomNo, s32 param_3) {
|
||||
}
|
||||
menuOut();
|
||||
field_0x0066 = 1;
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
field_0x00bf = 0;
|
||||
#endif
|
||||
} else {
|
||||
|
||||
@@ -431,7 +431,6 @@ u32 J3DMaterialFactory::calcSizeLockedMaterial(J3DMaterial* i_material, int i_id
|
||||
J3DGXColor J3DMaterialFactory::newMatColor(int idx, int stage) const {
|
||||
GXColor _ret = { 0xFF, 0xFF, 0xFF, 0xFF };
|
||||
J3DGXColor ret(_ret);
|
||||
J3DMaterialInitData* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mMatColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpMatColor[no];
|
||||
@@ -461,7 +460,6 @@ J3DColorChan J3DMaterialFactory::newColorChan(int idx, int stage) const {
|
||||
J3DGXColor J3DMaterialFactory::newAmbColor(int idx, int stage) const {
|
||||
GXColor _ret = { 0x32, 0x32, 0x32, 0x32 };
|
||||
J3DGXColor ret(_ret);
|
||||
J3DMaterialInitData* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mAmbColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpAmbColor[no];
|
||||
@@ -527,7 +525,6 @@ J3DTevOrder J3DMaterialFactory::newTevOrder(int idx, int stage) const {
|
||||
J3DGXColorS10 J3DMaterialFactory::newTevColor(int idx, int stage) const {
|
||||
GXColorS10 _ret = { 0x00, 0x00, 0x00, 0x00 };
|
||||
J3DGXColorS10 ret(_ret);
|
||||
J3DMaterialInitData* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mTevColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpTevColor[no];
|
||||
@@ -539,7 +536,6 @@ J3DGXColorS10 J3DMaterialFactory::newTevColor(int idx, int stage) const {
|
||||
J3DGXColor J3DMaterialFactory::newTevKColor(int idx, int stage) const {
|
||||
GXColor _ret = { 0xFF, 0xFF, 0xFF, 0xFF };
|
||||
J3DGXColor ret(_ret);
|
||||
J3DMaterialInitData* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mTevKColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpTevKColor[no];
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
#include "JSystem/J3DGraphLoader/J3DMaterialFactory_v21.h"
|
||||
#include "JSystem/J3DGraphLoader/J3DModelLoader.h"
|
||||
#include "JSystem/J3DGraphBase/J3DMatBlock.h"
|
||||
#include "JSystem/JMath/JMath.h"
|
||||
#include "JSystem/JSupport/JSupport.h"
|
||||
|
||||
/* 802F9A88-802F9C68 .text __ct__22J3DMaterialFactory_v21FRC20J3DMaterialBlock_v21 */
|
||||
@@ -172,7 +171,6 @@ J3DMaterial* J3DMaterialFactory_v21::create(J3DMaterial* i_material, int i_idx,
|
||||
J3DGXColor J3DMaterialFactory_v21::newMatColor(int idx, int stage) const {
|
||||
GXColor _ret = { 0xFF, 0xFF, 0xFF, 0xFF };
|
||||
J3DGXColor ret(_ret);
|
||||
J3DMaterialInitData_v21* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mMatColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpMatColor[no];
|
||||
@@ -256,7 +254,6 @@ J3DTevOrder J3DMaterialFactory_v21::newTevOrder(int idx, int stage) const {
|
||||
J3DGXColorS10 J3DMaterialFactory_v21::newTevColor(int idx, int stage) const {
|
||||
GXColorS10 _ret = { 0x00, 0x00, 0x00, 0x00 };
|
||||
J3DGXColorS10 ret(_ret);
|
||||
J3DMaterialInitData_v21* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mTevColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpTevColor[no];
|
||||
@@ -268,7 +265,6 @@ J3DGXColorS10 J3DMaterialFactory_v21::newTevColor(int idx, int stage) const {
|
||||
J3DGXColor J3DMaterialFactory_v21::newTevKColor(int idx, int stage) const {
|
||||
GXColor _ret = { 0xFF, 0xFF, 0xFF, 0xFF };
|
||||
J3DGXColor ret(_ret);
|
||||
J3DMaterialInitData_v21* initData = &mpMaterialInitData[mpMaterialID[idx]];
|
||||
u16 no = mpMaterialInitData[mpMaterialID[idx]].mTevKColorIdx[stage];
|
||||
if (no != 0xFFFF)
|
||||
return mpTevKColor[no];
|
||||
|
||||
@@ -75,7 +75,7 @@ JFWDisplay::~JFWDisplay() {
|
||||
|
||||
/* 80255354-802553EC .text createManager__10JFWDisplayFP7JKRHeapQ26JUTXfb10EXfbNumberb */
|
||||
JFWDisplay* JFWDisplay::createManager(JKRHeap* p_heap, JUTXfb::EXfbNumber xfb_num, bool enableAlpha) {
|
||||
JUT_CONFIRM(VERSION_SELECT(244, 243, 243), sManager == 0);
|
||||
JUT_CONFIRM(VERSION_SELECT(244, 244, 243, 243), sManager == 0);
|
||||
if(sManager == 0) {
|
||||
sManager = new JFWDisplay(0, p_heap, xfb_num, enableAlpha);
|
||||
}
|
||||
@@ -100,14 +100,14 @@ void JFWDisplay::prepareCopyDisp() {
|
||||
u16 width, height;
|
||||
JUTVideo::getManager()->getBounds(width, height);
|
||||
u16 xfb_height = JUTVideo::getManager()->getXfbHeight();
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
f32 y_scaleF = GXGetYScaleFactor(height, xfb_height);
|
||||
#endif
|
||||
|
||||
GXSetCopyClear(mClearColor, mZClear);
|
||||
GXSetDispCopySrc(0, 0, width, height);
|
||||
GXSetDispCopyDst(width, xfb_height);
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
GXSetDispCopyYScale(xfb_height / (f32)height);
|
||||
#else
|
||||
GXSetDispCopyYScale(y_scaleF);
|
||||
@@ -497,12 +497,12 @@ void JFWGXAbortAlarmHandler(OSAlarm*, OSContext*) {
|
||||
diagnoseGpHang();
|
||||
if(JFWAutoAbortGfx != 1) {
|
||||
OSReport("自動復帰しません\n");
|
||||
JUT_WARN(VERSION_SELECT(1351, 1350, 1350), "GP FREEZE!");
|
||||
JUT_ASSERT(VERSION_SELECT(1352, 1351, 1351), 0);
|
||||
JUT_WARN(VERSION_SELECT(1351, 1351, 1350, 1350), "GP FREEZE!");
|
||||
JUT_ASSERT(VERSION_SELECT(1352, 1352, 1351, 1351), 0);
|
||||
}
|
||||
else {
|
||||
OSReport("GXAbortFrame() を呼び出し、復帰します\n");
|
||||
JUT_WARN(VERSION_SELECT(1356, 1355, 1355), "GP FREEZE! AUTO RESUME");
|
||||
JUT_WARN(VERSION_SELECT(1356, 1356, 1355, 1355), "GP FREEZE! AUTO RESUME");
|
||||
GXAbortFrame();
|
||||
GXSetDrawDone();
|
||||
}
|
||||
|
||||
@@ -286,7 +286,7 @@ u8* JKRAram::aramToMainRam(JKRAramBlock* block, u8 *buf, u32 p3, u32 p4, JKRExpa
|
||||
}
|
||||
checkOkAddress(buf, 0, block, p4);
|
||||
if (!block) {
|
||||
OSPanic(__FILE__, VERSION_SELECT(690, 683, 683), ":::Bad Aram Block specified.\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(690, 690, 683, 683), ":::Bad Aram Block specified.\n");
|
||||
}
|
||||
if (p4 >= block->mSize) {
|
||||
return NULL;
|
||||
@@ -330,12 +330,12 @@ static int JKRDecompressFromAramToMainRam(u32 src, void* dst, u32 srcLength, u32
|
||||
|
||||
u32 szsBufferSize = JKRAram::getSzpBufferSize();
|
||||
szpBuf = (u8 *)JKRAllocFromSysHeap(szsBufferSize, 32);
|
||||
JUT_ASSERT(VERSION_SELECT(1091, 1077, 1077), szpBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(1091, 1091, 1077, 1077), szpBuf != NULL);
|
||||
|
||||
szpEnd = szpBuf + szsBufferSize;
|
||||
if (offset != 0) {
|
||||
refBuf = (u8 *)JKRAllocFromSysHeap(0x1120, 0);
|
||||
JUT_ASSERT(VERSION_SELECT(1100, 1086, 1086), refBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(1100, 1100, 1086, 1086), refBuf != NULL);
|
||||
refEnd = refBuf + 0x1120;
|
||||
refCurrent = refBuf;
|
||||
}
|
||||
@@ -523,7 +523,7 @@ static u8* nextSrcData(u8* current) {
|
||||
if (transSize > transLeft) {
|
||||
transSize = transLeft;
|
||||
}
|
||||
JUT_ASSERT(VERSION_SELECT(1376, 1361, 1361), transSize > 0);
|
||||
JUT_ASSERT(VERSION_SELECT(1376, 1376, 1361, 1361), transSize > 0);
|
||||
|
||||
JKRAramPcs(1, (u32)(srcAddress + srcOffset), ((u32)dest + left), ALIGN_NEXT(transSize, 0x20),
|
||||
NULL);
|
||||
|
||||
@@ -147,7 +147,7 @@ cleanup:
|
||||
JKRFreeToSysHeap(mem);
|
||||
}
|
||||
if (mMountMode == 0) {
|
||||
OSReport(":::[%s: %d] Cannot alloc memory\n", __FILE__, VERSION_SELECT(407, 400, 400));
|
||||
OSReport(":::[%s: %d] Cannot alloc memory\n", __FILE__, VERSION_SELECT(407, 407, 400, 400));
|
||||
if (mDvdFile != NULL) {
|
||||
delete mDvdFile;
|
||||
}
|
||||
@@ -158,7 +158,7 @@ cleanup:
|
||||
|
||||
/* 802BA4EC-802BA640 .text fetchResource__14JKRAramArchiveFPQ210JKRArchive12SDIFileEntryPUl */
|
||||
void* JKRAramArchive::fetchResource(SDIFileEntry* pEntry, u32* pOutSize) {
|
||||
JUT_ASSERT(VERSION_SELECT(434, 427, 427), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(434, 434, 427, 427), isMounted());
|
||||
u32 outSize;
|
||||
u8* outBuf;
|
||||
if (pOutSize == NULL) {
|
||||
@@ -193,7 +193,7 @@ void* JKRAramArchive::fetchResource(SDIFileEntry* pEntry, u32* pOutSize) {
|
||||
|
||||
/* 802BA640-802BA788 .text fetchResource__14JKRAramArchiveFPvUlPQ210JKRArchive12SDIFileEntryPUl */
|
||||
void* JKRAramArchive::fetchResource(void* buffer, u32 bufferSize, SDIFileEntry* pEntry, u32* resourceSize) {
|
||||
JUT_ASSERT(VERSION_SELECT(514, 500, 500), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(514, 514, 500, 500), isMounted());
|
||||
u32 size = pEntry->data_size;
|
||||
if (size > bufferSize) {
|
||||
size = bufferSize;
|
||||
@@ -223,7 +223,7 @@ void* JKRAramArchive::fetchResource(void* buffer, u32 bufferSize, SDIFileEntry*
|
||||
|
||||
/* 802BA788-802BA894 .text fetchResource_subroutine__14JKRAramArchiveFUlUlPUcUli */
|
||||
u32 JKRAramArchive::fetchResource_subroutine(u32 srcAram, u32 srcLength, u8* dst, u32 dstLength, int compression) {
|
||||
JUT_ASSERT(VERSION_SELECT(627, 613, 613), ( srcAram & 0x1f ) == 0);
|
||||
JUT_ASSERT(VERSION_SELECT(627, 627, 613, 613), ( srcAram & 0x1f ) == 0);
|
||||
u32 outLen;
|
||||
u32 srcSize = ALIGN_NEXT(srcLength, 0x20);
|
||||
u32 dstSize = ALIGN_PREV(dstLength, 0x20);
|
||||
@@ -240,7 +240,7 @@ u32 JKRAramArchive::fetchResource_subroutine(u32 srcAram, u32 srcLength, u8* dst
|
||||
JKRAramToMainRam(srcAram, dst, srcSize, EXPAND_SWITCH_UNKNOWN1, dstSize, NULL, -1, &outLen);
|
||||
return outLen;
|
||||
default:
|
||||
OSPanic(__FILE__, VERSION_SELECT(654, 640, 640), ":::??? bad sequence\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(654, 654, 640, 640), ":::??? bad sequence\n");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
@@ -254,7 +254,7 @@ u32 JKRAramArchive::fetchResource_subroutine(u32 entryNum, u32 length, JKRHeap*
|
||||
case COMPRESSION_NONE:
|
||||
{
|
||||
buffer = (u8*)(JKRAllocFromHeap(pHeap, alignedLen, 0x20));
|
||||
JUT_ASSERT(VERSION_SELECT(676, 662, 662), buffer != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(676, 676, 662, 662), buffer != NULL);
|
||||
JKRAramToMainRam(entryNum, buffer, alignedLen, EXPAND_SWITCH_UNKNOWN0, alignedLen, NULL, -1, NULL);
|
||||
*out = buffer;
|
||||
return length;
|
||||
@@ -267,14 +267,14 @@ u32 JKRAramArchive::fetchResource_subroutine(u32 entryNum, u32 length, JKRHeap*
|
||||
JKRAramToMainRam(entryNum, alignHeader, sizeof(SArcHeader), EXPAND_SWITCH_UNKNOWN0, 0, NULL, -1, NULL);
|
||||
u32 decompressedLen = ALIGN_NEXT(JKRDecompExpandSize(alignHeader), sizeof(SArcHeader));
|
||||
buffer = (u8*)(JKRAllocFromHeap(pHeap, decompressedLen, sizeof(SArcHeader)));
|
||||
JUT_ASSERT(VERSION_SELECT(709, 688, 688), buffer);
|
||||
JUT_ASSERT(VERSION_SELECT(709, 709, 688, 688), buffer);
|
||||
u32 readLen;
|
||||
JKRAramToMainRam(entryNum, buffer, alignedLen, EXPAND_SWITCH_UNKNOWN1, decompressedLen, pHeap, -1, &readLen);
|
||||
*out = buffer;
|
||||
return readLen;
|
||||
}
|
||||
default:
|
||||
OSPanic(__FILE__, VERSION_SELECT(719, 698, 698), ":::??? bad sequence\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(719, 719, 698, 698), ":::??? bad sequence\n");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -134,7 +134,7 @@ void* JKRArchive::getGlbResource(u32 param_0, const char* path, JKRArchive* arch
|
||||
|
||||
/* 802B8380-802B8450 .text getResource__10JKRArchiveFPCc */
|
||||
void* JKRArchive::getResource(const char* path) {
|
||||
JUT_ASSERT(VERSION_SELECT(337, 285, 285), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(337, 337, 285, 285), isMounted());
|
||||
|
||||
SDIFileEntry* fileEntry;
|
||||
if (*path == '/') {
|
||||
@@ -152,7 +152,7 @@ void* JKRArchive::getResource(const char* path) {
|
||||
|
||||
/* 802B8450-802B8528 .text getResource__10JKRArchiveFUlPCc */
|
||||
void* JKRArchive::getResource(u32 type, const char* path) {
|
||||
JUT_ASSERT(VERSION_SELECT(384, 332, 332), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(384, 384, 332, 332), isMounted());
|
||||
|
||||
SDIFileEntry* fileEntry;
|
||||
if (type == 0 || type == '\?\?\?\?') {
|
||||
@@ -190,7 +190,7 @@ u32 JKRArchive::readTypeResource(void* buffer, u32 bufferSize, u32 type, const c
|
||||
|
||||
/* 802B85F0-802B86DC .text readResource__10JKRArchiveFPvUlUlPCc */
|
||||
u32 JKRArchive::readResource(void* buffer, u32 bufferSize, u32 type, const char* path) {
|
||||
JUT_ASSERT(VERSION_SELECT(543, 491, 491), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(543, 543, 491, 491), isMounted());
|
||||
|
||||
SDIFileEntry* fileEntry;
|
||||
if (type == 0 || type == '\?\?\?\?') {
|
||||
@@ -210,7 +210,7 @@ u32 JKRArchive::readResource(void* buffer, u32 bufferSize, u32 type, const char*
|
||||
|
||||
/* 802B86DC-802B87C0 .text readResource__10JKRArchiveFPvUlPCc */
|
||||
u32 JKRArchive::readResource(void* buffer, u32 bufferSize, const char* path) {
|
||||
JUT_ASSERT(VERSION_SELECT(589, 537, 537), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(589, 589, 537, 537), isMounted());
|
||||
|
||||
SDIFileEntry* fileEntry;
|
||||
if (*path == '/') {
|
||||
@@ -230,7 +230,7 @@ u32 JKRArchive::readResource(void* buffer, u32 bufferSize, const char* path) {
|
||||
|
||||
/* 802B87C0-802B8878 .text readIdxResource__10JKRArchiveFPvUlUl */
|
||||
u32 JKRArchive::readIdxResource(void* buffer, u32 bufferSize, u32 index) {
|
||||
JUT_ASSERT(VERSION_SELECT(645, 593, 593), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(645, 645, 593, 593), isMounted());
|
||||
|
||||
SDIFileEntry* fileEntry = findIdxResource(index);
|
||||
if (fileEntry) {
|
||||
@@ -244,7 +244,7 @@ u32 JKRArchive::readIdxResource(void* buffer, u32 bufferSize, u32 index) {
|
||||
|
||||
/* 802B8878-802B8930 .text readResource__10JKRArchiveFPvUlUs */
|
||||
u32 JKRArchive::readResource(void* buffer, u32 bufferSize, u16 id) {
|
||||
JUT_ASSERT(VERSION_SELECT(679, 627, 627), isMounted());
|
||||
JUT_ASSERT(VERSION_SELECT(679, 679, 627, 627), isMounted());
|
||||
|
||||
SDIFileEntry* fileEntry = findIdResource(id);
|
||||
if (fileEntry) {
|
||||
@@ -271,7 +271,7 @@ void JKRArchive::removeResourceAll() {
|
||||
|
||||
/* 802B89B8-802B8A54 .text removeResource__10JKRArchiveFPv */
|
||||
bool JKRArchive::removeResource(void* resource) {
|
||||
JUT_ASSERT(VERSION_SELECT(755, 687, 687), resource != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(755, 755, 687, 687), resource != NULL);
|
||||
|
||||
SDIFileEntry* fileEntry = findPtrResource(resource);
|
||||
if (fileEntry == NULL)
|
||||
@@ -284,7 +284,7 @@ bool JKRArchive::removeResource(void* resource) {
|
||||
|
||||
/* 802B8A54-802B8AE4 .text detachResource__10JKRArchiveFPv */
|
||||
bool JKRArchive::detachResource(void* resource) {
|
||||
JUT_ASSERT(VERSION_SELECT(787, 719, 719), resource != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(787, 787, 719, 719), resource != NULL);
|
||||
|
||||
SDIFileEntry* fileEntry = findPtrResource(resource);
|
||||
if (fileEntry == NULL)
|
||||
@@ -296,7 +296,7 @@ bool JKRArchive::detachResource(void* resource) {
|
||||
|
||||
/* 802B8AE4-802B8B6C .text getResSize__10JKRArchiveCFPCv */
|
||||
u32 JKRArchive::getResSize(const void* resource) const {
|
||||
JUT_ASSERT(VERSION_SELECT(814, 746, 746), resource != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(814, 814, 746, 746), resource != NULL);
|
||||
|
||||
SDIFileEntry* fileEntry = findPtrResource(resource);
|
||||
if (fileEntry == NULL)
|
||||
|
||||
@@ -381,7 +381,7 @@ u32 JKRCompArchive::getExpandedResSize(const void* resource) const {
|
||||
JKRDvdToMainRam(mEntryNum, bufPtr, EXPAND_SWITCH_UNKNOWN2, sizeof(buf) / 2, NULL, JKRDvdRipper::ALLOC_DIRECTION_FORWARD, field_0x6c + fileEntry->data_offset, NULL);
|
||||
DCInvalidateRange(bufPtr, sizeof(buf) / 2);
|
||||
} else {
|
||||
OSPanic(__FILE__, VERSION_SELECT(948, 944, 944), "illegal resource.");
|
||||
OSPanic(__FILE__, VERSION_SELECT(948, 948, 944, 944), "illegal resource.");
|
||||
}
|
||||
u32 expandSize = JKRDecompExpandSize(bufPtr);
|
||||
const_cast<JKRCompArchive *>(this)->setExpandSize(fileEntry, expandSize);
|
||||
|
||||
@@ -249,14 +249,14 @@ static int JKRDecompressFromDVDToAram(JKRDvdFile* dvdFile, u32 param_1, u32 file
|
||||
OSLockMutex(&decompMutex);
|
||||
u32 bufferSize = JKRDvdAramRipper::getSzpBufferSize();
|
||||
szpBuf = (u8*)JKRAllocFromSysHeap(bufferSize, 0x20);
|
||||
JUT_ASSERT(VERSION_SELECT(703, 693, 693), szpBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(703, 703, 693, 693), szpBuf != NULL);
|
||||
szpEnd = szpBuf + bufferSize;
|
||||
refBuf = (u8*)JKRAllocFromSysHeap(0x1120, 0);
|
||||
JUT_ASSERT(VERSION_SELECT(711, 701, 701), refBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(711, 711, 701, 701), refBuf != NULL);
|
||||
refEnd = refBuf + 0x1120;
|
||||
refCurrent = refBuf;
|
||||
dmaBuf = (u8*)JKRAllocFromSysHeap(0x100, 0x20);
|
||||
JUT_ASSERT(VERSION_SELECT(720, 710, 710), dmaBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(720, 720, 710, 710), dmaBuf != NULL);
|
||||
dmaEnd = dmaBuf + 0x100;
|
||||
dmaCurrent = dmaBuf;
|
||||
srcFile = dvdFile;
|
||||
@@ -398,7 +398,7 @@ static u8* nextSrcData(u8* src) {
|
||||
if (transSize > transLeft) {
|
||||
transSize = transLeft;
|
||||
}
|
||||
JUT_ASSERT(VERSION_SELECT(979, 966, 966), transSize > 0);
|
||||
JUT_ASSERT(VERSION_SELECT(979, 979, 966, 966), transSize > 0);
|
||||
while (true) {
|
||||
s32 result = DVDReadPrio(&srcFile->mFileInfo, dest + size, transSize, srcOffset, 2);
|
||||
if (result >= 0) {
|
||||
|
||||
@@ -264,12 +264,12 @@ u32 JKRDvdArchive::fetchResource_subroutine(s32 entryNum, u32 offset, u32 size,
|
||||
}
|
||||
|
||||
case COMPRESSION_YAY0: {
|
||||
OSPanic(__FILE__, VERSION_SELECT(610, 603, 603), "Sorry, not prepared for SZP archive.\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(610, 610, 603, 603), "Sorry, not prepared for SZP archive.\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
default: {
|
||||
OSPanic(__FILE__, VERSION_SELECT(616, 609, 609), ":::??? bad sequence\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(616, 616, 609, 609), ":::??? bad sequence\n");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
@@ -285,7 +285,7 @@ u32 JKRDvdArchive::fetchResource_subroutine(s32 entryNum, u32 offset, u32 size,
|
||||
switch (fileCompression) {
|
||||
case COMPRESSION_NONE:
|
||||
buffer = (u8*)JKRAllocFromHeap(heap, alignedSize, sizeof(SArcHeader));
|
||||
JUT_ASSERT(VERSION_SELECT(638, 631, 631), buffer != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(638, 638, 631, 631), buffer != NULL);
|
||||
|
||||
JKRDvdToMainRam(entryNum, buffer, EXPAND_SWITCH_UNKNOWN0, alignedSize, NULL,
|
||||
JKRDvdRipper::ALLOC_DIRECTION_FORWARD, offset, NULL);
|
||||
@@ -304,7 +304,7 @@ u32 JKRDvdArchive::fetchResource_subroutine(s32 entryNum, u32 offset, u32 size,
|
||||
|
||||
alignedSize = JKRDecompExpandSize(arcHeader);
|
||||
buffer = (u8*)JKRAllocFromHeap(heap, alignedSize, sizeof(SArcHeader));
|
||||
JUT_ASSERT(VERSION_SELECT(674, 660, 660), buffer);
|
||||
JUT_ASSERT(VERSION_SELECT(674, 674, 660, 660), buffer);
|
||||
JKRDvdToMainRam(entryNum, buffer, EXPAND_SWITCH_UNKNOWN1, alignedSize, NULL,
|
||||
JKRDvdRipper::ALLOC_DIRECTION_FORWARD, offset, NULL);
|
||||
|
||||
@@ -315,7 +315,7 @@ u32 JKRDvdArchive::fetchResource_subroutine(s32 entryNum, u32 offset, u32 size,
|
||||
|
||||
case COMPRESSION_YAZ0: {
|
||||
buffer = (u8*)JKRAllocFromHeap(heap, alignedSize, sizeof(SArcHeader));
|
||||
JUT_ASSERT(VERSION_SELECT(686, 672, 672), buffer);
|
||||
JUT_ASSERT(VERSION_SELECT(686, 686, 672, 672), buffer);
|
||||
|
||||
JKRDvdToMainRam(entryNum, buffer, EXPAND_SWITCH_UNKNOWN1, size, NULL,
|
||||
JKRDvdRipper::ALLOC_DIRECTION_FORWARD, offset, NULL);
|
||||
@@ -325,12 +325,12 @@ u32 JKRDvdArchive::fetchResource_subroutine(s32 entryNum, u32 offset, u32 size,
|
||||
}
|
||||
|
||||
case COMPRESSION_YAY0: {
|
||||
OSPanic(__FILE__, VERSION_SELECT(697, 683, 683), "Sorry, not prepared for SZP archive.\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(697, 697, 683, 683), "Sorry, not prepared for SZP archive.\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
default: {
|
||||
OSPanic(__FILE__, VERSION_SELECT(702, 688, 688), ":::??? bad sequence\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(702, 702, 688, 688), ":::??? bad sequence\n");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -148,7 +148,7 @@ void* JKRDvdRipper::loadToMainRAM(JKRDvdFile* dvdFile, u8* dst, JKRExpandSwitch
|
||||
else if (compression2 == COMPRESSION_YAZ0) {
|
||||
JKRDecompressFromDVD(dvdFile, dst, fileSizeAligned, dstLength, 0, offset);
|
||||
} else {
|
||||
OSPanic(__FILE__, VERSION_SELECT(337, 314, 314), "Sorry, not prepared for SZP resource\n");
|
||||
OSPanic(__FILE__, VERSION_SELECT(337, 337, 314, 314), "Sorry, not prepared for SZP resource\n");
|
||||
}
|
||||
return dst;
|
||||
}
|
||||
@@ -157,7 +157,7 @@ void* JKRDvdRipper::loadToMainRAM(JKRDvdFile* dvdFile, u8* dst, JKRExpandSwitch
|
||||
// SZP decompression
|
||||
// s32 readoffset = startOffset;
|
||||
if (offset != 0) {
|
||||
OSPanic(__FILE__, VERSION_SELECT(347, 324, 324), ":::Not support SZP with offset read");
|
||||
OSPanic(__FILE__, VERSION_SELECT(347, 347, 324, 324), ":::Not support SZP with offset read");
|
||||
}
|
||||
while (true) {
|
||||
int readBytes = DVDReadPrio(dvdFile->getFileInfo(), mem, fileSizeAligned, 0, 2);
|
||||
@@ -221,12 +221,12 @@ static int JKRDecompressFromDVD(JKRDvdFile* dvdFile, void* dst, u32 fileSize, u3
|
||||
OSLockMutex(&decompMutex);
|
||||
int bufSize = JKRDvdRipper::getSzpBufferSize();
|
||||
szpBuf = (u8 *)JKRAllocFromSysHeap(bufSize, -0x20);
|
||||
JUT_ASSERT(VERSION_SELECT(913, 884, 884), szpBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(913, 913, 884, 884), szpBuf != NULL);
|
||||
|
||||
szpEnd = szpBuf + bufSize;
|
||||
if (inFileOffset != 0) {
|
||||
refBuf = (u8 *)JKRAllocFromSysHeap(0x1120, -4);
|
||||
JUT_ASSERT(VERSION_SELECT(922, 893, 893), refBuf != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(922, 922, 893, 893), refBuf != NULL);
|
||||
refEnd = refBuf + 0x1120;
|
||||
refCurrent = refBuf;
|
||||
} else {
|
||||
@@ -407,7 +407,7 @@ static u8* nextSrcData(u8* src) {
|
||||
if (transSize > transLeft) {
|
||||
transSize = transLeft;
|
||||
}
|
||||
JUT_ASSERT(VERSION_SELECT(1228, 1176, 1176), transSize > 0);
|
||||
JUT_ASSERT(VERSION_SELECT(1228, 1228, 1176, 1176), transSize > 0);
|
||||
|
||||
while (true) {
|
||||
s32 result = DVDReadPrio(srcFile->getFileInfo(), (buf + limit), transSize, srcOffset, 2);
|
||||
|
||||
@@ -955,8 +955,8 @@ static void dummy2() {
|
||||
|
||||
/* 802B30A4-802B31D4 .text state_register__10JKRExpHeapCFPQ27JKRHeap6TStateUl */
|
||||
void JKRExpHeap::state_register(TState* p, u32 param_1) const {
|
||||
JUT_ASSERT(VERSION_SELECT(2420, 2423, 2423), p != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(2421, 2424, 2424), p->getHeap() == this);
|
||||
JUT_ASSERT(VERSION_SELECT(2420, 2420, 2423, 2423), p != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(2421, 2421, 2424, 2424), p->getHeap() == this);
|
||||
p->mId = param_1;
|
||||
if (param_1 <= 0xff) {
|
||||
p->mUsedSize = getUsedSize(param_1);
|
||||
@@ -981,7 +981,7 @@ void JKRExpHeap::state_register(TState* p, u32 param_1) const {
|
||||
|
||||
/* 802B31D4-802B327C .text state_compare__10JKRExpHeapCFRCQ27JKRHeap6TStateRCQ27JKRHeap6TState */
|
||||
bool JKRExpHeap::state_compare(const JKRHeap::TState& r1, const JKRHeap::TState& r2) const {
|
||||
JUT_ASSERT(VERSION_SELECT(2468, 2471, 2471), r1.getHeap() == r2.getHeap());
|
||||
JUT_ASSERT(VERSION_SELECT(2468, 2468, 2471, 2471), r1.getHeap() == r2.getHeap());
|
||||
bool result = true;
|
||||
if (r1.mCheckCode != r2.mCheckCode) {
|
||||
result = false;
|
||||
|
||||
@@ -407,7 +407,7 @@ void operator delete[](void* ptr) {
|
||||
}
|
||||
|
||||
static void dummy3() {
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
OSReport("\x1B[41;37m:::addr %08x size %08x: Freeされた領域が浸食されている (%08x=%02x)\n\x1B[m");
|
||||
#endif
|
||||
OSReport("%s");
|
||||
@@ -420,13 +420,13 @@ static void dummy3() {
|
||||
|
||||
/* 802B0D70-802B0E14 .text state_register__7JKRHeapCFPQ27JKRHeap6TStateUl */
|
||||
void JKRHeap::state_register(JKRHeap::TState* p, u32 id) const {
|
||||
JUT_ASSERT(VERSION_SELECT(1034, 1090, 1090), p != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(1035, 1091, 1091), p->getHeap() == this);
|
||||
JUT_ASSERT(VERSION_SELECT(1034, 1034, 1090, 1090), p != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(1035, 1035, 1091, 1091), p->getHeap() == this);
|
||||
}
|
||||
|
||||
/* 802B0E14-802B0E9C .text state_compare__7JKRHeapCFRCQ27JKRHeap6TStateRCQ27JKRHeap6TState */
|
||||
bool JKRHeap::state_compare(const JKRHeap::TState& r1, const JKRHeap::TState& r2) const {
|
||||
JUT_ASSERT(VERSION_SELECT(1043, 1099, 1099), r1.getHeap() == r2.getHeap());
|
||||
JUT_ASSERT(VERSION_SELECT(1043, 1043, 1099, 1099), r1.getHeap() == r2.getHeap());
|
||||
return r1.getCheckCode() == r2.getCheckCode();
|
||||
}
|
||||
|
||||
@@ -439,9 +439,9 @@ static void dummy4() {
|
||||
|
||||
/* 802B0E9C-802B0F24 .text state_dump__7JKRHeapCFRCQ27JKRHeap6TState */
|
||||
void JKRHeap::state_dump(const JKRHeap::TState& p) const {
|
||||
JUT_LOG(VERSION_SELECT(1067, 1123, 1123), "check-code : 0x%08x", p.getCheckCode());
|
||||
JUT_LOG(VERSION_SELECT(1068, 1124, 1124), "id : 0x%08x", p.getId());
|
||||
JUT_LOG(VERSION_SELECT(1069, 1125, 1125), "used size : %u", p.getUsedSize());
|
||||
JUT_LOG(VERSION_SELECT(1067, 1067, 1123, 1123), "check-code : 0x%08x", p.getCheckCode());
|
||||
JUT_LOG(VERSION_SELECT(1068, 1068, 1124, 1124), "id : 0x%08x", p.getId());
|
||||
JUT_LOG(VERSION_SELECT(1069, 1069, 1125, 1125), "used size : %u", p.getUsedSize());
|
||||
}
|
||||
|
||||
/* 802B0F24-802B0F2C .text do_changeGroupID__7JKRHeapFUc */
|
||||
@@ -454,7 +454,7 @@ u8 JKRHeap::do_getCurrentGroupId() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
static void dummy5() {
|
||||
OSReport("\x1B[41;37m:::addr %08x size %08x: Freeされた領域が浸食されている (%08x=%02x)\n\x1B[m");
|
||||
}
|
||||
|
||||
@@ -236,8 +236,8 @@ bool JKRSolidHeap::dump() {
|
||||
|
||||
/* 802B3A68-802B3B4C .text state_register__12JKRSolidHeapCFPQ27JKRHeap6TStateUl */
|
||||
void JKRSolidHeap::state_register(JKRHeap::TState* p, u32 id) const {
|
||||
JUT_ASSERT(VERSION_SELECT(610, 607, 607), p != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(611, 608, 608), p->getHeap() == this);
|
||||
JUT_ASSERT(VERSION_SELECT(610, 610, 607, 607), p != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(611, 611, 608, 608), p->getHeap() == this);
|
||||
|
||||
getState_(p);
|
||||
setState_u32ID_(p, id);
|
||||
@@ -249,7 +249,7 @@ void JKRSolidHeap::state_register(JKRHeap::TState* p, u32 id) const {
|
||||
|
||||
/* 802B3B4C-802B3BF4 .text state_compare__12JKRSolidHeapCFRCQ27JKRHeap6TStateRCQ27JKRHeap6TState */
|
||||
bool JKRSolidHeap::state_compare(const JKRHeap::TState& r1, const JKRHeap::TState& r2) const {
|
||||
JUT_ASSERT(VERSION_SELECT(638, 635, 635), r1.getHeap() == r2.getHeap());
|
||||
JUT_ASSERT(VERSION_SELECT(638, 638, 635, 635), r1.getHeap() == r2.getHeap());
|
||||
|
||||
bool result = true;
|
||||
if (r1.getCheckCode() != r2.getCheckCode()) {
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#include "dolphin/vi/vi.h"
|
||||
|
||||
struct CallbackObject {
|
||||
/* 0x00 */ OSErrorHandler callback;
|
||||
/* 0x00 */ JUTExceptionUserCallback callback;
|
||||
/* 0x04 */ u16 error;
|
||||
/* 0x06 */ u16 pad_0x06;
|
||||
/* 0x08 */ OSContext* context;
|
||||
@@ -49,17 +49,17 @@ const char* JUTException::sCpuExpName[] = {
|
||||
"FLOATING POINT",
|
||||
};
|
||||
JUTException* JUTException::sErrorManager;
|
||||
OSErrorHandler JUTException::sPreUserCallback;
|
||||
OSErrorHandler JUTException::sPostUserCallback;
|
||||
JUTExceptionUserCallback JUTException::sPreUserCallback;
|
||||
JUTExceptionUserCallback JUTException::sPostUserCallback;
|
||||
|
||||
/* 802C4AC8-802C4BAC .text __ct__12JUTExceptionFP14JUTDirectPrint */
|
||||
JUTException::JUTException(JUTDirectPrint* directPrint) : JKRThread(0x4000, 0x10, 0) {
|
||||
mDirectPrint = directPrint;
|
||||
OSSetErrorHandler(EXCEPTION_DSI, errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_ISI, errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_PROGRAM, errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_ALIGNMENT, errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_MEMORY_PROTECTION, errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_DSI, (OSErrorHandler)errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_ISI, (OSErrorHandler)errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_PROGRAM, (OSErrorHandler)errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_ALIGNMENT, (OSErrorHandler)errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_MEMORY_PROTECTION, (OSErrorHandler)errorHandler);
|
||||
setFPException(0);
|
||||
|
||||
sPreUserCallback = NULL;
|
||||
@@ -96,7 +96,7 @@ void* JUTException::run() {
|
||||
while (true) {
|
||||
OSReceiveMessage(&sMessageQueue, &message, OS_MESSAGE_BLOCK);
|
||||
CallbackObject* cb = (CallbackObject*)message;
|
||||
OSErrorHandler callback = cb->callback;
|
||||
JUTExceptionUserCallback callback = cb->callback;
|
||||
u16 error = cb->error;
|
||||
OSContext* context = cb->context;
|
||||
int r24 = cb->param_3;
|
||||
@@ -214,7 +214,7 @@ void JUTException::errorHandler(OSError error, OSContext* context, u32 param_3,
|
||||
void JUTException::setFPException(u32 fpscr_enable_bits) {
|
||||
__OSFpscrEnableBits = fpscr_enable_bits;
|
||||
if (fpscr_enable_bits) {
|
||||
OSSetErrorHandler(EXCEPTION_FLOATING_POINT_EXCEPTION, errorHandler);
|
||||
OSSetErrorHandler(EXCEPTION_FLOATING_POINT_EXCEPTION, (OSErrorHandler)errorHandler);
|
||||
} else {
|
||||
OSSetErrorHandler(EXCEPTION_FLOATING_POINT_EXCEPTION, NULL);
|
||||
}
|
||||
@@ -802,15 +802,15 @@ void JUTException::createFB() {
|
||||
}
|
||||
|
||||
/* 802C6868-802C6878 .text setPreUserCallback__12JUTExceptionFPFUsP9OSContextUlUl_v */
|
||||
OSErrorHandler JUTException::setPreUserCallback(OSErrorHandler callback) {
|
||||
OSErrorHandler previous = sPreUserCallback;
|
||||
JUTExceptionUserCallback JUTException::setPreUserCallback(JUTExceptionUserCallback callback) {
|
||||
JUTExceptionUserCallback previous = sPreUserCallback;
|
||||
sPreUserCallback = callback;
|
||||
return previous;
|
||||
}
|
||||
|
||||
/* 802C6878-802C6888 .text setPostUserCallback__12JUTExceptionFPFUsP9OSContextUlUl_v */
|
||||
OSErrorHandler JUTException::setPostUserCallback(OSErrorHandler callback) {
|
||||
OSErrorHandler previous = sPostUserCallback;
|
||||
JUTExceptionUserCallback JUTException::setPostUserCallback(JUTExceptionUserCallback callback) {
|
||||
JUTExceptionUserCallback previous = sPostUserCallback;
|
||||
sPostUserCallback = callback;
|
||||
return previous;
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ JUTXfb::JUTXfb(const GXRenderModeObj* pObj, JKRHeap* pHeap, JUTXfb::EXfbNumber x
|
||||
if (pObj) {
|
||||
initiate(pObj->fb_width, pObj->xfb_height, pHeap, xfbNum);
|
||||
} else {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
GXRenderModeObj* obj = JUTVideo::getManager()->getRenderMode();
|
||||
initiate(obj->fb_width, obj->xfb_height, pHeap, xfbNum);
|
||||
#else
|
||||
@@ -63,7 +63,7 @@ void JUTXfb::delXfb(int xfbIdx) {
|
||||
|
||||
/* 802C837C-802C8410 .text createManager__6JUTXfbFPC16_GXRenderModeObjP7JKRHeapQ26JUTXfb10EXfbNumber */
|
||||
JUTXfb* JUTXfb::createManager(const GXRenderModeObj* pObj, JKRHeap* pHeap, JUTXfb::EXfbNumber xfbNum) {
|
||||
JUT_CONFIRM(VERSION_SELECT(198, 203, 203), sManager == 0);
|
||||
JUT_CONFIRM(VERSION_SELECT(198, 198, 203, 203), sManager == 0);
|
||||
if (sManager == NULL) {
|
||||
sManager = new JUTXfb(pObj, pHeap, xfbNum);
|
||||
}
|
||||
@@ -72,7 +72,7 @@ JUTXfb* JUTXfb::createManager(const GXRenderModeObj* pObj, JKRHeap* pHeap, JUTXf
|
||||
|
||||
/* 802C8410-802C8468 .text destroyManager__6JUTXfbFv */
|
||||
void JUTXfb::destroyManager() {
|
||||
JUT_CONFIRM(VERSION_SELECT(339, 344, 344), sManager);
|
||||
JUT_CONFIRM(VERSION_SELECT(339, 339, 344, 344), sManager);
|
||||
delete sManager;
|
||||
sManager = NULL;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#ifndef _MSL_COMMON_ANSI_FP_H
|
||||
#define _MSL_COMMON_ANSI_FP_H
|
||||
|
||||
#include "dolphin/types.h"
|
||||
#include "float.h"
|
||||
|
||||
#define SIGDIGLEN 36
|
||||
@@ -22,7 +23,7 @@ typedef struct decform {
|
||||
short digits;
|
||||
} decform;
|
||||
|
||||
/* void __ull2dec(decimal*, u64);
|
||||
void __ull2dec(decimal*, u64);
|
||||
void __timesdec(decimal*, const decimal*, const decimal*);
|
||||
void __str2dec(decimal*, const char*, short);
|
||||
void __two_exp(decimal*, s16);
|
||||
@@ -31,6 +32,6 @@ BOOL __less_dec(const decimal*, const decimal*);
|
||||
void __minus_dec(decimal*, const decimal*, const decimal*);
|
||||
void __num2dec_internal(decimal*, f64);
|
||||
void __num2dec(const decform*, f64, decimal*);
|
||||
f64 __dec2num(const decimal*); */
|
||||
f64 __dec2num(const decimal*);
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "stdlib.h"
|
||||
#include "string.h"
|
||||
#include "wchar_io.h"
|
||||
#include "ansi_fp.h"
|
||||
|
||||
#define TARGET_FLOAT_BITS 64
|
||||
#define TARGET_FLOAT_BYTES (TARGET_FLOAT_BITS / 8)
|
||||
|
||||
+2
-1
@@ -40,6 +40,7 @@
|
||||
*/
|
||||
|
||||
#include "fdlibm.h"
|
||||
#include "math.h"
|
||||
|
||||
#ifdef __STDC__
|
||||
static const double
|
||||
@@ -140,4 +141,4 @@ double __ieee754_atan2(y, x) double y, x;
|
||||
default: /* case 3 */
|
||||
return (z - pi_lo) - pi; /* atan(-,-) */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+2
-1
@@ -33,6 +33,7 @@
|
||||
*/
|
||||
|
||||
#include "fdlibm.h"
|
||||
#include "math.h"
|
||||
|
||||
#ifdef __STDC__
|
||||
static const double atanhi[] = {
|
||||
@@ -140,4 +141,4 @@ double atan(x) double x;
|
||||
z = atanhi[id] - ((x * (s1 + s2) - atanlo[id]) - x);
|
||||
return (hx < 0) ? -z : z;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,9 +22,11 @@ static int fragmentID = -2;
|
||||
|
||||
/* clang-format off */
|
||||
static ASM char* GetR2() {
|
||||
#ifdef __MWERKS__
|
||||
nofralloc;
|
||||
mr r3, r2
|
||||
blr
|
||||
#endif
|
||||
}
|
||||
/* clang-format on */
|
||||
|
||||
|
||||
@@ -128,7 +128,7 @@ bool cBgS::LineCross(cBgS_LinChk* chk) {
|
||||
|
||||
/* 802468E4-80246A14 .text GroundCross__4cBgSFP11cBgS_GndChk */
|
||||
f32 cBgS::GroundCross(cBgS_GndChk* chk) {
|
||||
chk->SetNowY(C_BG_MIN_HEIGHT);
|
||||
chk->SetNowY(-G_CM3D_F_INF);
|
||||
chk->ClearPi();
|
||||
chk->mWallPrecheck = (chk->mFlag & 0x02);
|
||||
chk->mGndPrecheck = (chk->mFlag & 0x01);
|
||||
|
||||
@@ -21,6 +21,9 @@
|
||||
#define CHECK_PVEC3_RANGE(line, v) JUT_ASSERT(line, -1.0e32f < v->x && v->x < 1.0e32f && -1.0e32f < v->y && v->y < 1.0e32f && -1.0e32f < v->z && v->z < 1.0e32f)
|
||||
|
||||
const f32 G_CM3D_F_ABS_MIN = 3.8146973e-06f;
|
||||
#if VERSION == VERSION_DEMO
|
||||
const f32 G_CM3D_F_INF = 1.0e38f;
|
||||
#endif
|
||||
|
||||
static void dummy(f32 dummy) {
|
||||
// to fix float literal order
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#define CHECK_FLOAT_RANGE(line, x) JUT_ASSERT(line, -1.0e32f < x && x < 1.0e32f);
|
||||
#define CHECK_VEC3_RANGE(line, v) JUT_ASSERT(line, -1.0e32f < v.x && v.x < 1.0e32f && -1.0e32f < v.y && v.y < 1.0e32f && -1.0e32f < v.z && v.z < 1.0e32f)
|
||||
|
||||
#if VERSION > VERSION_DEMO
|
||||
/* 80251D88-80252020 .text SetC__8cM3dGCylFRC4cXyz */
|
||||
void cM3dGCyl::SetC(const cXyz& pos) {
|
||||
CHECK_FLOAT_CLASS(21, pos.x);
|
||||
@@ -33,6 +34,7 @@ void cM3dGCyl::SetR(f32 r) {
|
||||
CHECK_FLOAT_RANGE(49, r);
|
||||
mRadius = r;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* 80252278-8025229C .text cross__8cM3dGCylCFPC8cM3dGSphP4cXyz */
|
||||
bool cM3dGCyl::cross(const cM3dGSph* pOther, cXyz* pOut) const {
|
||||
|
||||
+15
-15
@@ -175,7 +175,7 @@ BOOL enemy_ice(enemyice* ei) {
|
||||
|
||||
BOOL frozen = FALSE;
|
||||
BOOL moveAndCollide = FALSE;
|
||||
switch (ei->mState) {
|
||||
switch (ei->mMode) {
|
||||
case 0: // Not initialized
|
||||
// Initialize the enemyice now.
|
||||
ei->mStts.Init(250, 0xFF, ac);
|
||||
@@ -192,7 +192,7 @@ BOOL enemy_ice(enemyice* ei) {
|
||||
if (std::fabsf(ei->mYOffset) < 0.1f) {
|
||||
ei->mYOffset = 80.0f;
|
||||
}
|
||||
ei->mState = 1;
|
||||
ei->mMode = 1;
|
||||
ei->mScaleY = 1.0f;
|
||||
ei->mScaleXZ = 1.0f;
|
||||
fopAcM_OnStatus(ac, fopAcStts_UNK8000000_e);
|
||||
@@ -202,7 +202,7 @@ BOOL enemy_ice(enemyice* ei) {
|
||||
// The enemy has signaled that it wants to be frozen for some length of time.
|
||||
ei->mFreezeTimer = ei->mFreezeDuration;
|
||||
ei->mFreezeDuration = 0;
|
||||
ei->mState = 2;
|
||||
ei->mMode = 2;
|
||||
if (ei->m00C == 0) {
|
||||
ei->mSpeed.y = 30.0f;
|
||||
ei->mAngularVelY = (s16)cM_rndFX(3000.0f);
|
||||
@@ -232,7 +232,7 @@ BOOL enemy_ice(enemyice* ei) {
|
||||
ac->attention_info.distances[fopAc_Attn_TYPE_CARRY_e] = 0x12;
|
||||
if (fopAcM_CheckStatus(ac, fopAcStts_CARRY_e)) {
|
||||
cLib_offBit<u32>(ac->attention_info.flags, fopAc_Attn_ACTION_CARRY_e);
|
||||
ei->mState = 3;
|
||||
ei->mMode = 3;
|
||||
if (ei->m00C == 2) {
|
||||
ei->m00C = 0;
|
||||
}
|
||||
@@ -250,7 +250,7 @@ BOOL enemy_ice(enemyice* ei) {
|
||||
ei->mSpeed.y = -15.0f;
|
||||
}
|
||||
ei->mAngleY = player->shape_angle.y;
|
||||
ei->mState = 2;
|
||||
ei->mMode = 2;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -349,7 +349,7 @@ BOOL enemy_ice(enemyice* ei) {
|
||||
}
|
||||
|
||||
if (ei->mFreezeTimer == 0) {
|
||||
ei->mState = 1;
|
||||
ei->mMode = 1;
|
||||
ei->mCyl.SetC(non_pos);
|
||||
dComIfG_Ccsp()->Set(&ei->mCyl);
|
||||
|
||||
@@ -440,7 +440,7 @@ void enemy_fire(enemyfire* ef) {
|
||||
cXyz pos;
|
||||
offset.setall(0.0f);
|
||||
|
||||
switch (ef->mState) {
|
||||
switch (ef->mMode) {
|
||||
case 0: // Not on fire.
|
||||
if (ef->mFireDuration == 0) {
|
||||
return;
|
||||
@@ -449,7 +449,7 @@ void enemy_fire(enemyfire* ef) {
|
||||
ef->mFireTimer = ef->mFireDuration;
|
||||
ef->mFireDuration = 0;
|
||||
|
||||
ef->mState = 1; // On fire
|
||||
ef->mMode = 1; // On fire
|
||||
|
||||
dKy_plight_set(&ef->mLight);
|
||||
|
||||
@@ -562,7 +562,7 @@ void enemy_fire(enemyfire* ef) {
|
||||
fopAcM_seStart(ac, JA_SE_OBJ_TORCH_BURNING, 0);
|
||||
|
||||
if (ef->mFireTimer == 0) {
|
||||
ef->mState = 0; // Not on fire
|
||||
ef->mMode = 0; // Not on fire
|
||||
dKy_plight_cut(&ef->mLight);
|
||||
ef->mSph.SetC(non_pos);
|
||||
dComIfG_Ccsp()->Set(&ef->mSph);
|
||||
@@ -579,7 +579,7 @@ void enemy_fire(enemyfire* ef) {
|
||||
|
||||
/* 8001D3B0-8001D428 .text enemy_fire_remove__FP9enemyfire */
|
||||
void enemy_fire_remove(enemyfire* ef) {
|
||||
ef->mState = 0; // Not on fire
|
||||
ef->mMode = 0; // Not on fire
|
||||
dKy_plight_cut(&ef->mLight);
|
||||
|
||||
for (int i = 0; i < 10; i++) {
|
||||
@@ -641,7 +641,7 @@ void dr_body_bg_check(damagereaction* dr) {
|
||||
dr->m71E--;
|
||||
}
|
||||
|
||||
if (dr->mState != 21 && dr->mState != 22) {
|
||||
if (dr->mAction != 21 && dr->mAction != 22) {
|
||||
dBgS_ObjGndChk_Spl gndChk;
|
||||
f32 x = dr->mpEnemy->current.pos.x;
|
||||
f32 y = dr->mpEnemy->current.pos.y;
|
||||
@@ -653,16 +653,16 @@ void dr_body_bg_check(damagereaction* dr) {
|
||||
temp.z = z;
|
||||
gndChk.SetPos(&temp);
|
||||
f32 floor_y = dComIfG_Bgsp()->GroundCross(&gndChk);
|
||||
if (floor_y != C_BG_MIN_HEIGHT && dr->mpEnemy->current.pos.y <= floor_y) {
|
||||
if (floor_y != -G_CM3D_F_INF && dr->mpEnemy->current.pos.y <= floor_y) {
|
||||
dr->mpEnemy->current.pos.y = floor_y + REG0_F(13);
|
||||
dr->m004 = 0;
|
||||
dr->mMode = 0;
|
||||
dr->m47C = 0;
|
||||
if (dComIfG_Bgsp()->ChkGrpInf(gndChk, 0x100)) {
|
||||
dr->mState = 22;
|
||||
dr->mAction = 22;
|
||||
cXyz sp14(x, floor_y, z);
|
||||
fopKyM_createWpillar(&sp14, REG0_F(9) + 1.0f, REG0_F(10) + 1.0f, 0);
|
||||
} else {
|
||||
dr->mState = 21;
|
||||
dr->mAction = 21;
|
||||
cXyz sp08(x, floor_y, z);
|
||||
fopKyM_createMpillar(&sp08, REG0_F(14) + 0.5f);
|
||||
}
|
||||
|
||||
+79
-19
@@ -17,8 +17,12 @@
|
||||
#include "string.h"
|
||||
|
||||
DynamicModuleControlBase * DMC[PROC_COUNT_e];
|
||||
#if VERSION == VERSION_DEMO
|
||||
JKRSolidHeap* cCc_solidHeap = NULL;
|
||||
#else
|
||||
bool DMC_initialized = false;
|
||||
BOOL cDyl_Initialized = false;
|
||||
#endif
|
||||
volatile BOOL cDyl_Initialized = false;
|
||||
mDoDvdThd_callback_c * cDyl_DVD = NULL;
|
||||
|
||||
const DynamicNameTableEntry DynamicNameTable[] = {
|
||||
@@ -186,6 +190,9 @@ const DynamicNameTableEntry DynamicNameTable[] = {
|
||||
{PROC_MANT, "d_a_mant"},
|
||||
{PROC_KANTERA, "d_a_kantera"},
|
||||
{PROC_KAMOME, "d_a_kamome"},
|
||||
#if VERSION == VERSION_DEMO
|
||||
{PROC_KAMOME2, "d_a_kamome2"},
|
||||
#endif
|
||||
{PROC_NPC_KAM, "d_a_npc_kamome"},
|
||||
{PROC_WBIRD, "d_a_wbird"},
|
||||
{PROC_DEMO_KMM, "d_a_demo_kmm"},
|
||||
@@ -457,10 +464,17 @@ const DynamicNameTableEntry DynamicNameTable[] = {
|
||||
|
||||
/* 800227A0-800229E0 .text cCc_Init__Fv */
|
||||
BOOL cCc_Init() {
|
||||
#if VERSION != VERSION_DEMO
|
||||
JUT_ASSERT(0x2a, !DMC_initialized);
|
||||
#endif
|
||||
|
||||
#if VERSION == VERSION_DEMO
|
||||
JKRExpHeap * pHeap = mDoExt_getArchiveHeap();
|
||||
cCc_solidHeap = mDoExt_createSolidHeapToCurrent(0, NULL, 0);
|
||||
#else
|
||||
JKRSolidHeap * pHeap = JKRSolidHeap::create(0x5648, mDoExt_getArchiveHeap(), false);
|
||||
JKRHeap * pOldHeap = pHeap->becomeCurrentHeap();
|
||||
#endif
|
||||
memset(DMC, 0, sizeof(DMC));
|
||||
|
||||
for (int i = 0; i < ARRAY_SIZE(DynamicNameTable); i++) {
|
||||
@@ -468,8 +482,8 @@ BOOL cCc_Init() {
|
||||
if (d.name == NULL)
|
||||
continue;
|
||||
|
||||
JUT_ASSERT(0x39, d.mKey < ARRAY_SIZE(DMC));
|
||||
JUT_ASSERT(0x3a, DMC[d.mKey] == NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(47, 57, 57, 57), d.mKey < ARRAY_SIZE(DMC));
|
||||
JUT_ASSERT(VERSION_SELECT(48, 58, 58, 58), DMC[d.mKey] == NULL);
|
||||
|
||||
for (int j = 0; j < ARRAY_SIZE(DMC); j++) {
|
||||
if (DMC[j] != NULL) {
|
||||
@@ -481,18 +495,28 @@ BOOL cCc_Init() {
|
||||
}
|
||||
|
||||
if (DMC[d.mKey] == NULL)
|
||||
#if VERSION == VERSION_DEMO
|
||||
DMC[d.mKey] = new (pHeap, 0) DynamicModuleControl(d.name);
|
||||
#else
|
||||
DMC[d.mKey] = new DynamicModuleControl(d.name);
|
||||
#endif
|
||||
}
|
||||
|
||||
#if VERSION == VERSION_DEMO
|
||||
mDoExt_restoreCurrentHeap();
|
||||
mDoExt_adjustSolidHeap(cCc_solidHeap);
|
||||
#else
|
||||
pHeap->adjustSize();
|
||||
pOldHeap->becomeCurrentHeap();
|
||||
DMC_initialized = TRUE;
|
||||
#endif
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/* 800229E0-80022A80 .text cDyl_IsLinked__Fs */
|
||||
BOOL cDyl_IsLinked(s16 i_ProfName) {
|
||||
JUT_ASSERT(0xae, cDyl_Initialized);
|
||||
JUT_ASSERT(VERSION_SELECT(134, 174, 174, 174), cDyl_Initialized);
|
||||
|
||||
if (DMC[i_ProfName] != NULL)
|
||||
return DMC[i_ProfName]->isLinked();
|
||||
@@ -502,8 +526,8 @@ BOOL cDyl_IsLinked(s16 i_ProfName) {
|
||||
|
||||
/* 80022A80-80022B58 .text cDyl_Unlink__Fs */
|
||||
BOOL cDyl_Unlink(s16 i_ProfName) {
|
||||
JUT_ASSERT(0xc5, cDyl_Initialized);
|
||||
JUT_ASSERT(0xc6, i_ProfName < ARRAY_SIZE(DMC));
|
||||
JUT_ASSERT(VERSION_SELECT(154, 197, 197, 197), cDyl_Initialized);
|
||||
JUT_ASSERT(VERSION_SELECT(155, 198, 198, 198), i_ProfName < ARRAY_SIZE(DMC));
|
||||
|
||||
if (DMC[i_ProfName] != NULL)
|
||||
return DMC[i_ProfName]->unlink();
|
||||
@@ -511,32 +535,62 @@ BOOL cDyl_Unlink(s16 i_ProfName) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
static void dummy(s16 i_ProfName) {
|
||||
OSReport_Error("cDyl_Link i_ProfName=%d\n", i_ProfName);
|
||||
cPhs_State cDyl_Link(s16 i_ProfName) {
|
||||
JUT_ASSERT(180, cDyl_Initialized);
|
||||
if (i_ProfName >= ARRAY_SIZE(DMC)) {
|
||||
OSReport_Error("cDyl_Link i_ProfName=%d\n", i_ProfName);
|
||||
return cPhs_ERROR_e;
|
||||
}
|
||||
JUT_ASSERT(185, i_ProfName < ARRAY_SIZE(DMC));
|
||||
if (DMC[i_ProfName]) {
|
||||
if (DMC[i_ProfName]->link()) {
|
||||
return cPhs_COMPLEATE_e;
|
||||
} else {
|
||||
return cPhs_ERROR_e;
|
||||
}
|
||||
} else {
|
||||
return cPhs_COMPLEATE_e;
|
||||
}
|
||||
}
|
||||
|
||||
#if VERSION != VERSION_DEMO
|
||||
static void dummy() {
|
||||
OSReport_Error("cDyl_LinkASync: リンクに失敗しました。諦めます\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
/* 80022B58-80022CEC .text cDyl_LinkASync__Fs */
|
||||
cPhs_State cDyl_LinkASync(s16 i_ProfName) {
|
||||
JUT_ASSERT(0x101, DMC_initialized);
|
||||
|
||||
#if VERSION == VERSION_DEMO
|
||||
if (!cDyl_Initialized) {
|
||||
OSReport_Error("初期化が終わってないのに呼んでもらっても困ります %d\n", i_ProfName);
|
||||
return cPhs_INIT_e;
|
||||
}
|
||||
JUT_ASSERT(203, cDyl_Initialized);
|
||||
#else
|
||||
JUT_ASSERT(257, DMC_initialized);
|
||||
if (!cDyl_Initialized)
|
||||
return cPhs_INIT_e;
|
||||
#endif
|
||||
|
||||
if (i_ProfName >= ARRAY_SIZE(DMC)) {
|
||||
OSReport_Error("cDyl_Link i_ProfName=%d\n", i_ProfName);
|
||||
return cPhs_ERROR_e;
|
||||
}
|
||||
|
||||
JUT_ASSERT(0x111, i_ProfName < ARRAY_SIZE(DMC));
|
||||
JUT_ASSERT(VERSION_SELECT(208, 273, 273, 273), i_ProfName < ARRAY_SIZE(DMC));
|
||||
DynamicModuleControlBase * d = DMC[i_ProfName];
|
||||
if (d != NULL) {
|
||||
#if VERSION != VERSION_DEMO
|
||||
JUT_ASSERT(0x115, cDyl_Initialized);
|
||||
#endif
|
||||
if (d->load_async()) {
|
||||
if (d->link()) {
|
||||
return cPhs_COMPLEATE_e;
|
||||
} else {
|
||||
#if VERSION != VERSION_DEMO
|
||||
OSReport_Error("cDyl_LinkASync: リンクに失敗しました。諦めます\n");
|
||||
#endif
|
||||
return cPhs_ERROR_e;
|
||||
}
|
||||
}
|
||||
@@ -549,25 +603,31 @@ cPhs_State cDyl_LinkASync(s16 i_ProfName) {
|
||||
|
||||
/* 80022CEC-80022DF8 .text cDyl_InitCallback__FPv */
|
||||
BOOL cDyl_InitCallback(void*) {
|
||||
JUT_ASSERT(0x12f, !cDyl_Initialized);
|
||||
JKRFileLoader * pFileLoader = JKRFileCache::mount("/", mDoExt_getArchiveHeap(), NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(230, 303, 303, 303), !cDyl_Initialized);
|
||||
JKRFileCache* loader = JKRMountDvdDrive("/", mDoExt_getArchiveHeap(), NULL);
|
||||
DynamicModuleControl::initialize();
|
||||
void * pData = JKRFileLoader::getGlbResource("/dvd/framework.str");
|
||||
JKRFileLoader::detachResource(pData, pFileLoader);
|
||||
pFileLoader->unmount();
|
||||
OSSetStringTable(pData);
|
||||
|
||||
void* strTbl = JKRGetResource("/dvd/framework.str");
|
||||
JKRDetachResource(strTbl, loader);
|
||||
JKRUnmountDvdDrive(loader);
|
||||
OSSetStringTable(strTbl);
|
||||
|
||||
DynamicModuleControl dmc("f_pc_profile_lst");
|
||||
dmc.link();
|
||||
#if VERSION == VERSION_DEMO
|
||||
cCc_Init();
|
||||
#endif
|
||||
cDyl_Initialized = TRUE;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/* 80022DF8-80022E70 .text cDyl_InitAsync__Fv */
|
||||
void cDyl_InitAsync() {
|
||||
#if VERSION != VERSION_DEMO
|
||||
cCc_Init();
|
||||
#endif
|
||||
|
||||
JUT_ASSERT(0x145, cDyl_DVD == NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(252, 325, 325, 325), cDyl_DVD == NULL);
|
||||
cDyl_DVD = mDoDvdThd_callback_c::create((mDoDvdThd_callback_func) cDyl_InitCallback, NULL);
|
||||
}
|
||||
|
||||
@@ -617,7 +677,7 @@ cPhs_State cDylPhs::Link(request_of_phase_process_class* i_phase, s16 profName)
|
||||
|
||||
/* 80022F68-80023004 .text Unlink__7cDylPhsFP30request_of_phase_process_classs */
|
||||
BOOL cDylPhs::Unlink(request_of_phase_process_class* i_phase, s16 profName) {
|
||||
JUT_ASSERT(0x1a6, i_phase->id != 1);
|
||||
JUT_ASSERT(VERSION_SELECT(357, 422, 422, 422), i_phase->id != 1);
|
||||
|
||||
BOOL ret;
|
||||
if (i_phase->id == 2) {
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_acorn_leaf.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-0000010C .text CheckCreateHeap__FP10fopAc_ac_c */
|
||||
static BOOL CheckCreateHeap(fopAc_ac_c*) {
|
||||
@@ -94,7 +95,7 @@ actor_process_profile_definition g_profile_ACORN_LEAF = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0118,
|
||||
/* Priority */ PRIO_ACORN_LEAF,
|
||||
/* Actor SubMtd */ &daAleafMethodTable,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
+15
-14
@@ -14,6 +14,7 @@
|
||||
#include "d/d_item_data.h"
|
||||
#include "d/d_meter.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_kankyo_wether.h"
|
||||
#include "m_Do/m_Do_controller_pad.h"
|
||||
#include "m_Do/m_Do_dvd_thread.h"
|
||||
@@ -31,7 +32,7 @@ static mDoDvdThd_toMainRam_c* l_gbaCommand;
|
||||
|
||||
int daAgb_c::mEffect;
|
||||
daAgb_c::daAgb_ItemBuy daAgb_c::mItemBuy;
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
daAgb_c::daAgb_GbaFlg daAgb_c::mGbaFlg;
|
||||
daAgb_c::daAgb_Switch daAgb_c::mSwitch;
|
||||
daAgb_c::daAgb_Item daAgb_c::mItem;
|
||||
@@ -90,7 +91,7 @@ int dMsgCtrl_c::execute() {
|
||||
|
||||
static dMsgCtrl_c l_msgCtrl;
|
||||
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
u8 sjis2chrNo(const char* i_chr) {
|
||||
static u8 l_sjis1chrNo[] = {
|
||||
0x2A, 0x2A, 0x2A, 0x2A, 0x2A, 0x2A, 0x2A, 0x2A,
|
||||
@@ -267,7 +268,7 @@ void daAgb_c::NameConv() {
|
||||
mPlayerName = 0;
|
||||
|
||||
for (i = 0; i < 8; i++) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
u8 chr = sjis2chrNo(name);
|
||||
mPlayerName |= chr;
|
||||
if (*name & 0x80)
|
||||
@@ -364,7 +365,7 @@ int daAgb_c::uploadSelect() {
|
||||
fopMsgM_messageSet(6); // "Now calling Tingle..."
|
||||
mUploadAction = UpAct_UNK3;
|
||||
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
l_gbaCommand = mDoDvdThd_toMainRam_c::create("/res/Gba/client.bin", 0, dMsg_getAgbWorkArea());
|
||||
#elif VERSION == VERSION_USA
|
||||
l_gbaCommand = mDoDvdThd_toMainRam_c::create("/res/Gba/client_u.bin", 0, dMsg_getAgbWorkArea());
|
||||
@@ -377,7 +378,7 @@ int daAgb_c::uploadSelect() {
|
||||
strcat(path, ".bin");
|
||||
l_gbaCommand = mDoDvdThd_toMainRam_c::create(path, 0, dMsg_getAgbWorkArea());
|
||||
#endif
|
||||
JUT_ASSERT(VERSION_SELECT(591, 860, 861), l_gbaCommand != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(591, 591, 860, 861), l_gbaCommand != NULL);
|
||||
|
||||
mDoGaC_GbaReboot();
|
||||
mDoGaC_setPortNo(mPortNo);
|
||||
@@ -393,7 +394,7 @@ int daAgb_c::uploadSelect() {
|
||||
int daAgb_c::uploadJoyboot1() {
|
||||
if (l_gbaCommand->sync()) {
|
||||
void* programp = l_gbaCommand->getMemAddress();
|
||||
JUT_ASSERT(VERSION_SELECT(622, 891, 892), programp != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(622, 622, 891, 892), programp != NULL);
|
||||
|
||||
JUTGba::getManager()->doJoyBoot(mDoGaC_getPortNo(), 3, -1, (u8*)programp,
|
||||
l_gbaCommand->getMemSize() - 4, NULL, NULL);
|
||||
@@ -453,7 +454,7 @@ int daAgb_c::uploadMessageLoad() {
|
||||
strcat(path, ".bin");
|
||||
l_gbaCommand = mDoDvdThd_toMainRam_c::create(path, 0, NULL);
|
||||
#endif
|
||||
JUT_ASSERT(VERSION_SELECT(715, 1000, 1001), l_gbaCommand != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(715, 715, 1000, 1001), l_gbaCommand != NULL);
|
||||
|
||||
mUploadAction = UpAct_UNK7;
|
||||
mDoGaC_onComEnable();
|
||||
@@ -476,7 +477,7 @@ int daAgb_c::uploadMessageLoad2() {
|
||||
int daAgb_c::uploadConnect() {
|
||||
if (mDoGaC_getComEnable() && mDoGaC_GbaLink()) {
|
||||
void* programp = l_gbaCommand->getMemAddress();
|
||||
JUT_ASSERT(VERSION_SELECT(760, 1045, 1046), programp != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(760, 760, 1045, 1046), programp != NULL);
|
||||
mDoGac_SendDataSet((u32*)programp, l_gbaCommand->getMemSize(), 0, 0);
|
||||
|
||||
mUploadAction = UpAct_UNK8;
|
||||
@@ -516,7 +517,7 @@ int daAgb_c::uploadMessageSend() {
|
||||
delete l_gbaCommand;
|
||||
}
|
||||
} else if (mDoGaC_getDataStatus(0) == 9) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
mUploadAction = UpAct_UNK5;
|
||||
#else
|
||||
field_0x664 = 5;
|
||||
@@ -527,7 +528,7 @@ int daAgb_c::uploadMessageSend() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
/* 800D01F4-800D021C .text uploadRetryWait__7daAgb_cFv */
|
||||
int daAgb_c::uploadRetryWait() {
|
||||
field_0x664--;
|
||||
@@ -575,7 +576,7 @@ daAgb_c::uploadFunc daAgb_c::uploadFuncTable[] = {
|
||||
&daAgb_c::uploadMessageLoad,
|
||||
&daAgb_c::uploadMessageLoad2,
|
||||
&daAgb_c::uploadMessageSend,
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
&daAgb_c::uploadRetryWait,
|
||||
#endif
|
||||
&daAgb_c::uploadMsgEndWait,
|
||||
@@ -1310,7 +1311,7 @@ void daAgb_c::CursorMove(fopAc_ac_c* actor, u32 stage_type) {
|
||||
|
||||
cXyz r1_14;
|
||||
dBgS_GndChk r1_5C;
|
||||
f32 f30 = C_BG_MIN_HEIGHT;
|
||||
f32 f30 = -G_CM3D_F_INF;
|
||||
r1_5C.OffWall();
|
||||
r1_14.y = actor->current.pos.y + 150.0f;
|
||||
static cXy l_ckOffset[] = {
|
||||
@@ -1716,7 +1717,7 @@ static BOOL createHeap_CB(fopAc_ac_c* i_this) {
|
||||
/* 800D396C-800D3B58 .text createHeap__7daAgb_cFv */
|
||||
BOOL daAgb_c::createHeap() {
|
||||
J3DModelData* modelData = (J3DModelData*)dComIfG_getObjectRes("Agb", AGB_BDL_AGBCURSOR);
|
||||
JUT_ASSERT(VERSION_SELECT(2960, 3277, 3286), modelData != NULL);
|
||||
JUT_ASSERT(VERSION_SELECT(2960, 2960, 3277, 3286), modelData != NULL);
|
||||
|
||||
mpModel = mDoExt_J3DModel__create(modelData, 0x80000, 0x11000002);
|
||||
if (mpModel == NULL) {
|
||||
@@ -1801,7 +1802,7 @@ actor_process_profile_definition g_profile_AGB = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x000C,
|
||||
/* Priority */ PRIO_AGB,
|
||||
/* Actor SubMtd */ &l_daAgb_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_NOPAUSE_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
+20
-19
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "global.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
#include "weak_data_1811.h" // IWYU pragma: keep
|
||||
|
||||
@@ -366,7 +367,7 @@ BOOL daAgbsw0_c::ExeSubA() {
|
||||
if(!fopAcM_isSwitch(this, sw0)) {
|
||||
if(field_0x298 == 1) {
|
||||
if(mDoGaC_GbaLink()) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
if(mDoGac_SendStatusCheck(5)) {
|
||||
#else
|
||||
if(!mDoGac_SendStatusCheck(5)) {
|
||||
@@ -404,7 +405,7 @@ BOOL daAgbsw0_c::ExeSubA() {
|
||||
}
|
||||
|
||||
if(MoveCheck(conditionNo)) {
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if(field_0x298 == 1) {
|
||||
if(mDoGaC_GbaLink()) {
|
||||
if(!mDoGac_SendStatusCheck(5)) {
|
||||
@@ -450,7 +451,7 @@ BOOL daAgbsw0_c::ExeSubAT() {
|
||||
if(!dComIfGs_isTbox(flag)) {
|
||||
if(field_0x298 == 1) {
|
||||
if(mDoGaC_GbaLink()) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
if(mDoGac_SendStatusCheck(5)) {
|
||||
#else
|
||||
if(!mDoGac_SendStatusCheck(5)) {
|
||||
@@ -574,7 +575,7 @@ BOOL daAgbsw0_c::ExeSubA2() {
|
||||
}
|
||||
|
||||
if(MoveCheck(conditionNo)) {
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if(field_0x298 == 1) {
|
||||
if(mDoGaC_GbaLink()) {
|
||||
if(!mDoGac_SendStatusCheck(5)) {
|
||||
@@ -837,7 +838,7 @@ BOOL daAgbsw0_c::ExeSubM3() {
|
||||
if(mDoGaC_GbaLink() && mDoGac_SendStatusCheck(5)) {
|
||||
daAgb_c* agb = dComIfGp_getAgb();
|
||||
if(agb && agb->isActive() && (agb->isFree() || agb->getFollowTarget() != 1) && HitCheck(agb)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
u16 gbaMsgNo = TriforceCheck();
|
||||
#else
|
||||
u16 gbaMsgNo = TriforceCheck(agb);
|
||||
@@ -858,7 +859,7 @@ BOOL daAgbsw0_c::ExeSubM3() {
|
||||
}
|
||||
}
|
||||
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
u32 daAgbsw0_c::TriforceCheck()
|
||||
#else
|
||||
/* 00001368-000017B0 .text TriforceCheck__10daAgbsw0_cFP7daAgb_c */
|
||||
@@ -896,7 +897,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
}
|
||||
if(!dComIfGs_isGetCollectMap(2) && dComIfGs_checkGetItem(dItem_SKULL_HAMMER_e)) {
|
||||
if(dComIfGs_checkGetItem(COTTAGE_PAPER)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
s8 roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -911,7 +912,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
if(!dComIfGs_isGetCollectMap(3)) {
|
||||
if(dComIfGs_checkGetItem(dItem_BAIT_BAG_e)) {
|
||||
if(dComIfGs_checkBaitItem(dItem_HYOI_PEAR_e)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
s8 roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -930,7 +931,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
s32 hour = dKy_getdaytime_hour();
|
||||
if(hour < 6 || hour >= 0x13) {
|
||||
u32 moonType = dKy_moon_type_chk();
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
int roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -993,7 +994,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
}
|
||||
if(!dComIfGs_isGetCollectMap(5)) {
|
||||
if(dComIfGs_isEventBit(0x3E80)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
if (!dComIfGs_isGetCollectMap(0x1C)) {
|
||||
return 0x31E;
|
||||
} else if (!dComIfGs_isCompleteCollectMap(0x1C)) {
|
||||
@@ -1010,7 +1011,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
#endif
|
||||
}
|
||||
else {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
s8 roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -1028,7 +1029,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
}
|
||||
|
||||
if(!dComIfGs_isGetCollectMap(6)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
s8 roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -1036,7 +1037,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
return roomNo == dIsleRoom_OutsetIsland_e ? 0x325 : 0x324;
|
||||
}
|
||||
if(!dComIfGs_isGetCollectMap(7)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
s8 roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -1044,7 +1045,7 @@ u32 daAgbsw0_c::TriforceCheck(daAgb_c* agb)
|
||||
return roomNo == dIsleRoom_StoneWatcherIsland_e ? 0x327 : 0x326;
|
||||
}
|
||||
if(dComIfGs_checkGetItem(dItem_HOOKSHOT_e)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
s8 roomNo = dComIfGp_roomControl_getStayNo();
|
||||
#else
|
||||
int roomNo = agb->field_0x66d;
|
||||
@@ -1184,7 +1185,7 @@ BOOL daAgbsw0_c::ExeSubS() {
|
||||
return true;
|
||||
}
|
||||
else {
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if(strcmp(dComIfGp_getStartStageName(), "M_NewD2") == 0 && fopAcM_GetHomeRoomNo(this) == 0xC && dComIfGs_isTbox(0xC)) {
|
||||
fopAcM_delete(this);
|
||||
return true;
|
||||
@@ -1559,7 +1560,7 @@ BOOL daAgbsw0_c::ExeSubFA() {
|
||||
if(!fopAcM_isSwitch(this, sw0)) {
|
||||
if(field_0x298 == 1) {
|
||||
if(mDoGaC_GbaLink()) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
if(mDoGac_SendStatusCheck(5)) {
|
||||
#else
|
||||
if(!mDoGac_SendStatusCheck(5)) {
|
||||
@@ -1613,7 +1614,7 @@ BOOL daAgbsw0_c::ExeSubFA() {
|
||||
}
|
||||
|
||||
if(MoveCheck(conditionNo)) {
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if(field_0x298 == 1) {
|
||||
if(mDoGaC_GbaLink()) {
|
||||
if(!mDoGac_SendStatusCheck(5)) {
|
||||
@@ -2502,7 +2503,7 @@ BOOL daAgbsw0_c::MoveCheck(s16 conditionNo) {
|
||||
}
|
||||
|
||||
break;
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
case 0x82:
|
||||
if(field_0x29B == 0) {
|
||||
if(daNpc_Md_c::isPlayerRoom()) {
|
||||
@@ -2595,7 +2596,7 @@ actor_process_profile_definition g_profile_AGBSW0 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x000D,
|
||||
/* Priority */ PRIO_AGBSW0,
|
||||
/* Actor SubMtd */ &l_daAgbsw0_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_alldie.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
|
||||
enum {
|
||||
@@ -126,7 +127,7 @@ actor_process_profile_definition g_profile_ALLDIE = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x011D,
|
||||
/* Priority */ PRIO_ALLDIE,
|
||||
/* Actor SubMtd */ &l_daAlldie_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
+65
-64
@@ -9,6 +9,7 @@
|
||||
#include "JSystem/J3DGraphAnimator/J3DNode.h"
|
||||
#include "SSystem/SComponent/c_xyz.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_cc_d.h"
|
||||
#include "d/d_bg_s_acch.h"
|
||||
#include "d/d_bg_s_lin_chk.h"
|
||||
@@ -34,17 +35,17 @@ enum Action {
|
||||
ACTION_ITAI_MOVE = 3,
|
||||
};
|
||||
|
||||
enum State {
|
||||
STATE_DOUSA_INIT = 0,
|
||||
STATE_DOUSA_OKIRU = 2,
|
||||
STATE_DOUSA_SLEEP_INIT = 9,
|
||||
STATE_DOUSA_SLEEP_MAIN = 10,
|
||||
STATE_MODORU_MOVE_INIT = 20,
|
||||
STATE_MODORU_MOVE_MAIN = 21,
|
||||
STATE_MODORU_MOVE_END = 22,
|
||||
STATE_HANDOU_MOVE_INIT = 30,
|
||||
STATE_HANDOU_MOVE_MAIN = 31,
|
||||
STATE_ITAI_MOVE_INIT = 40,
|
||||
enum Mode {
|
||||
MODE_DOUSA_INIT = 0,
|
||||
MODE_DOUSA_OKIRU = 2,
|
||||
MODE_DOUSA_SLEEP_INIT = 9,
|
||||
MODE_DOUSA_SLEEP_MAIN = 10,
|
||||
MODE_MODORU_MOVE_INIT = 20,
|
||||
MODE_MODORU_MOVE_MAIN = 21,
|
||||
MODE_MODORU_MOVE_END = 22,
|
||||
MODE_HANDOU_MOVE_INIT = 30,
|
||||
MODE_HANDOU_MOVE_MAIN = 31,
|
||||
MODE_ITAI_MOVE_INIT = 40,
|
||||
};
|
||||
|
||||
/* 00000078-0000021C .text nodeCallBack__FP7J3DNodei */
|
||||
@@ -143,7 +144,7 @@ static void anm_init(am_class* i_this, int bckFileIdx, f32 morf, u8 loopMode, f3
|
||||
static void body_atari_check(am_class* i_this) {
|
||||
daPy_py_c* player = daPy_getPlayerActorClass();
|
||||
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
if (i_this->mStartsInactive == 1 && i_this->mSwitch != 0xFF && !dComIfGs_isSwitch(i_this->mSwitch, dComIfGp_roomControl_getStayNo())) {
|
||||
return;
|
||||
}
|
||||
@@ -183,7 +184,7 @@ static void body_atari_check(am_class* i_this) {
|
||||
break;
|
||||
case AT_TYPE_SKULL_HAMMER:
|
||||
fopAcM_seStart(i_this, JA_SE_LK_HAMMER_HIT, 0x42);
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
if (i_this->mStartsInactive == 1 && i_this->mSwitch != 0xFF && !dComIfGs_isSwitch(i_this->mSwitch, dComIfGp_roomControl_getStayNo())) {
|
||||
return;
|
||||
}
|
||||
@@ -195,7 +196,7 @@ static void body_atari_check(am_class* i_this) {
|
||||
return;
|
||||
}
|
||||
i_this->mAction = ACTION_HANDOU_MOVE;
|
||||
i_this->mState = STATE_HANDOU_MOVE_INIT;
|
||||
i_this->mMode = MODE_HANDOU_MOVE_INIT;
|
||||
i_this->mHugeKnockback = 0;
|
||||
if (player->getCutType() == 0x11) {
|
||||
// If the player hits the Armos Knight with the Skull Hammer's side swing, knock it back much farther than normal.
|
||||
@@ -284,14 +285,14 @@ static BOOL medama_atari_check(am_class* i_this) {
|
||||
i_this->mNeedleCyl.OnAtSPrmBit(cCcD_AtSPrm_Set_e);
|
||||
i_this->mNeedleCyl.OnAtHitBit();
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = STATE_DOUSA_OKIRU;
|
||||
i_this->mMode = MODE_DOUSA_OKIRU;
|
||||
} else {
|
||||
dComIfGp_particle_set(dPa_name::ID_COMMON_0010, &i_this->mEyeballPos, &player->shape_angle);
|
||||
// fopAcM_seStart(i_this, JA_SE_CM_AM_EYE_DAMAGE, 0);
|
||||
mDoAud_seStart(JA_SE_CM_AM_EYE_DAMAGE, &i_this->eyePos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_AM_EYE_DAMAGE, 0x42);
|
||||
i_this->mAction = ACTION_ITAI_MOVE;
|
||||
i_this->mState = STATE_ITAI_MOVE_INIT;
|
||||
i_this->mMode = MODE_ITAI_MOVE_INIT;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
@@ -394,7 +395,7 @@ static BOOL bomb_nomi_check(am_class* i_this) {
|
||||
bomb->setBombNoHit();
|
||||
bomb_move_set(i_this, 0);
|
||||
i_this->mAction = ACTION_ITAI_MOVE;
|
||||
i_this->mState = 44;
|
||||
i_this->mMode = 44;
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
@@ -409,7 +410,7 @@ static BOOL bomb_nomi_check(am_class* i_this) {
|
||||
bomb2->set_no_hit();
|
||||
bomb_move_set(i_this, 0);
|
||||
i_this->mAction = ACTION_ITAI_MOVE;
|
||||
i_this->mState = 44;
|
||||
i_this->mMode = 44;
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
@@ -481,13 +482,13 @@ static void medama_move(am_class* i_this) {
|
||||
/* 00001B00-00002564 .text action_dousa__FP8am_class */
|
||||
static void action_dousa(am_class* i_this) {
|
||||
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
|
||||
switch (i_this->mState) {
|
||||
case STATE_DOUSA_INIT:
|
||||
switch (i_this->mMode) {
|
||||
case MODE_DOUSA_INIT:
|
||||
for (int i = 0; i < ARRAY_SIZE(i_this->mCountUpTimers); i++) {
|
||||
i_this->mCountUpTimers[i] = 0;
|
||||
}
|
||||
anm_init(i_this, AM_BCK_SLEEP_LOOP, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
case 1:
|
||||
if (i_this->mStartsInactive == 1 && i_this->mSwitch != 0xFF && !dComIfGs_isSwitch(i_this->mSwitch, dComIfGp_roomControl_getStayNo())) {
|
||||
@@ -506,15 +507,15 @@ static void action_dousa(am_class* i_this) {
|
||||
i_this->attention_info.flags = fopAc_Attn_LOCKON_BATTLE_e;
|
||||
i_this->mNeedleCyl.OnAtSetBit();
|
||||
i_this->mNeedleCyl.OnAtHitBit();
|
||||
i_this->mState += 1; // STATE_DOUSA_OKIRU
|
||||
i_this->mMode += 1; // MODE_DOUSA_OKIRU
|
||||
}
|
||||
}
|
||||
break;
|
||||
case STATE_DOUSA_OKIRU:
|
||||
case MODE_DOUSA_OKIRU:
|
||||
if (!i_this->mpMorf->isStop()) {
|
||||
break;
|
||||
}
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
case 3:
|
||||
if (i_this->mCurrBckIdx != AM_BCK_CLOSE && i_this->mCurrBckIdx != AM_BCK_CLOSE_LOOP) {
|
||||
@@ -528,7 +529,7 @@ static void action_dousa(am_class* i_this) {
|
||||
i_this->mCountDownTimers[2] = 6;
|
||||
}
|
||||
i_this->mTargetAngleY = fopAcM_searchPlayerAngleY(i_this);
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
case 4: {
|
||||
if (i_this->mCountDownTimers[2] == 1) {
|
||||
@@ -544,24 +545,24 @@ static void action_dousa(am_class* i_this) {
|
||||
f32 xzDist = std::sqrtf(xDist*xDist + zDist*zDist);
|
||||
if (xzDist > i_this->mAreaRadius) {
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = STATE_MODORU_MOVE_INIT;
|
||||
i_this->mMode = MODE_MODORU_MOVE_INIT;
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
if (fopAcM_searchPlayerDistance(i_this) > 2000.0f) {
|
||||
i_this->mState = STATE_DOUSA_SLEEP_INIT;
|
||||
i_this->mMode = MODE_DOUSA_SLEEP_INIT;
|
||||
break;
|
||||
}
|
||||
f32 yDist = player->current.pos.y - i_this->current.pos.y;
|
||||
yDist = std::sqrtf(yDist*yDist); // ???
|
||||
if (yDist > 300.0f) {
|
||||
i_this->mState = STATE_DOUSA_SLEEP_INIT;
|
||||
i_this->mMode = MODE_DOUSA_SLEEP_INIT;
|
||||
break;
|
||||
}
|
||||
}
|
||||
s16 yRotDiff = cLib_distanceAngleS(i_this->shape_angle.y, i_this->mTargetAngleY);
|
||||
if (yRotDiff < 0x100) {
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -573,7 +574,7 @@ static void action_dousa(am_class* i_this) {
|
||||
if (!Line_check(i_this, player->current.pos) || player->getDamageWaitTimer() != 0) {
|
||||
i_this->speedF = 0.0f;
|
||||
}
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
case 6:
|
||||
if (i_this->mCurrBckIdx == AM_BCK_CLOSE) {
|
||||
@@ -596,7 +597,7 @@ static void action_dousa(am_class* i_this) {
|
||||
if (i_this->mCountUpTimers[0] < 2) {
|
||||
i_this->mCountDownTimers[0] = 10;
|
||||
}
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
case 7:
|
||||
if (i_this->mCountDownTimers[0] != 0) {
|
||||
@@ -621,9 +622,9 @@ static void action_dousa(am_class* i_this) {
|
||||
0xB9, &i_this->mSmokeCbs[2], fopAcM_GetRoomNo(i_this)
|
||||
);
|
||||
}
|
||||
i_this->mState = 8;
|
||||
i_this->mMode = 8;
|
||||
} else {
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
}
|
||||
break;
|
||||
case 8:
|
||||
@@ -635,27 +636,27 @@ static void action_dousa(am_class* i_this) {
|
||||
}
|
||||
if (i_this->mCountDownTimers[0] == 0) {
|
||||
i_this->mSmokeCbs[2].remove();
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
}
|
||||
break;
|
||||
case STATE_DOUSA_SLEEP_INIT:
|
||||
case MODE_DOUSA_SLEEP_INIT:
|
||||
anm_init(i_this, AM_BCK_SLEEP, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
fopAcM_seStart(i_this, JA_SE_CM_AM_NEEDLE_IN, 0);
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->attention_info.flags = 0;
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
case STATE_DOUSA_SLEEP_MAIN:
|
||||
case MODE_DOUSA_SLEEP_MAIN:
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->mState = 0;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
medama_move(i_this);
|
||||
|
||||
if (i_this->mState != 2 && medama_atari_check(i_this)) {
|
||||
if (i_this->mMode != 2 && medama_atari_check(i_this)) {
|
||||
i_this->mSmokeCbs[2].remove();
|
||||
} else if (bomb_nomi_check(i_this)) {
|
||||
i_this->mSmokeCbs[2].remove();
|
||||
@@ -664,8 +665,8 @@ static void action_dousa(am_class* i_this) {
|
||||
|
||||
/* 00002564-000028C4 .text action_modoru_move__FP8am_class */
|
||||
static void action_modoru_move(am_class* i_this) {
|
||||
switch (i_this->mState) {
|
||||
case STATE_MODORU_MOVE_INIT: {
|
||||
switch (i_this->mMode) {
|
||||
case MODE_MODORU_MOVE_INIT: {
|
||||
anm_init(i_this, AM_BCK_CLOSE_LOOP, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->mNeedleCyl.OnAtSetBit();
|
||||
i_this->mNeedleCyl.OnAtHitBit();
|
||||
@@ -677,10 +678,10 @@ static void action_modoru_move(am_class* i_this) {
|
||||
f32 xDistToSpawn = i_this->mSpawnPos.x - i_this->current.pos.x;
|
||||
f32 zDistToSpawn = i_this->mSpawnPos.z - i_this->current.pos.z;
|
||||
i_this->mTargetAngleY = cM_atan2s(xDistToSpawn, zDistToSpawn);
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
}
|
||||
case STATE_MODORU_MOVE_MAIN: {
|
||||
case MODE_MODORU_MOVE_MAIN: {
|
||||
f32 xDistToSpawn = i_this->mSpawnPos.x - i_this->current.pos.x;
|
||||
f32 zDistToSpawn = i_this->mSpawnPos.z - i_this->current.pos.z;
|
||||
if (i_this->mAcch.ChkGroundHit()) {
|
||||
@@ -705,18 +706,18 @@ static void action_modoru_move(am_class* i_this) {
|
||||
if (xzDist < 20.0f) {
|
||||
i_this->mTargetAngleY = i_this->mSpawnRotY;
|
||||
i_this->speedF = 0.0f;
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case STATE_MODORU_MOVE_END: {
|
||||
case MODE_MODORU_MOVE_END: {
|
||||
s16 angleDiff = cLib_distanceAngleS(i_this->shape_angle.y, i_this->mTargetAngleY);
|
||||
if (angleDiff < 0x100) {
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->attention_info.flags = 0;
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = STATE_DOUSA_INIT;
|
||||
i_this->mMode = MODE_DOUSA_INIT;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -726,8 +727,8 @@ static void action_modoru_move(am_class* i_this) {
|
||||
/* 000028C4-00002A6C .text action_handou_move__FP8am_class */
|
||||
static void action_handou_move(am_class* i_this) {
|
||||
daPy_py_c* player = daPy_getPlayerActorClass();
|
||||
switch (i_this->mState) {
|
||||
case STATE_HANDOU_MOVE_INIT: {
|
||||
switch (i_this->mMode) {
|
||||
case MODE_HANDOU_MOVE_INIT: {
|
||||
i_this->speedF = 20.0f;
|
||||
s16 angleToPlayer = fopAcM_searchPlayerAngleY(i_this);
|
||||
i_this->current.angle.y = angleToPlayer + 0x8000;
|
||||
@@ -743,17 +744,17 @@ static void action_handou_move(am_class* i_this) {
|
||||
mDoAud_seStart(JA_SE_CM_AM_MOUTH_CLOSE, &i_this->eyePos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
anm_init(i_this, AM_BCK_CLOSE, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
}
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
}
|
||||
case STATE_HANDOU_MOVE_MAIN: {
|
||||
case MODE_HANDOU_MOVE_MAIN: {
|
||||
cLib_addCalc0(&i_this->speedF, 0.8f, 2.0f);
|
||||
if (i_this->speedF < 0.1f) {
|
||||
i_this->speedF = 0.0f;
|
||||
i_this->mCountDownTimers[2] = 6;
|
||||
i_this->current.angle.y = i_this->shape_angle.y;
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -762,8 +763,8 @@ static void action_handou_move(am_class* i_this) {
|
||||
|
||||
/* 00002A6C-000034F4 .text action_itai_move__FP8am_class */
|
||||
static void action_itai_move(am_class* i_this) {
|
||||
switch (i_this->mState) {
|
||||
case STATE_ITAI_MOVE_INIT:
|
||||
switch (i_this->mMode) {
|
||||
case MODE_ITAI_MOVE_INIT:
|
||||
i_this->mEyeRot.setall(0);
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
@@ -772,7 +773,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
i_this->mTargetAngleY = i_this->current.angle.y;
|
||||
fopAcM_seStart(i_this, JA_SE_CM_AM_NEEDLE_IN, 0);
|
||||
anm_init(i_this, AM_BCK_DAMAGE, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
case 41:
|
||||
cLib_addCalc0(&i_this->speedF, 0.8f, 2.0f);
|
||||
@@ -782,7 +783,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
i_this->mCountDownTimers[0] = 100;
|
||||
i_this->speedF = 0.0f;
|
||||
anm_init(i_this, AM_BCK_DAMAGE_LOOP, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
case 42:
|
||||
if (i_this->mCountDownTimers[0] != 0) {
|
||||
@@ -793,7 +794,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
// Using the fopAcM_seStart inline multiple times in a single case makes the codegen not match.
|
||||
// fopAcM_seStart(i_this, JA_SE_CM_AM_MOUTH_CLOSE, 0);
|
||||
mDoAud_seStart(JA_SE_CM_AM_MOUTH_CLOSE, &i_this->eyePos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
case 43:
|
||||
if (!i_this->mpMorf->isStop()) {
|
||||
@@ -803,7 +804,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
i_this->mNeedleCyl.OnAtHitBit();
|
||||
i_this->mCountUpTimers[0] = 0;
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
break;
|
||||
case 44:
|
||||
i_this->mSmokeCbs[3].remove();
|
||||
@@ -819,7 +820,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->mNeedleCyl.OffAtSetBit();
|
||||
i_this->mCountDownTimers[1] = 10;
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
// Fall-through
|
||||
case 45:
|
||||
bomb_move_set(i_this, 0);
|
||||
@@ -846,7 +847,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
}
|
||||
i_this->mCountDownTimers[0] = 100;
|
||||
i_this->mTargetAngleY = fopAcM_searchPlayerAngleY(i_this);
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
case 46:
|
||||
bomb_move_set(i_this, 1);
|
||||
@@ -889,7 +890,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
i_this->m0340 = NULL;
|
||||
}
|
||||
i_this->speedF = 0.0f;
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
break;
|
||||
case 47:
|
||||
bomb_move_set(i_this, 1);
|
||||
@@ -930,7 +931,7 @@ static void action_itai_move(am_class* i_this) {
|
||||
i_this->m0340->setGlobalRTMatrix(i_this->mpMorf->getModel()->getAnmMtx(2));
|
||||
}
|
||||
|
||||
if (i_this->mState == 41 || i_this->mState == 42) {
|
||||
if (i_this->mMode == 41 || i_this->mMode == 42) {
|
||||
bomb_nomi_check(i_this);
|
||||
}
|
||||
}
|
||||
@@ -987,11 +988,11 @@ static BOOL daAM_Execute(am_class* i_this) {
|
||||
|
||||
i_this->speedF = 0.0f;
|
||||
i_this->mAction = ACTION_ITAI_MOVE;
|
||||
i_this->mState = 47;
|
||||
i_this->mMode = 47;
|
||||
}
|
||||
|
||||
cLib_addCalcAngleS2(&i_this->current.angle.y, i_this->mTargetAngleY, 1, 0x500);
|
||||
if (i_this->mState != 46 && i_this->mState != 47 && i_this->mState != 31) {
|
||||
if (i_this->mMode != 46 && i_this->mMode != 47 && i_this->mMode != 31) {
|
||||
cLib_addCalcAngleS2(&i_this->shape_angle.y, i_this->current.angle.y, 1, 0x500);
|
||||
}
|
||||
|
||||
@@ -1348,7 +1349,7 @@ actor_process_profile_definition g_profile_AM = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00BD,
|
||||
/* Priority */ PRIO_AM,
|
||||
/* Actor SubMtd */ &l_daAM_Method,
|
||||
/* Status */ fopAcStts_SHOWMAP_e | fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
+58
-57
@@ -7,6 +7,7 @@
|
||||
#include "d/res/res_am2.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_bg_s_lin_chk.h"
|
||||
#include "d/d_s_play.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
@@ -177,7 +178,7 @@ static BOOL medama_atari_check(am2_class* i_this) {
|
||||
i_this->mNeedleCyl.OnAtHitBit();
|
||||
i_this->mNeedleCyl.OnTgSetBit();
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 2;
|
||||
i_this->mMode = 2;
|
||||
} else {
|
||||
dComIfGp_particle_set(dPa_name::ID_COMMON_0010, &hitPos, &player->shape_angle);
|
||||
// Using the fopAcM_seStart inline breaks the codegen.
|
||||
@@ -185,7 +186,7 @@ static BOOL medama_atari_check(am2_class* i_this) {
|
||||
mDoAud_seStart(JA_SE_CM_AM2_PARALYZED, &i_this->eyePos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_AM2_PARALYZED, 0x42);
|
||||
i_this->mAction = ACTION_MAHI;
|
||||
i_this->mState = 10;
|
||||
i_this->mMode = 10;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
@@ -294,7 +295,7 @@ static BOOL week_atari_check(am2_class* i_this) {
|
||||
}
|
||||
|
||||
i_this->mAction = ACTION_ITAI;
|
||||
i_this->mState = 20;
|
||||
i_this->mMode = 20;
|
||||
if (i_this->m2CE == 7 || i_this->m2CE == 8) {
|
||||
actor->health = 0;
|
||||
}
|
||||
@@ -341,7 +342,7 @@ static BOOL body_atari_check(am2_class* i_this) {
|
||||
break;
|
||||
}
|
||||
i_this->mAction = ACTION_HANDOU_MOVE;
|
||||
i_this->mState = 30;
|
||||
i_this->mMode = 30;
|
||||
i_this->m2CE = 7;
|
||||
if (player->getCutType() == 0x11) {
|
||||
i_this->m2CE = 8;
|
||||
@@ -387,7 +388,7 @@ static BOOL Line_check(am2_class* i_this, cXyz destPos) {
|
||||
/* 0000177C-00001A24 .text naraku_check__FP9am2_class */
|
||||
static BOOL naraku_check(am2_class* i_this) {
|
||||
// Checks if the Armos has fallen into an abyss.
|
||||
if (i_this->mAcch.GetGroundH() != C_BG_MIN_HEIGHT &&
|
||||
if (i_this->mAcch.GetGroundH() != -G_CM3D_F_INF &&
|
||||
dComIfG_Bgsp()->ChkPolySafe(i_this->mAcch.m_gnd) &&
|
||||
dComIfG_Bgsp()->GetGroundCode(i_this->mAcch.m_gnd) == 4) // Abyss ground code
|
||||
{
|
||||
@@ -448,7 +449,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
|
||||
cXyz offset;
|
||||
cXyz rotOffset;
|
||||
if (i_this->mState == 4 || i_this->mState == 5) {
|
||||
if (i_this->mMode == 4 || i_this->mMode == 5) {
|
||||
cMtx_YrotS(*calc_mtx, i_this->current.angle.y);
|
||||
offset.set(0.0f, 0.0f, 200.0f);
|
||||
MtxPosition(&offset, &rotOffset);
|
||||
@@ -456,7 +457,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
rotOffset.y += 100.0f + REG12_F(19);
|
||||
}
|
||||
|
||||
switch (i_this->mState) {
|
||||
switch (i_this->mMode) {
|
||||
case 0:
|
||||
for (int i = 0; i < ARRAY_SIZE(i_this->mCountUpTimers); i++) {
|
||||
i_this->mCountUpTimers[i] = 0;
|
||||
@@ -465,7 +466,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
if (i_this->mCurrBckIdx != AM2_BCK_WAIT) {
|
||||
anm_init(i_this, AM2_BCK_WAIT, 10.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
}
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
case 1: {
|
||||
f32 playerDist = fopAcM_searchPlayerDistance(i_this);
|
||||
@@ -479,7 +480,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_AM2_AWAKE, 0);
|
||||
i_this->mEyeSph.OnTgSetBit();
|
||||
i_this->mWeakSph.OnTgSetBit();
|
||||
i_this->mState += 1;
|
||||
i_this->mMode += 1;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -491,7 +492,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
if (!i_this->mpMorf->isStop()) {
|
||||
break;
|
||||
}
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
case 3: {
|
||||
for (int i = 0; i < ARRAY_SIZE(i_this->mCountUpTimers); i++) {
|
||||
@@ -501,7 +502,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
f32 playerDist = fopAcM_searchPlayerDistance(i_this);
|
||||
f32 radiusAdjust = 200.0f;
|
||||
if (playerDist > i_this->mAreaRadius + radiusAdjust) {
|
||||
i_this->mState = 6;
|
||||
i_this->mMode = 6;
|
||||
} else {
|
||||
i_this->mNeedleCyl.OnAtSetBit();
|
||||
i_this->mNeedleCyl.OnAtHitBit();
|
||||
@@ -512,7 +513,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
if (i_this->mCurrBckIdx != AM2_BCK_JUMP) {
|
||||
anm_init(i_this, AM2_BCK_JUMP, 2.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
}
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -521,11 +522,11 @@ static void action_dousa(am2_class* i_this) {
|
||||
i_this->gravity = -3.0f;
|
||||
i_this->speed.y = 12.0f;
|
||||
fopAcM_seStart(i_this, JA_SE_CM_AM2_LANDING, 0);
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
s16 angleDiff = cLib_distanceAngleS(i_this->shape_angle.y, i_this->current.angle.y);
|
||||
if (angleDiff < 0x1000) {
|
||||
if (Line_check(i_this, rotOffset) || player->getDamageWaitTimer() == 0) {
|
||||
i_this->mState = 5;
|
||||
i_this->mMode = 5;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -552,7 +553,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
}
|
||||
|
||||
if (i_this->mCountUpTimers[0] > 8) {
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
} else {
|
||||
i_this->speedF = 9.0f;
|
||||
i_this->gravity = -8.0f;
|
||||
@@ -570,7 +571,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
fopAcM_seStart(i_this, JA_SE_CM_AM2_SPIKE_IN, 0);
|
||||
i_this->mWeakSph.OffTgSetBit();
|
||||
i_this->mWeakSph.ClrTgHit();
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
case 7:
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
@@ -583,7 +584,7 @@ static void action_dousa(am2_class* i_this) {
|
||||
i_this->mNeedleCyl.ClrTgHit();
|
||||
i_this->m304 = i_this->current.pos;
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 1;
|
||||
i_this->mMode = 1;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -598,10 +599,10 @@ static void action_dousa(am2_class* i_this) {
|
||||
fopAcM_delete(i_this);
|
||||
} else {
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = 40;
|
||||
i_this->mMode = 40;
|
||||
}
|
||||
} else if (!medama_atari_check(i_this)) {
|
||||
if (i_this->mState < 3 || !week_atari_check(i_this)) {
|
||||
if (i_this->mMode < 3 || !week_atari_check(i_this)) {
|
||||
body_atari_check(i_this);
|
||||
}
|
||||
}
|
||||
@@ -612,7 +613,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
daPy_py_c* player = (daPy_py_c*)dComIfGp_getPlayer(0);
|
||||
fopAc_ac_c* actor = i_this; // Fixes regswaps
|
||||
|
||||
switch (i_this->mState) {
|
||||
switch (i_this->mMode) {
|
||||
case 10:
|
||||
for (int i = 0; i < ARRAY_SIZE(i_this->mCountUpTimers); i++) {
|
||||
i_this->mCountUpTimers[i] = 0;
|
||||
@@ -631,7 +632,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
fopAcM_seStart(actor, JA_SE_CM_AM2_SPIKE_IN, 0);
|
||||
anm_init(i_this, AM2_BCK_DAMAGE, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
break;
|
||||
case 11:
|
||||
cLib_addCalc0(&actor->speedF, 0.5f, 1.0f);
|
||||
@@ -640,7 +641,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
actor->speedF = 0.0f;
|
||||
i_this->mCountDownTimers[2] = 20*30;
|
||||
anm_init(i_this, AM2_BCK_MAHI, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -653,7 +654,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
fopAcM_delete(actor);
|
||||
} else {
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = 40;
|
||||
i_this->mMode = 40;
|
||||
}
|
||||
} else {
|
||||
if (i_this->mCountUpTimers[1] != 0 && i_this->mAcch.ChkGroundHit()) {
|
||||
@@ -672,7 +673,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
actor->speedF = 0.0f;
|
||||
i_this->mbNotInHomeRoom = false;
|
||||
i_this->mBodyCyl.OffCoSetBit();
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -692,11 +693,11 @@ static void action_mahi(am2_class* i_this) {
|
||||
actor->speed.y = 25.0f;
|
||||
actor->speedF = 35.0f;
|
||||
i_this->mAcch.OnLineCheck();
|
||||
i_this->mState = 14;
|
||||
i_this->mMode = 14;
|
||||
} else {
|
||||
actor->gravity = -3.0f;
|
||||
i_this->mCountUpTimers[1] = 1;
|
||||
i_this->mState = 12;
|
||||
i_this->mMode = 12;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -710,7 +711,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
} else {
|
||||
i_this->mAcch.OffLineCheck();
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = 40;
|
||||
i_this->mMode = 40;
|
||||
}
|
||||
} else {
|
||||
if (i_this->mAcch.ChkGroundHit()) {
|
||||
@@ -740,7 +741,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
} else {
|
||||
actor->speedF = 0.0f;
|
||||
i_this->mCountUpTimers[0] = 0;
|
||||
i_this->mState = 12;
|
||||
i_this->mMode = 12;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -753,7 +754,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
fopAcM_delete(actor);
|
||||
} else {
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = 40;
|
||||
i_this->mMode = 40;
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -764,14 +765,14 @@ static void action_mahi(am2_class* i_this) {
|
||||
actor->attention_info.flags = fopAc_Attn_LOCKON_BATTLE_e;
|
||||
fopAcM_OnStatus(actor, fopAcStts_SHOWMAP_e);
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
i_this->mTargetAngleY = actor->current.angle.y;
|
||||
|
||||
if (i_this->mState >= 12 && i_this->mState != 15) {
|
||||
if (i_this->mMode >= 12 && i_this->mMode != 15) {
|
||||
if (i_this->mStartsInactive == 1 && i_this->mSwitch != 0xFF) {
|
||||
if (!dComIfGs_isSwitch(i_this->mSwitch, dComIfGp_roomControl_getStayNo())) {
|
||||
i_this->mCountDownTimers[2] = 20*30;
|
||||
@@ -781,7 +782,7 @@ static void action_mahi(am2_class* i_this) {
|
||||
|
||||
i_this->mSwitch = 0xFF;
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 0;
|
||||
i_this->mMode = 0;
|
||||
|
||||
if (fopAcM_CheckStatus(actor, fopAcStts_CARRY_e)) {
|
||||
fopAcM_cancelCarryNow(actor);
|
||||
@@ -811,19 +812,19 @@ static void action_mahi(am2_class* i_this) {
|
||||
actor->gravity = -4.0f;
|
||||
actor->speed.y = 20.0f;
|
||||
i_this->mBodyCyl.OnCoSetBit();
|
||||
i_this->mState = 15;
|
||||
i_this->mMode = 15;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (fopAcM_CheckStatus(actor, fopAcStts_CARRY_e) || i_this->mState == 15 || !week_atari_check(i_this)) {
|
||||
if (fopAcM_CheckStatus(actor, fopAcStts_CARRY_e) || i_this->mMode == 15 || !week_atari_check(i_this)) {
|
||||
body_atari_check(i_this);
|
||||
}
|
||||
}
|
||||
|
||||
/* 00002B08-000032AC .text action_itai__FP9am2_class */
|
||||
static void action_itai(am2_class* i_this) {
|
||||
switch (i_this->mState) {
|
||||
switch (i_this->mMode) {
|
||||
case 20:
|
||||
for (int i = 0; i < ARRAY_SIZE(i_this->mCountUpTimers); i++) {
|
||||
i_this->mCountUpTimers[i] = 0;
|
||||
@@ -845,9 +846,9 @@ static void action_itai(am2_class* i_this) {
|
||||
if (i_this->mCountDownTimers[2] > 5) {
|
||||
i_this->speedF = 5.0f;
|
||||
}
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
} else {
|
||||
i_this->mState = 22;
|
||||
i_this->mMode = 22;
|
||||
}
|
||||
break;
|
||||
case 21:
|
||||
@@ -857,11 +858,11 @@ static void action_itai(am2_class* i_this) {
|
||||
i_this->gravity = -3.0f;
|
||||
if (i_this->mCountDownTimers[2] < 5) {
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
} else {
|
||||
anm_init(i_this, AM2_BCK_MAHI, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->mAction = ACTION_MAHI;
|
||||
i_this->mState = 12;
|
||||
i_this->mMode = 12;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -871,7 +872,7 @@ static void action_itai(am2_class* i_this) {
|
||||
i_this->mEyeSph.ClrTgHit();
|
||||
i_this->mWeakSph.ClrTgHit();
|
||||
anm_init(i_this, AM2_BCK_DEAD1, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
break;
|
||||
case 23:
|
||||
if (!i_this->mpMorf->isStop()) {
|
||||
@@ -885,7 +886,7 @@ static void action_itai(am2_class* i_this) {
|
||||
i_this->mCountDownTimers[0] = 100;
|
||||
i_this->current.angle.y = fopAcM_searchPlayerAngleY(i_this);
|
||||
anm_init(i_this, AM2_BCK_DEAD2, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
case 24:
|
||||
if (i_this->speed.y > 0.0f && i_this->mCountUpTimers[1] == 0) {
|
||||
@@ -921,7 +922,7 @@ static void action_itai(am2_class* i_this) {
|
||||
|
||||
i_this->speedF = 0.0f;
|
||||
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
break;
|
||||
case 25:
|
||||
@@ -942,15 +943,15 @@ static void action_itai(am2_class* i_this) {
|
||||
|
||||
if (naraku_check(i_this)) {
|
||||
if (i_this->mbNotInHomeRoom || i_this->health <= 0) {
|
||||
if (i_this->mState != 25) {
|
||||
if (i_this->mMode != 25) {
|
||||
anm_init(i_this, AM2_BCK_DEAD3, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
fopAcM_seStart(i_this, JA_SE_CM_AM2_BEF_EXPLODE, 0);
|
||||
i_this->speedF = 0.0f;
|
||||
i_this->mState = 25;
|
||||
i_this->mMode = 25;
|
||||
}
|
||||
} else {
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = 40;
|
||||
i_this->mMode = 40;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -958,7 +959,7 @@ static void action_itai(am2_class* i_this) {
|
||||
/* 000032AC-000034A4 .text action_handou_move__FP9am2_class */
|
||||
static void action_handou_move(am2_class* i_this) {
|
||||
daPy_py_c* player = daPy_getPlayerActorClass();
|
||||
switch (i_this->mState) {
|
||||
switch (i_this->mMode) {
|
||||
case 30: {
|
||||
i_this->speedF = 40.0f;
|
||||
s16 angleToPlayer = fopAcM_searchPlayerAngleY(i_this);
|
||||
@@ -972,7 +973,7 @@ static void action_handou_move(am2_class* i_this) {
|
||||
i_this->mNeedleCyl.OffTgSetBit();
|
||||
i_this->mNeedleCyl.ClrTgHit();
|
||||
i_this->mTargetAngleY = i_this->current.angle.y;
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
}
|
||||
case 31:
|
||||
@@ -982,12 +983,12 @@ static void action_handou_move(am2_class* i_this) {
|
||||
i_this->speedF = 0.0f;
|
||||
i_this->current.angle.y = i_this->shape_angle.y;
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 3;
|
||||
i_this->mMode = 3;
|
||||
if (i_this->mStartsInactive == 1 && i_this->mSwitch != 0xFF && !dComIfGs_isSwitch(i_this->mSwitch, dComIfGp_roomControl_getStayNo())) {
|
||||
i_this->attention_info.flags = 0;
|
||||
i_this->mCountDownTimers[2] = 20*30;
|
||||
i_this->mAction = ACTION_MAHI;
|
||||
i_this->mState = 12;
|
||||
i_this->mMode = 12;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -997,7 +998,7 @@ static void action_handou_move(am2_class* i_this) {
|
||||
fopAcM_delete(i_this);
|
||||
} else {
|
||||
i_this->mAction = ACTION_MODORU_MOVE;
|
||||
i_this->mState = 40;
|
||||
i_this->mMode = 40;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1005,7 +1006,7 @@ static void action_handou_move(am2_class* i_this) {
|
||||
/* 000034A4-0000379C .text action_modoru_move__FP9am2_class */
|
||||
static void action_modoru_move(am2_class* i_this) {
|
||||
// Respawns the Armos back at its spawn point after it falls into an abyss.
|
||||
switch (i_this->mState) {
|
||||
switch (i_this->mMode) {
|
||||
case 40:
|
||||
dCam_getBody()->ForceLockOff(fopAcM_GetID(i_this));
|
||||
i_this->mInAbyssTimer = 0;
|
||||
@@ -1013,7 +1014,7 @@ static void action_modoru_move(am2_class* i_this) {
|
||||
i_this->mRippleCb.remove();
|
||||
anm_init(i_this, AM2_BCK_WAIT, 10.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
fopAcM_seStart(i_this, JA_SE_CM_AM2_WTR_RECOVER, 0);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
case 41:
|
||||
cLib_addCalc0(&i_this->scale.x, 1.0f, 0.1f);
|
||||
@@ -1034,7 +1035,7 @@ static void action_modoru_move(am2_class* i_this) {
|
||||
i_this->current.pos = i_this->mSpawnPos;
|
||||
i_this->mTargetAngleY = i_this->current.angle.y;
|
||||
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
break;
|
||||
case 42:
|
||||
@@ -1056,13 +1057,13 @@ static void action_modoru_move(am2_class* i_this) {
|
||||
i_this->mWeakSph.ClrTgHit();
|
||||
i_this->mNeedleCyl.ClrTgHit();
|
||||
i_this->mAction = ACTION_DOUSA;
|
||||
i_this->mState = 0;
|
||||
i_this->mMode = 0;
|
||||
|
||||
if (i_this->mStartsInactive == 1 && i_this->mSwitch != 0xFF && !dComIfGs_isSwitch(i_this->mSwitch, dComIfGp_roomControl_getStayNo())) {
|
||||
i_this->attention_info.flags = 0;
|
||||
i_this->mCountDownTimers[2] = 20*30;
|
||||
i_this->mAction = ACTION_MAHI;
|
||||
i_this->mState = 12;
|
||||
i_this->mMode = 12;
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1456,7 +1457,7 @@ static cPhs_State daAM2_Create(fopAc_ac_c* i_actor) {
|
||||
i_this->attention_info.flags = 0;
|
||||
i_this->mCountDownTimers[2] = 20*30;
|
||||
i_this->mAction = ACTION_MAHI;
|
||||
i_this->mState = 12;
|
||||
i_this->mMode = 12;
|
||||
}
|
||||
|
||||
i_this->mAcchRadius = 40.0f + REG8_F(10);
|
||||
@@ -1483,7 +1484,7 @@ actor_process_profile_definition g_profile_AM2 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00BE,
|
||||
/* Priority */ PRIO_AM2,
|
||||
/* Actor SubMtd */ &l_daAM2_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_FREEZE_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_amiprop.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000000D4 .text _delete__11daAmiProp_cFv */
|
||||
bool daAmiProp_c::_delete() {
|
||||
@@ -94,7 +95,7 @@ actor_process_profile_definition g_profile_AMI_PROP = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0090,
|
||||
/* Priority */ PRIO_AMI_PROP,
|
||||
/* Actor SubMtd */ &daAmiPropMethodTable,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/actor/d_a_bk.h"
|
||||
#include "d/actor/d_a_bb.h"
|
||||
|
||||
@@ -356,7 +357,7 @@ actor_process_profile_definition g_profile_ANDSW0 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0135,
|
||||
/* Priority */ PRIO_ANDSW0,
|
||||
/* Actor SubMtd */ &l_daAndsw0_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
enum Action {
|
||||
ACT_ON_ALL,
|
||||
@@ -271,7 +272,7 @@ actor_process_profile_definition g_profile_ANDSW2 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0136,
|
||||
/* Priority */ PRIO_ANDSW2,
|
||||
/* Actor SubMtd */ &l_daAndsw2_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_item_data.h"
|
||||
#include "d/actor/d_a_player.h"
|
||||
#include "d/actor/d_a_player_main.h"
|
||||
@@ -514,7 +515,7 @@ void daArrow_c::setRoomInfo() {
|
||||
|
||||
mGndChk.SetPos(¤t.pos);
|
||||
f32 groundY = dComIfG_Bgsp()->GroundCross(&mGndChk);
|
||||
if (groundY != C_BG_MIN_HEIGHT) {
|
||||
if (groundY != -G_CM3D_F_INF) {
|
||||
roomNo = dComIfG_Bgsp()->GetRoomId(mGndChk);
|
||||
tevStr.mEnvrIdxOverride = dComIfG_Bgsp()->GetPolyColor(mGndChk);
|
||||
} else {
|
||||
@@ -1294,7 +1295,7 @@ actor_process_profile_definition g_profile_ARROW = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x01BF,
|
||||
/* Priority */ PRIO_ARROW,
|
||||
/* Actor SubMtd */ &daArrowMethodTable,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/actor/d_a_player_main.h"
|
||||
#include "d/actor/d_a_arrow.h"
|
||||
|
||||
@@ -311,7 +312,7 @@ actor_process_profile_definition g_profile_ARROW_ICEEFF = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x01C0,
|
||||
/* Priority */ PRIO_ARROW_ICEEFF,
|
||||
/* Actor SubMtd */ &daArrow_IceeffMethodTable,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "d/actor/d_a_arrow.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
#include "m_Do/m_Do_graphic.h"
|
||||
#include "SSystem/SComponent/c_lib.h"
|
||||
@@ -417,7 +418,7 @@ actor_process_profile_definition g_profile_ARROW_LIGHTEFF = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x01C1,
|
||||
/* Priority */ PRIO_ARROW_LIGHTEFF,
|
||||
/* Actor SubMtd */ &daArrow_LighteffMethodTable,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_atdoor.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000084 .text getSwbit__10daAtdoor_cFv */
|
||||
void daAtdoor_c::getSwbit() {
|
||||
@@ -104,7 +105,7 @@ actor_process_profile_definition g_profile_ATDOOR = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x012F,
|
||||
/* Priority */ PRIO_ATDOOR,
|
||||
/* Actor SubMtd */ &l_daAtdoor_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_att.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/actor/d_a_bgn.h"
|
||||
@@ -250,7 +251,7 @@ actor_process_profile_definition g_profile_ATT = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x019C,
|
||||
/* Priority */ PRIO_ATT,
|
||||
/* Actor SubMtd */ &l_daAtt_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "d/actor/d_a_player_main.h"
|
||||
#include "d/d_camera.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "m_Do/m_Do_controller_pad.h"
|
||||
|
||||
#include "weak_bss_936_to_1036.h" // IWYU pragma: keep
|
||||
@@ -67,8 +68,8 @@ static NpcDatStruct l_npc_dat[7] = {
|
||||
{0.3f, 0.5f, 0x4, 0x6, 450 },
|
||||
{0.3f, 0.6f, 0x3, 0x7, 500 },
|
||||
{0.4f, 0.7f, 0x2, 0x4, 250 },
|
||||
{0.5f, 1.0f, 0x2, 0x3, VERSION_SELECT(998, 990, 990) },
|
||||
{0.4f, 0.5f, 0x3, 0x4, VERSION_SELECT(998, 990, 990) },
|
||||
{0.5f, 1.0f, 0x2, 0x3, VERSION_SELECT(998, 998, 990, 990) },
|
||||
{0.4f, 0.5f, 0x3, 0x4, VERSION_SELECT(998, 998, 990, 990) },
|
||||
{0.7f, 1.2f, 0x2, 0x2, 150 },
|
||||
};
|
||||
|
||||
@@ -1661,7 +1662,7 @@ actor_process_profile_definition g_profile_AUCTION = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x01E0,
|
||||
/* Priority */ PRIO_AUCTION,
|
||||
/* Actor SubMtd */ &daAuctionMethodTable,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_bb.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000003C8 .text nodeCallBack__FP7J3DNodei */
|
||||
static BOOL nodeCallBack(J3DNode*, int) {
|
||||
@@ -185,7 +186,7 @@ actor_process_profile_definition g_profile_BB = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x000E,
|
||||
/* Priority */ PRIO_BB,
|
||||
/* Actor SubMtd */ &l_daBb_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e | fopAcStts_UNK80000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_bdk.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-0000015C .text __ct__11daBdk_HIO_cFv */
|
||||
daBdk_HIO_c::daBdk_HIO_c() {
|
||||
@@ -330,7 +331,7 @@ actor_process_profile_definition g_profile_BDK = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E3,
|
||||
/* Priority */ PRIO_BDK,
|
||||
/* Actor SubMtd */ &l_daBdk_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_bdkobj.h"
|
||||
#include "d/d_bg_w.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000104 .text ride_call_back__FP4dBgWP10fopAc_ac_cP10fopAc_ac_c */
|
||||
void ride_call_back(dBgW*, fopAc_ac_c*, fopAc_ac_c*) {
|
||||
@@ -85,7 +86,7 @@ actor_process_profile_definition g_profile_BDKOBJ = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E4,
|
||||
/* Priority */ PRIO_BDKOBJ,
|
||||
/* Actor SubMtd */ &l_daBdkobj_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_beam.h"
|
||||
#include "d/d_cc_d.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000118 .text __ct__12daBeam_HIO_cFv */
|
||||
daBeam_HIO_c::daBeam_HIO_c() {
|
||||
@@ -125,7 +126,7 @@ actor_process_profile_definition g_profile_Beam = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00DC,
|
||||
/* Priority */ PRIO_Beam,
|
||||
/* Actor SubMtd */ &daBeamMethodTable,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bflower.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/res/res_vbakh.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/actor/d_a_player_main.h"
|
||||
@@ -531,7 +532,7 @@ actor_process_profile_definition g_profile_BOMB_FLOWER = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0117,
|
||||
/* Priority */ PRIO_BOMB_FLOWER,
|
||||
/* Actor SubMtd */ &daBFlowerMethodTable,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -276,7 +276,7 @@ static BOOL daBg_Draw(daBg_c* i_this) {
|
||||
|
||||
BOOL daBg_c::execute() {
|
||||
if (mUnloadTimer != 0) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
mUnloadTimer = 0;
|
||||
fopAcM_delete(this);
|
||||
#else
|
||||
@@ -287,7 +287,7 @@ BOOL daBg_c::execute() {
|
||||
}
|
||||
|
||||
if (dComIfGp_roomControl_checkStatusFlag(fopAcM_GetParam(this), 0x04)) {
|
||||
#if VERSION == VERSION_JPN
|
||||
#if VERSION <= VERSION_JPN
|
||||
mUnloadTimer = 1;
|
||||
#else
|
||||
if (strcmp(dComIfGp_getStartStageName(), "sea") == 0)
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "d/actor/d_a_bgn2.h"
|
||||
#include "d/actor/d_a_bgn3.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
|
||||
/* 000000EC-000003F0 .text __ct__11daBgn_HIO_cFv */
|
||||
@@ -293,7 +294,7 @@ actor_process_profile_definition g_profile_BGN = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E8,
|
||||
/* Priority */ PRIO_BGN,
|
||||
/* Actor SubMtd */ &l_daBgn_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bgn2.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000194 .text __ct__12daBgn2_HIO_cFv */
|
||||
daBgn2_HIO_c::daBgn2_HIO_c() {
|
||||
@@ -164,7 +165,7 @@ actor_process_profile_definition g_profile_BGN2 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E9,
|
||||
/* Priority */ PRIO_BGN2,
|
||||
/* Actor SubMtd */ &l_daBgn2_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bgn3.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000001F4 .text __ct__12daBgn3_HIO_cFv */
|
||||
daBgn3_HIO_c::daBgn3_HIO_c() {
|
||||
@@ -164,7 +165,7 @@ actor_process_profile_definition g_profile_BGN3 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00EA,
|
||||
/* Priority */ PRIO_BGN3,
|
||||
/* Actor SubMtd */ &l_daBgn3_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bigelf.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-0000016C .text oct_delete__10daBigelf_cFv */
|
||||
void daBigelf_c::oct_delete() {
|
||||
@@ -374,7 +375,7 @@ actor_process_profile_definition g_profile_BIGELF = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x012B,
|
||||
/* Priority */ PRIO_BIGELF,
|
||||
/* Actor SubMtd */ &l_daBigelf_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_kankyo.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/actor/d_a_btd.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
@@ -290,7 +291,7 @@ actor_process_profile_definition g_profile_BITA = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0096,
|
||||
/* Priority */ PRIO_BITA,
|
||||
/* Actor SubMtd */ &l_daBita_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENV_e,
|
||||
|
||||
+300
-299
File diff suppressed because it is too large
Load Diff
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bl.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000178 .text draw_SUB__FP8bl_class */
|
||||
void draw_SUB(bl_class*) {
|
||||
@@ -174,7 +175,7 @@ actor_process_profile_definition g_profile_BL = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00C2,
|
||||
/* Priority */ PRIO_BL,
|
||||
/* Actor SubMtd */ &l_daBL_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e | fopAcStts_UNK80000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bmd.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000134 .text __ct__11daBmd_HIO_cFv */
|
||||
daBmd_HIO_c::daBmd_HIO_c() {
|
||||
@@ -169,7 +170,7 @@ actor_process_profile_definition g_profile_BMD = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00DF,
|
||||
/* Priority */ PRIO_BMD,
|
||||
/* Actor SubMtd */ &l_daBmd_Method,
|
||||
/* Status */ fopAcStts_SHOWMAP_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_bmdfoot.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000114 .text __ct__15daBmdfoot_HIO_cFv */
|
||||
daBmdfoot_HIO_c::daBmdfoot_HIO_c() {
|
||||
@@ -125,7 +126,7 @@ actor_process_profile_definition g_profile_BMDFOOT = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E1,
|
||||
/* Priority */ PRIO_BMDFOOT,
|
||||
/* Actor SubMtd */ &l_daBmdfoot_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bmdhand.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000118 .text __ct__15daBmdhand_HIO_cFv */
|
||||
daBmdhand_HIO_c::daBmdhand_HIO_c() {
|
||||
@@ -139,7 +140,7 @@ actor_process_profile_definition g_profile_BMDHAND = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E0,
|
||||
/* Priority */ PRIO_BMDHAND,
|
||||
/* Actor SubMtd */ &l_daBmdhand_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bo.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000001E8 .text smoke_set__FP8bo_class */
|
||||
void smoke_set(bo_class*) {
|
||||
@@ -154,7 +155,7 @@ actor_process_profile_definition g_profile_BO = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00C9,
|
||||
/* Priority */ PRIO_BO,
|
||||
/* Actor SubMtd */ &l_daBO_Method,
|
||||
/* Status */ fopAcStts_SHOWMAP_e | fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_boko.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_bg_s_lin_chk.h"
|
||||
|
||||
#include "weak_bss_936_to_1036.h" // IWYU pragma: keep
|
||||
@@ -69,7 +70,7 @@ void daBoko_c::setFlameEffect() {
|
||||
/* 00001340-000013CC .text setRoomInfo__8daBoko_cFv */
|
||||
void daBoko_c::setRoomInfo() {
|
||||
int roomNo;
|
||||
if (mAcch.GetGroundH() != C_BG_MIN_HEIGHT) {
|
||||
if (mAcch.GetGroundH() != -G_CM3D_F_INF) {
|
||||
roomNo = dComIfG_Bgsp()->GetRoomId(mAcch.m_gnd);
|
||||
tevStr.mEnvrIdxOverride = dComIfG_Bgsp()->GetPolyColor(mAcch.m_gnd);
|
||||
} else {
|
||||
@@ -194,7 +195,7 @@ BOOL daBoko_c::procCarry() {
|
||||
int i;
|
||||
for (i = 0; i < 3; i++) {
|
||||
m_ground_check.SetPos(¤t.pos);
|
||||
if (dComIfG_Bgsp()->GroundCross(&m_ground_check) != C_BG_MIN_HEIGHT) {
|
||||
if (dComIfG_Bgsp()->GroundCross(&m_ground_check) != -G_CM3D_F_INF) {
|
||||
break;
|
||||
}
|
||||
current.pos.x -= 50.0f * cM_ssin(shape_angle.y);
|
||||
@@ -283,7 +284,7 @@ actor_process_profile_definition g_profile_BOKO = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x01A0,
|
||||
/* Priority */ PRIO_BOKO,
|
||||
/* Actor SubMtd */ &l_daBoko_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "d/actor/d_a_player.h"
|
||||
#include "d/d_a_obj.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_kankyo_wether.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/res/res_vbakh.h"
|
||||
@@ -291,12 +292,12 @@ namespace daBomb2 {
|
||||
mAcch.ClrRoofNone();
|
||||
mAcch.m_roof_crr_height = 50.0f;
|
||||
mAcch.OnLineCheck();
|
||||
field_0x51C = C_BG_MIN_HEIGHT;
|
||||
field_0x520 = C_BG_MIN_HEIGHT;
|
||||
field_0x51C = -G_CM3D_F_INF;
|
||||
field_0x520 = -G_CM3D_F_INF;
|
||||
field_0x524 = 0;
|
||||
mbWaterIn = 0;
|
||||
field_0x526 = 0;
|
||||
field_0x528 = C_BG_MIN_HEIGHT;
|
||||
field_0x528 = -G_CM3D_F_INF;
|
||||
}
|
||||
|
||||
dCcD_SrcSph Act_c::M_sph_src = {
|
||||
@@ -552,7 +553,7 @@ namespace daBomb2 {
|
||||
r5 = true;
|
||||
field_0x526 = 1;
|
||||
} else {
|
||||
field_0x520 = C_BG_MIN_HEIGHT;
|
||||
field_0x520 = -G_CM3D_F_INF;
|
||||
field_0x526 = 0;
|
||||
}
|
||||
mbWaterIn = r5;
|
||||
@@ -563,7 +564,7 @@ namespace daBomb2 {
|
||||
}
|
||||
|
||||
bool Act_c::chk_lava_in() const {
|
||||
if(field_0x51C == C_BG_MIN_HEIGHT) {
|
||||
if(field_0x51C == -G_CM3D_F_INF) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -572,7 +573,7 @@ namespace daBomb2 {
|
||||
|
||||
void Act_c::setRoomInfo() {
|
||||
s32 roomNo;
|
||||
if(mAcch.GetGroundH() != C_BG_MIN_HEIGHT) {
|
||||
if(mAcch.GetGroundH() != -G_CM3D_F_INF) {
|
||||
roomNo = dComIfG_Bgsp()->GetRoomId(mAcch.m_gnd);
|
||||
tevStr.mEnvrIdxOverride = dComIfG_Bgsp()->GetPolyColor(mAcch.m_gnd);
|
||||
}
|
||||
@@ -1091,7 +1092,7 @@ namespace daBomb2 {
|
||||
void Act_c::mode_sink() {
|
||||
f32 temp;
|
||||
bool temp2 = fopAcM_getWaterY(¤t.pos, &temp);
|
||||
if(temp2 && field_0x528 != C_BG_MIN_HEIGHT && --field_0x698 > 0) {
|
||||
if(temp2 && field_0x528 != -G_CM3D_F_INF && --field_0x698 > 0) {
|
||||
current.pos.y += temp - field_0x528;
|
||||
field_0x528 = temp;
|
||||
posMoveF();
|
||||
@@ -1350,7 +1351,7 @@ actor_process_profile_definition g_profile_Bomb2 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0116,
|
||||
/* Priority */ PRIO_Bomb2,
|
||||
/* Actor SubMtd */ &daBomb2::Mthd_Table,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
+11
-10
@@ -7,6 +7,7 @@
|
||||
#include "d/d_a_obj.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/actor/d_a_player_main.h"
|
||||
#include "d/actor/d_a_sea.h"
|
||||
#include "d/d_kankyo_wether.h"
|
||||
@@ -196,7 +197,7 @@ BOOL daBomb_c::draw() {
|
||||
draw_norm();
|
||||
}
|
||||
|
||||
if(fopAcM_GetModel(this) == 0 && mAcch.GetGroundH() != C_BG_MIN_HEIGHT) {
|
||||
if(fopAcM_GetModel(this) == 0 && mAcch.GetGroundH() != -G_CM3D_F_INF) {
|
||||
cM3dGPla* pNormal = dComIfG_Bgsp()->GetTriPla(mAcch.m_gnd);
|
||||
if(pNormal) {
|
||||
dComIfGd_setSimpleShadow(¤t.pos, mAcch.GetGroundH(), 25.0f, pNormal->GetNP());
|
||||
@@ -437,7 +438,7 @@ bool daBomb_c::checkExplodeBg() {
|
||||
/* 800DA320-800DA3A0 .text water_tention__8daBomb_cFv */
|
||||
void daBomb_c::water_tention() {
|
||||
if(chk_water_in()) {
|
||||
if(field_0x558 != C_BG_MIN_HEIGHT && field_0x55C != C_BG_MIN_HEIGHT) {
|
||||
if(field_0x558 != -G_CM3D_F_INF && field_0x55C != -G_CM3D_F_INF) {
|
||||
f32 temp = field_0x558 - field_0x55C;
|
||||
current.pos.y += temp < 0.0f ? 0.8f * temp : 0.2f * temp;
|
||||
}
|
||||
@@ -532,7 +533,7 @@ void daBomb_c::bgCrrPos_water() {
|
||||
r5 = true;
|
||||
field_0x562 = 1;
|
||||
} else {
|
||||
field_0x558 = C_BG_MIN_HEIGHT;
|
||||
field_0x558 = -G_CM3D_F_INF;
|
||||
field_0x562 = 0;
|
||||
}
|
||||
field_0x560 = r5 && !mbWaterIn;
|
||||
@@ -558,7 +559,7 @@ bool daBomb_c::chk_water_sink() {
|
||||
|
||||
/* 800DA768-800DA794 .text chk_lava_hit__8daBomb_cFv */
|
||||
bool daBomb_c::chk_lava_hit() {
|
||||
if(field_0x554 == C_BG_MIN_HEIGHT) {
|
||||
if(field_0x554 == -G_CM3D_F_INF) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -567,7 +568,7 @@ bool daBomb_c::chk_lava_hit() {
|
||||
|
||||
/* 800DA794-800DA7CC .text chk_dead_zone__8daBomb_cFv */
|
||||
bool daBomb_c::chk_dead_zone() {
|
||||
return mAcch.GetGroundH() == C_BG_MIN_HEIGHT && field_0x558 == C_BG_MIN_HEIGHT && field_0x554 == C_BG_MIN_HEIGHT;
|
||||
return mAcch.GetGroundH() == -G_CM3D_F_INF && field_0x558 == -G_CM3D_F_INF && field_0x554 == -G_CM3D_F_INF;
|
||||
}
|
||||
|
||||
/* 800DA7CC-800DA8C8 .text bound__8daBomb_cFf */
|
||||
@@ -628,7 +629,7 @@ void daBomb_c::set_real_shadow_flag() {
|
||||
/* 800DA9DC-800DAA60 .text setRoomInfo__8daBomb_cFv */
|
||||
void daBomb_c::setRoomInfo() {
|
||||
s32 roomNo;
|
||||
if(mAcch.GetGroundH() != C_BG_MIN_HEIGHT) {
|
||||
if(mAcch.GetGroundH() != -G_CM3D_F_INF) {
|
||||
roomNo = dComIfG_Bgsp()->GetRoomId(mAcch.m_gnd);
|
||||
tevStr.mEnvrIdxOverride = dComIfG_Bgsp()->GetPolyColor(mAcch.m_gnd);
|
||||
}
|
||||
@@ -1397,9 +1398,9 @@ void daBomb_c::create_init() {
|
||||
mAcch.m_roof_crr_height = 50.0f;
|
||||
mAcch.OnLineCheck();
|
||||
|
||||
field_0x554 = C_BG_MIN_HEIGHT;
|
||||
field_0x558 = C_BG_MIN_HEIGHT;
|
||||
field_0x55C = C_BG_MIN_HEIGHT;
|
||||
field_0x554 = -G_CM3D_F_INF;
|
||||
field_0x558 = -G_CM3D_F_INF;
|
||||
field_0x55C = -G_CM3D_F_INF;
|
||||
field_0x560 = 0;
|
||||
mbWaterIn = 0;
|
||||
field_0x562 = 0;
|
||||
@@ -1487,7 +1488,7 @@ actor_process_profile_definition g_profile_BOMB = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0115,
|
||||
/* Priority */ PRIO_BOMB,
|
||||
/* Actor SubMtd */ &l_daBomb_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_boomerang.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
#include "assets/l_sightMatDL.h"
|
||||
#include "assets/l_sightDL__d_a_boomerang.h"
|
||||
@@ -167,7 +168,7 @@ actor_process_profile_definition g_profile_BOOMERANG = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x019F,
|
||||
/* Priority */ PRIO_BOOMERANG,
|
||||
/* Actor SubMtd */ &l_daBoomerang_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "f_op/f_op_actor.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
|
||||
/* 00000078-00000080 .text daBossItem_IsDelete__FP14bossitem_class */
|
||||
@@ -56,7 +57,7 @@ actor_process_profile_definition g_profile_BOSSITEM = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00FB,
|
||||
/* Priority */ PRIO_BOSSITEM,
|
||||
/* Actor SubMtd */ &daBossItem_METHODS,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bpw.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000258 .text body_nodeCallBack__FP7J3DNodei */
|
||||
static BOOL body_nodeCallBack(J3DNode*, int) {
|
||||
@@ -304,7 +305,7 @@ actor_process_profile_definition g_profile_BPW = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00C6,
|
||||
/* Priority */ PRIO_BPW,
|
||||
/* Actor SubMtd */ &l_daBPW_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "JSystem/JUtility/JUTAssert.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
#include "d/d_kankyo.h"
|
||||
#include "JSystem/J3DGraphBase/J3DMaterial.h"
|
||||
@@ -233,7 +234,7 @@ actor_process_profile_definition g_profile_BRANCH = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0193,
|
||||
/* Priority */ PRIO_BRANCH,
|
||||
/* Actor SubMtd */ &l_daBranch_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_bridge.h"
|
||||
#include "d/d_bg_w.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000504 .text ride_call_back__FP4dBgWP10fopAc_ac_cP10fopAc_ac_c */
|
||||
void ride_call_back(dBgW*, fopAc_ac_c*, fopAc_ac_c*) {
|
||||
@@ -115,7 +116,7 @@ actor_process_profile_definition g_profile_BRIDGE = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0089,
|
||||
/* Priority */ PRIO_BRIDGE,
|
||||
/* Actor SubMtd */ &l_daBridge_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_bst.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000110 .text __ct__11daBst_HIO_cFv */
|
||||
daBst_HIO_c::daBst_HIO_c() {
|
||||
@@ -230,7 +231,7 @@ actor_process_profile_definition g_profile_BST = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E5,
|
||||
/* Priority */ PRIO_BST,
|
||||
/* Actor SubMtd */ &l_daBst_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_btd.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000001C8 .text __ct__11daBtd_HIO_cFv */
|
||||
daBtd_HIO_c::daBtd_HIO_c() {
|
||||
@@ -240,7 +241,7 @@ actor_process_profile_definition g_profile_BTD = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00DE,
|
||||
/* Priority */ PRIO_BTD,
|
||||
/* Actor SubMtd */ &l_daBtd_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bwd.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-0000019C .text __ct__11daBwd_HIO_cFv */
|
||||
daBwd_HIO_c::daBwd_HIO_c() {
|
||||
@@ -174,7 +175,7 @@ actor_process_profile_definition g_profile_BWD = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00CC,
|
||||
/* Priority */ PRIO_BWD,
|
||||
/* Actor SubMtd */ &l_daBwd_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_BOSS_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "d/d_bg_w_hf.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/actor/d_a_bwd.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "dolphin/gf/GFGeometry.h"
|
||||
@@ -276,7 +277,7 @@ actor_process_profile_definition g_profile_BWDG = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00CE,
|
||||
/* Priority */ PRIO_BWDG,
|
||||
/* Actor SubMtd */ &l_daBwdg_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_bwds.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000144 .text __ct__12daBwds_HIO_cFv */
|
||||
daBwds_HIO_c::daBwds_HIO_c() {
|
||||
@@ -114,7 +115,7 @@ actor_process_profile_definition g_profile_BWDS = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00CD,
|
||||
/* Priority */ PRIO_BWDS,
|
||||
/* Actor SubMtd */ &l_daBwds_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e | fopAcStts_UNK80000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_canon.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000002C8 .text set_mtx__9daCanon_cFv */
|
||||
void daCanon_c::set_mtx() {
|
||||
@@ -190,7 +191,7 @@ actor_process_profile_definition g_profile_Canon = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x01AD,
|
||||
/* Priority */ PRIO_Canon,
|
||||
/* Actor SubMtd */ &daCanonMethodTable,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_cc.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000002AC .text nodeCallBack__FP7J3DNodei */
|
||||
static BOOL nodeCallBack(J3DNode*, int) {
|
||||
@@ -184,7 +185,7 @@ actor_process_profile_definition g_profile_CC = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00C1,
|
||||
/* Priority */ PRIO_CC,
|
||||
/* Actor SubMtd */ &l_daCC_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e | fopAcStts_UNK80000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_coming2.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000164 .text chase_ship__Q29daComing25Act_cFv */
|
||||
void daComing2::Act_c::chase_ship() {
|
||||
@@ -228,7 +229,7 @@ actor_process_profile_definition g_profile_Coming2 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0028,
|
||||
/* Priority */ PRIO_Coming2,
|
||||
/* Actor SubMtd */ &daComing2::Mthd_Table,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_coming3.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000404 .text get_water_height__Q29daComing35Act_cFPfPiPC4cXyz */
|
||||
void daComing3::Act_c::get_water_height(float*, int*, const cXyz*) {
|
||||
@@ -168,7 +169,7 @@ actor_process_profile_definition g_profile_Coming3 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0029,
|
||||
/* Priority */ PRIO_Coming3,
|
||||
/* Actor SubMtd */ &daComing3::Mthd_Table,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_dai.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000000C4 .text _delete__7daDai_cFv */
|
||||
bool daDai_c::_delete() {
|
||||
@@ -134,7 +135,7 @@ actor_process_profile_definition g_profile_DAI = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0138,
|
||||
/* Priority */ PRIO_DAI,
|
||||
/* Actor SubMtd */ &daDaiMethodTable,
|
||||
/* Status */ fopAcStts_NOCULLEXEC_e | fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "SSystem/SComponent/c_math.h"
|
||||
#include "d/d_kankyo_wether.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_s_play.h"
|
||||
#include "d/res/res_fdai.h"
|
||||
#include "d/res/res_cloth.h"
|
||||
@@ -368,7 +369,7 @@ void daStandItem_c::CreateInit() {
|
||||
m690 = NULL;
|
||||
m694 = NULL;
|
||||
m698 = NULL;
|
||||
#if VERSION != VERSION_JPN
|
||||
#if VERSION > VERSION_JPN
|
||||
g_env_light.settingTevStruct(TEV_TYPE_ACTOR, ¤t.pos, &tevStr);
|
||||
#endif
|
||||
}
|
||||
@@ -816,7 +817,7 @@ actor_process_profile_definition g_profile_STANDITEM = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0101,
|
||||
/* Priority */ PRIO_STANDITEM,
|
||||
/* Actor SubMtd */ &daStandItemMethodTable,
|
||||
/* Status */ fopAcStts_NOCULLEXEC_e | fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_daiocta.h"
|
||||
#include "d/d_cc_d.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000002B0 .text __ct__15daDaiocta_HIO_cFv */
|
||||
daDaiocta_HIO_c::daDaiocta_HIO_c() {
|
||||
@@ -305,7 +306,7 @@ actor_process_profile_definition g_profile_DAIOCTA = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00D5,
|
||||
/* Priority */ PRIO_DAIOCTA,
|
||||
/* Actor SubMtd */ &daDaioctaMethodTable,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_daiocta_eye.h"
|
||||
#include "d/d_cc_d.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-000001B0 .text __ct__19daDaiocta_Eye_HIO_cFv */
|
||||
daDaiocta_Eye_HIO_c::daDaiocta_Eye_HIO_c() {
|
||||
@@ -155,7 +156,7 @@ actor_process_profile_definition g_profile_DAIOCTA_EYE = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00D6,
|
||||
/* Priority */ PRIO_DAIOCTA_EYE,
|
||||
/* Actor SubMtd */ &daDaiocta_EyeMethodTable,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "d/res/res_deku.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
#include "weak_data_1811.h" // IWYU pragma: keep
|
||||
|
||||
@@ -291,7 +292,7 @@ actor_process_profile_definition g_profile_DEKU_ITEM = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00FF,
|
||||
/* Priority */ PRIO_DEKU_ITEM,
|
||||
/* Actor SubMtd */ &daDekuItemMethodTable,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "d/d_kankyo.h"
|
||||
#include "d/d_kankyo_demo.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "m_Do/m_Do_graphic.h"
|
||||
@@ -234,7 +235,7 @@ actor_process_profile_definition g_profile_DEMO00 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x018D,
|
||||
/* Priority */ PRIO_DEMO00,
|
||||
/* Actor SubMtd */ &l_daDemo00_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_demo_dk.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000000E8 .text daDEMO_DK_Draw__FP13demo_dk_class */
|
||||
static BOOL daDEMO_DK_Draw(demo_dk_class*) {
|
||||
@@ -69,7 +70,7 @@ actor_process_profile_definition g_profile_DEMO_DK = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00BC,
|
||||
/* Priority */ PRIO_DEMO_DK,
|
||||
/* Actor SubMtd */ &l_daDEMO_DK_Method,
|
||||
/* Status */ fopAcStts_NOCULLEXEC_e | fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENV_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_demo_item.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_drawlist.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
@@ -285,7 +286,7 @@ void daDitem_c::setParticle() {
|
||||
if (mpEmitters[0] || mpEmitters[1] || mpEmitters[2] || mpEmitters[3]) {
|
||||
return;
|
||||
}
|
||||
if (chkArgFlag(0x02) || chkArgFlag(0x04) || chkArgFlag(0x08)) {
|
||||
if (chkArgFlag(FLAG_UNK02) || chkArgFlag(FLAG_UNK04) || chkArgFlag(FLAG_UNK08)) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -314,7 +315,7 @@ bool daDitem_c::CreateInit() {
|
||||
hide();
|
||||
clrFlag();
|
||||
mArgFlag = daDitem_prm::getFlag(this);
|
||||
if (!chkArgFlag(0x02) && !chkArgFlag(0x04) && !chkArgFlag(0x08)) {
|
||||
if (!chkArgFlag(FLAG_UNK02) && !chkArgFlag(FLAG_UNK04) && !chkArgFlag(FLAG_UNK08)) {
|
||||
current.angle.y = -0x2000;
|
||||
}
|
||||
for (int i = 0; i < ARRAY_SIZE(mpEmitters); i++) {
|
||||
@@ -351,17 +352,17 @@ void daDitem_c::set_pos() {
|
||||
|
||||
cXyz pos;
|
||||
cXyz offset;
|
||||
if (chkArgFlag(0x02)) {
|
||||
if (chkArgFlag(FLAG_UNK02)) {
|
||||
offset = offset_tbl[1];
|
||||
} else if (chkArgFlag(0x04)) {
|
||||
} else if (chkArgFlag(FLAG_UNK04)) {
|
||||
offset = offset_tbl[2];
|
||||
} else if (chkArgFlag(0x08)) {
|
||||
} else if (chkArgFlag(FLAG_UNK08)) {
|
||||
offset = mOffsetPos;
|
||||
} else {
|
||||
offset = offset_tbl[0];
|
||||
}
|
||||
|
||||
if (!chkArgFlag(0x08)) {
|
||||
if (!chkArgFlag(FLAG_UNK08)) {
|
||||
fopAc_ac_c* player = dComIfGp_getPlayer(0);
|
||||
mDoMtx_stack_c::ZXYrotS(player->current.angle.x, player->shape_angle.y, player->current.angle.z);
|
||||
mDoMtx_stack_c::multVec(&offset, &offset);
|
||||
@@ -410,7 +411,7 @@ void daDitem_c::set_mtx() {
|
||||
mpModel->setBaseScale(scale);
|
||||
fopAcM_addAngleY(this, current.angle.y + 0x0111, 0x0111);
|
||||
|
||||
if (chkArgFlag(0x02) || chkArgFlag(0x04) || chkArgFlag(0x08)) {
|
||||
if (chkArgFlag(FLAG_UNK02) || chkArgFlag(FLAG_UNK04) || chkArgFlag(FLAG_UNK08)) {
|
||||
mDoMtx_stack_c::transS(current.pos);
|
||||
mDoMtx_stack_c::YrotM(current.angle.y);
|
||||
} else {
|
||||
@@ -437,7 +438,7 @@ void daDitem_c::setListStart() {
|
||||
}
|
||||
|
||||
BOOL daDitem_c::Delete() {
|
||||
if (!chkArgFlag(0x01)) {
|
||||
if (!chkArgFlag(FLAG_UNK01)) {
|
||||
execItemGet(m_itemNo);
|
||||
}
|
||||
|
||||
@@ -549,7 +550,7 @@ actor_process_profile_definition g_profile_Demo_Item = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00FC,
|
||||
/* Priority */ PRIO_Demo_Item,
|
||||
/* Actor SubMtd */ &l_daDitem_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_demo_kmm.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000098 .text CheckCreateHeap__FP10fopAc_ac_c */
|
||||
static BOOL CheckCreateHeap(fopAc_ac_c*) {
|
||||
@@ -84,7 +85,7 @@ actor_process_profile_definition g_profile_DEMO_KMM = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00B8,
|
||||
/* Priority */ PRIO_DEMO_KMM,
|
||||
/* Actor SubMtd */ &l_daDemo_Kmm_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "f_op/f_op_actor.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_s_play.h"
|
||||
|
||||
@@ -132,7 +133,7 @@ actor_process_profile_definition g_profile_DISAPPEAR = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0188,
|
||||
/* Priority */ PRIO_DISAPPEAR,
|
||||
/* Actor SubMtd */ &l_daDisappear_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_dk.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000130 .text __ct__10daDk_HIO_cFv */
|
||||
daDk_HIO_c::daDk_HIO_c() {
|
||||
@@ -95,7 +96,7 @@ actor_process_profile_definition g_profile_DK = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E2,
|
||||
/* Priority */ PRIO_DK,
|
||||
/* Actor SubMtd */ &l_daDk_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_door10.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000000C8 .text chkMakeKey__10daDoor10_cFv */
|
||||
void daDoor10_c::chkMakeKey() {
|
||||
@@ -204,7 +205,7 @@ actor_process_profile_definition g_profile_DOOR10 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x012D,
|
||||
/* Priority */ PRIO_DOOR10,
|
||||
/* Actor SubMtd */ &l_daDoor10_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_door12.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000000C0 .text chkMakeKey__10daDoor12_cFv */
|
||||
void daDoor12_c::chkMakeKey() {
|
||||
@@ -214,7 +215,7 @@ actor_process_profile_definition g_profile_DOOR12 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x012E,
|
||||
/* Priority */ PRIO_DOOR12,
|
||||
/* Actor SubMtd */ &l_daDoor12_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
+10
-9
@@ -7,6 +7,7 @@
|
||||
#include "d/res/res_dr.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
#include "m_Do/m_Do_hostIO.h"
|
||||
@@ -58,29 +59,29 @@ static void anm_init(dr_class* i_this, int bckFileIdx, f32 morf, u8 loopMode, f3
|
||||
/* 00000320-0000091C .text move__FP8dr_class */
|
||||
static void move(dr_class* i_this) {
|
||||
bool isIdle = false;
|
||||
switch (i_this->mState) {
|
||||
switch (i_this->mMode) {
|
||||
case 0:
|
||||
isIdle = true;
|
||||
anm_init(i_this, DR_BCK_DR_WAIT1, l_HIO.mWait1Morf, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
i_this->mCountDownTimers[0] = (s16)(200.0f + cM_rndF(200.0f));
|
||||
break;
|
||||
case 1:
|
||||
isIdle = true;
|
||||
if (i_this->mCountDownTimers[0] == 0) {
|
||||
anm_init(i_this, DR_BCK_DR_AKUBI1, l_HIO.mAkubi1Morf, J3DFrameCtrl::EMode_NONE, 1.0f, DR_BAS_AKUBI1);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
isIdle = true;
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->mState = 0;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
break;
|
||||
case 10:
|
||||
anm_init(i_this, DR_BCK_DR_BIKU1, l_HIO.mBiku1Morf, J3DFrameCtrl::EMode_NONE, 1.0f, DR_BAS_BIKU1);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
i_this->mCountDownTimers[0] = l_HIO.m0E;
|
||||
i_this->mpBreathEmitter = dComIfGp_particle_set(dPa_name::ID_SCENE_81C4, &i_this->current.pos);
|
||||
i_this->m2C9 = 0;
|
||||
@@ -118,7 +119,7 @@ static void move(dr_class* i_this) {
|
||||
} else {
|
||||
anm_init(i_this, DR_BCK_DR_HO1, l_HIO.mHo1Morf, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->mpBreathEmitter = dComIfGp_particle_set(dPa_name::ID_SCENE_81C6, &i_this->current.pos);
|
||||
i_this->mState++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -138,7 +139,7 @@ static void move(dr_class* i_this) {
|
||||
}
|
||||
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->mState = 0;
|
||||
i_this->mMode = 0;
|
||||
if (i_this->mpBreathEmitter) {
|
||||
i_this->mpBreathEmitter->becomeInvalidEmitter();
|
||||
i_this->mpBreathEmitter = NULL;
|
||||
@@ -151,7 +152,7 @@ static void move(dr_class* i_this) {
|
||||
if ((isIdle && (l_HIO.m0C || dComIfGp_getVibration().CheckQuake())) || i_this->m2C8 != 0) {
|
||||
l_HIO.m0C = false;
|
||||
i_this->m2C8 = 0;
|
||||
i_this->mState = 10;
|
||||
i_this->mMode = 10;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -271,7 +272,7 @@ actor_process_profile_definition g_profile_DR = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00D2,
|
||||
/* Priority */ PRIO_DR,
|
||||
/* Actor SubMtd */ &l_daDr_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "d/actor/d_a_dr2.h"
|
||||
#include "m_Do/m_Do_ext.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 000000EC-00000110 .text __ct__11daDr2_HIO_cFv */
|
||||
daDr2_HIO_c::daDr2_HIO_c() {
|
||||
@@ -115,7 +116,7 @@ actor_process_profile_definition g_profile_DR2 = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00D3,
|
||||
/* Priority */ PRIO_DR2,
|
||||
/* Actor SubMtd */ &l_daDr2_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_dummy.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
|
||||
@@ -94,7 +95,7 @@ actor_process_profile_definition g_profile_Dummy = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0060,
|
||||
/* Priority */ PRIO_Dummy,
|
||||
/* Actor SubMtd */ &daDummy::Mthd_Table,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_ep.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000158 .text ga_draw__FP8ep_class */
|
||||
void ga_draw(ep_class*) {
|
||||
@@ -99,7 +100,7 @@ actor_process_profile_definition g_profile_EP = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00AD,
|
||||
/* Priority */ PRIO_EP,
|
||||
/* Actor SubMtd */ &l_daEp_Method,
|
||||
/* Status */ fopAcStts_UNK4000_e | fopAcStts_UNK40000_e | fopAcStts_UNK200000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include "d/d_s_play.h"
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "d/d_bg_s_func.h"
|
||||
#include "d/res/res_link.h"
|
||||
#include "f_op/f_op_actor_mng.h"
|
||||
@@ -51,7 +52,7 @@ void bg_check(esa_class* i_this) {
|
||||
cXyz sp54 = i_this->current.pos;
|
||||
sp54.y += 100.0f;
|
||||
f32 waterHeight = dBgS_GetWaterHeight(sp54);
|
||||
if(waterHeight != C_BG_MIN_HEIGHT && i_this->mGroundHeight <= waterHeight) {
|
||||
if(waterHeight != -G_CM3D_F_INF && i_this->mGroundHeight <= waterHeight) {
|
||||
i_this->mGroundHeight = waterHeight;
|
||||
state = 2;
|
||||
}
|
||||
@@ -300,7 +301,7 @@ actor_process_profile_definition g_profile_ESA = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00D0,
|
||||
/* Priority */ PRIO_ESA,
|
||||
/* Actor SubMtd */ &l_daEsa_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_fallrock.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000098 .text CheckCreateHeap__FP10fopAc_ac_c */
|
||||
static BOOL CheckCreateHeap(fopAc_ac_c*) {
|
||||
@@ -79,7 +80,7 @@ actor_process_profile_definition g_profile_FallRock = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x0190,
|
||||
/* Priority */ PRIO_FallRock,
|
||||
/* Actor SubMtd */ &l_daFallRock_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_fallrock_tag.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-00000080 .text daFallRockTag_Draw__FP15daFallRockTag_c */
|
||||
static BOOL daFallRockTag_Draw(daFallRockTag_c*) {
|
||||
@@ -59,7 +60,7 @@ actor_process_profile_definition g_profile_TagRock = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x018F,
|
||||
/* Priority */ PRIO_TagRock,
|
||||
/* Actor SubMtd */ &l_daFallRockTag_Method,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include "d/d_com_inf_game.h"
|
||||
#include "d/d_level_se.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "m_Do/m_Do_mtx.h"
|
||||
#include "JSystem/JUtility/JUTAssert.h"
|
||||
|
||||
@@ -303,7 +304,7 @@ actor_process_profile_definition g_profile_FAN = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x011B,
|
||||
/* Priority */ PRIO_FAN,
|
||||
/* Actor SubMtd */ &daFanMethodTable,
|
||||
/* Status */ fopAcStts_CULL_e | fopAcStts_UNK4000_e | fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_ff.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000001E4 .text fire_fly_draw__FP8ff_class */
|
||||
void fire_fly_draw(ff_class*) {
|
||||
@@ -69,7 +70,7 @@ actor_process_profile_definition g_profile_FF = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00EE,
|
||||
/* Priority */ PRIO_FF,
|
||||
/* Actor SubMtd */ &l_daFf_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ACTOR_e,
|
||||
|
||||
+155
-154
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_fganon.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
#include "JSystem/JUtility/JUTReport.h"
|
||||
#include "d/actor/d_a_boko.h"
|
||||
#include "d/actor/d_a_mant.h"
|
||||
@@ -185,23 +186,23 @@ void fly(fganon_class* i_this) {
|
||||
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
|
||||
dBgS_LinChk linChk;
|
||||
|
||||
if ((((i_this->m384 & 0xF) == 0) && (cM_rndF(1.0f) < 0.5f)) || (i_this->m388 == -10)) {
|
||||
if ((((i_this->m384 & 0xF) == 0) && (cM_rndF(1.0f) < 0.5f)) || (i_this->mMode == -10)) {
|
||||
i_this->m398 = player->shape_angle.y;
|
||||
}
|
||||
|
||||
switch (i_this->m388) {
|
||||
switch (i_this->mMode) {
|
||||
case -10:
|
||||
deru_brk(i_this);
|
||||
i_this->current.pos = i_this->home.pos;
|
||||
i_this->current.pos.y = player->current.pos.y + l_HIO.m10;
|
||||
i_this->shape_angle.y = fopAcM_searchPlayerAngleY(a_this);
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 20.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m3A4[1] = 60;
|
||||
break;
|
||||
case 0:
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 20.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
i_this->m3A0 = 0.0f;
|
||||
i_this->m3A4[1] = (short)(cM_rndF(50.0f) + 50.0f);
|
||||
// Fall-through
|
||||
@@ -235,24 +236,24 @@ void fly(fganon_class* i_this) {
|
||||
fly_se_set(i_this);
|
||||
|
||||
if (i_this->m3A4[1] == 0) {
|
||||
i_this->m386 = 6;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 6;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
|
||||
if (i_this->m3A4[2] == 0) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
}
|
||||
|
||||
/* 000015A8-00001BD0 .text shot__FP12fganon_class */
|
||||
void shot(fganon_class* i_this) {
|
||||
cLib_addCalcAngleS2(&i_this->shape_angle.y, fopAcM_searchPlayerAngleY(i_this), 10, 0x400);
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
if (!i_this->m408) {
|
||||
anm_init(i_this, FGANON_BCK_TAME1, 10.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
i_this->m3A4[0] = 40;
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_EBALL_MAKE_S, 0);
|
||||
// Fall-through
|
||||
@@ -269,7 +270,7 @@ void shot(fganon_class* i_this) {
|
||||
}
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
anm_init(i_this, FGANON_BCK_NAGERU1, 3.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_EBALL_FIRE_S, 0);
|
||||
mDoAud_seStart(JA_SE_CM_PG_EBALL_FIRE_S, &i_this->eyePos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
}
|
||||
@@ -285,7 +286,7 @@ void shot(fganon_class* i_this) {
|
||||
}
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 3.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
// Fall-through
|
||||
}
|
||||
@@ -300,7 +301,7 @@ void shot(fganon_class* i_this) {
|
||||
else {
|
||||
anm_init(i_this, FGANON_BCK_TENNISRL1, 0.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
}
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_REFLECT_EBALL, 0);
|
||||
mDoAud_seStart(JA_SE_CM_PG_SWING_S, &i_this->eyePos, 0, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
i_this->m687++;
|
||||
@@ -309,8 +310,8 @@ void shot(fganon_class* i_this) {
|
||||
}
|
||||
}
|
||||
else if (i_this->m2BC == 2) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -324,7 +325,7 @@ void shot(fganon_class* i_this) {
|
||||
if (i_this->mpMorf->isStop() || ((i_this->m2BC >= 1) && (i_this->mpMorf->getFrame() >= 20.0f)))
|
||||
{
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 10.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
}
|
||||
// Fall-through
|
||||
}
|
||||
@@ -332,11 +333,11 @@ void shot(fganon_class* i_this) {
|
||||
cLib_addCalc0(&i_this->speedF, 1.0f, REG0_F(14) + 1.0f);
|
||||
pos_move(i_this, 0);
|
||||
fly_se_set(i_this);
|
||||
if ((i_this->m388 >= 2) && (i_this->m408 == 0)) {
|
||||
i_this->m386 = 5;
|
||||
i_this->m388 = 0;
|
||||
if ((i_this->mMode >= 2) && (i_this->m408 == 0)) {
|
||||
i_this->mAction = 5;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
if ((i_this->m388 == 3) || (i_this->m388 == 4)) {
|
||||
if ((i_this->mMode == 3) || (i_this->mMode == 4)) {
|
||||
mDoAud_monsSeStart(JA_SE_OBJ_PG_EBALL_FLY_S, &i_this->m3E0, 100, dComIfGp_getReverb(fopAcM_GetRoomNo(i_this)));
|
||||
}
|
||||
}
|
||||
@@ -347,10 +348,10 @@ void spinattack(fganon_class* i_this) {
|
||||
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
|
||||
dBgS_LinChk linChk;
|
||||
int mFrame = i_this->mpMorf->mFrameCtrl.getFrame();
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
i_this->shape_angle.y = player->shape_angle.y;
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
// Fall-through
|
||||
}
|
||||
case 1: {
|
||||
@@ -363,7 +364,7 @@ void spinattack(fganon_class* i_this) {
|
||||
if (!dComIfG_Bgsp()->LineCross(&linChk)) {
|
||||
i_this->current.pos.y -= 100.0f;
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388 = 2;
|
||||
i_this->mMode = 2;
|
||||
i_this->m3A4[0] = 30;
|
||||
deru_brk(i_this);
|
||||
// Fall-through
|
||||
@@ -376,7 +377,7 @@ void spinattack(fganon_class* i_this) {
|
||||
case 2: {
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
anm_init(i_this, FGANON_BCK_KAITEN1, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
i_this->speedF = 0.0f;
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_EBALL_FIRE_S, 0);
|
||||
}
|
||||
@@ -406,8 +407,8 @@ void spinattack(fganon_class* i_this) {
|
||||
i_this->current.angle.x = 0;
|
||||
pos_move(i_this, 1);
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -420,22 +421,22 @@ void fly2(fganon_class* i_this) {
|
||||
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
|
||||
dBgS_LinChk linChk;
|
||||
|
||||
if ((((i_this->m384 & 0xF) == 0) && (cM_rndF(1.0f) < 0.5f)) || (i_this->m388 == -10)) {
|
||||
if ((((i_this->m384 & 0xF) == 0) && (cM_rndF(1.0f) < 0.5f)) || (i_this->mMode == -10)) {
|
||||
i_this->m398 = player->shape_angle.y;
|
||||
}
|
||||
switch (i_this->m388) {
|
||||
switch (i_this->mMode) {
|
||||
case -10:
|
||||
deru_brk(i_this);
|
||||
i_this->current.pos = i_this->home.pos;
|
||||
i_this->current.pos.y = player->current.pos.y + l_HIO.m18;
|
||||
i_this->shape_angle.y = fopAcM_searchPlayerAngleY(a_this);
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 20.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m3A4[1] = 40;
|
||||
break;
|
||||
case 0:
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 20.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
i_this->m3A0 = 0.0f;
|
||||
i_this->m3A4[1] = (short)(cM_rndF(50.0f) + 50.0f);
|
||||
// Fall-through
|
||||
@@ -469,13 +470,13 @@ void fly2(fganon_class* i_this) {
|
||||
fly_se_set(i_this);
|
||||
|
||||
if (i_this->m3A4[1] == 0) {
|
||||
i_this->m386 = 11;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 11;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
|
||||
if (i_this->m3A4[2] == 0) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -568,7 +569,7 @@ void mahou_set(fganon_class* i_this) {
|
||||
void shot2(fganon_class* i_this) {
|
||||
cLib_addCalcAngleS2(&i_this->shape_angle.y, fopAcM_searchPlayerAngleY(i_this), 10, 0x400);
|
||||
int mFrame = i_this->mpMorf->mFrameCtrl.getFrame();
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
anm_init(i_this, FGANON_BCK_TAME_S1, 5.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
for (int i = 0; i < 2; i++) {
|
||||
@@ -580,7 +581,7 @@ void shot2(fganon_class* i_this) {
|
||||
i_this->mEmitters2[0] = dComIfGp_particle_set(dPa_name::ID_SCENE_8218, &i_this->current.pos, NULL);
|
||||
i_this->mEmitters2[1] = dComIfGp_particle_set(dPa_name::ID_SCENE_8219, &i_this->current.pos, NULL);
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_EBALL_MAKE_L, 0);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
// Fall-through
|
||||
}
|
||||
case 1: {
|
||||
@@ -593,7 +594,7 @@ void shot2(fganon_class* i_this) {
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
anm_init(i_this, FGANON_BCK_TAME_S2, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m3A4[0] = l_HIO.m3C;
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
for (int i = 0; i < 2; i++) {
|
||||
if (i_this->mEmitters2[i] != NULL) {
|
||||
i_this->mEmitters2[i]->becomeInvalidEmitter();
|
||||
@@ -611,7 +612,7 @@ void shot2(fganon_class* i_this) {
|
||||
fopAcM_seStart(i_this, JA_SE_CM_PG_EBALL_MAKING_L, 0);
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
anm_init(i_this, FGANON_BCK_NAGERU_S1, 3.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
i_this->mEmitters2[0] = dComIfGp_particle_set(dPa_name::ID_SCENE_821C, &i_this->current.pos, NULL);
|
||||
i_this->mEmitters2[1] = dComIfGp_particle_set(dPa_name::ID_SCENE_821D, &i_this->current.pos, NULL);
|
||||
}
|
||||
@@ -642,7 +643,7 @@ void shot2(fganon_class* i_this) {
|
||||
}
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->m3A4[0] = 60;
|
||||
i_this->m388 = 4;
|
||||
i_this->mMode = 4;
|
||||
for (int i = 0; i < 2; i++) {
|
||||
if (i_this->mEmitters2[i] != NULL) {
|
||||
i_this->mEmitters2[i]->becomeInvalidEmitter();
|
||||
@@ -657,8 +658,8 @@ void shot2(fganon_class* i_this) {
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 10.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
}
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
i_this->m386 = 9;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 9;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -678,10 +679,10 @@ void spinattack2(fganon_class* i_this) {
|
||||
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
|
||||
dBgS_LinChk linChk;
|
||||
int mFrame = i_this->mpMorf->mFrameCtrl.getFrame();
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
i_this->shape_angle.y = player->shape_angle.y + i_this->m68F * 0x3333;
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
if (i_this->m68F == 0) {
|
||||
for (int i = 1; i < 5; i++) {
|
||||
fopAcM_create(PROC_FGANON, (i * 16) | 3, &i_this->current.pos, i_this->current.roomNo);
|
||||
@@ -698,7 +699,7 @@ void spinattack2(fganon_class* i_this) {
|
||||
MtxPosition(&offset, &transformedPos);
|
||||
i_this->current.pos = player->current.pos + transformedPos;
|
||||
anm_init(i_this, 10, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m388 = 2;
|
||||
i_this->mMode = 2;
|
||||
deru_brk(i_this);
|
||||
i_this->m38C = player->current.pos;
|
||||
}
|
||||
@@ -711,7 +712,7 @@ void spinattack2(fganon_class* i_this) {
|
||||
local_e4 = i_this->m38C - i_this->current.pos;
|
||||
if (local_e4.abs() < l_HIO.m38) {
|
||||
anm_init(i_this, 9, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
i_this->speedF = 0.0f;
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_EBALL_FIRE_S, 0);
|
||||
break;
|
||||
@@ -731,21 +732,21 @@ void spinattack2(fganon_class* i_this) {
|
||||
}
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
if (i_this->m68F == 0) {
|
||||
i_this->m388 = 4;
|
||||
i_this->mMode = 4;
|
||||
i_this->m3A4[0] = 40;
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 10.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
}
|
||||
else {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 4: {
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -756,17 +757,17 @@ void spinattack2(fganon_class* i_this) {
|
||||
|
||||
/* 00003690-00003B3C .text down__FP12fganon_class */
|
||||
void down(fganon_class* i_this) {
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
anm_init(i_this, 6, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
i_this->speed.y = 0.0f;
|
||||
}
|
||||
case 1: {
|
||||
i_this->m3AE = 5;
|
||||
if (i_this->mAcch.ChkGroundHit()) {
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
anm_init(i_this, FGANON_BCK_TYAKUTI1, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
}
|
||||
}
|
||||
@@ -775,7 +776,7 @@ void down(fganon_class* i_this) {
|
||||
}
|
||||
case 2: {
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
anm_init(i_this, 8, 2.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
}
|
||||
break;
|
||||
@@ -789,7 +790,7 @@ void down(fganon_class* i_this) {
|
||||
}
|
||||
case 10: {
|
||||
anm_init(i_this, 7, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388 = 2;
|
||||
i_this->mMode = 2;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
@@ -807,12 +808,12 @@ void down(fganon_class* i_this) {
|
||||
sp2C.y += 300.0f;
|
||||
gndChk.SetPos(&sp2C);
|
||||
f32 height = dComIfG_Bgsp()->GroundCross(&gndChk);
|
||||
if (height != C_BG_MIN_HEIGHT && i_this->current.pos.y <= height) {
|
||||
if (height != -G_CM3D_F_INF && i_this->current.pos.y <= height) {
|
||||
bVar3 = TRUE;
|
||||
}
|
||||
if ((i_this->m3A4[0] == 0) || bVar3) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
if (i_this->m2BC != 0) {
|
||||
i_this->health = 100;
|
||||
}
|
||||
@@ -844,54 +845,54 @@ BOOL kabe_check(fganon_class* i_this) {
|
||||
/* 00004300-000044CC .text deru__FP12fganon_class */
|
||||
void deru(fganon_class* i_this) {
|
||||
i_this->m3AE = 3;
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0:
|
||||
if(l_HIO.m06 != 0) {
|
||||
if (l_HIO.m06 == 1) {
|
||||
i_this->m386 = 5;
|
||||
i_this->m388 = -10;
|
||||
i_this->mAction = 5;
|
||||
i_this->mMode = -10;
|
||||
i_this->m3A4[2] = l_HIO.m0A;
|
||||
}
|
||||
else if (l_HIO.m06 == 2) {
|
||||
i_this->m386 = 7;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 7;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
else if (l_HIO.m06 == 3) {
|
||||
i_this->m386 = 9;
|
||||
i_this->m388 = -10;
|
||||
i_this->mAction = 9;
|
||||
i_this->mMode = -10;
|
||||
i_this->m3A4[2] = l_HIO.m0A;
|
||||
}
|
||||
else if (l_HIO.m06 == 4) {
|
||||
i_this->m386 = 10;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 10;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (i_this->m2BC == 0) {
|
||||
if (cM_rndF(1.0f) < 0.5f) {
|
||||
i_this->m386 = 5;
|
||||
i_this->m388 = -10;
|
||||
i_this->mAction = 5;
|
||||
i_this->mMode = -10;
|
||||
i_this->m3A4[2] = l_HIO.m0A;
|
||||
}
|
||||
else {
|
||||
i_this->m386 = 7;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 7;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
}
|
||||
else {
|
||||
if ((cM_rndF(1.0f) < 0.4f) && !kabe_check(i_this)) {
|
||||
i_this->m386 = 10;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 10;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
else {
|
||||
if (cM_rndF(1.0f) < 0.5f) {
|
||||
i_this->m386 = 9;
|
||||
i_this->m388 = -10;
|
||||
i_this->mAction = 9;
|
||||
i_this->mMode = -10;
|
||||
i_this->m3A4[2] = l_HIO.m0A;
|
||||
}
|
||||
else {
|
||||
i_this->m386 = 5;
|
||||
i_this->m388 = -10;
|
||||
i_this->mAction = 5;
|
||||
i_this->mMode = -10;
|
||||
i_this->m3A4[2] = l_HIO.m0A;
|
||||
}
|
||||
}
|
||||
@@ -904,19 +905,19 @@ void deru(fganon_class* i_this) {
|
||||
/* 000044CC-00004584 .text kieru__FP12fganon_class */
|
||||
void kieru(fganon_class* i_this) {
|
||||
i_this->m3AE = 3;
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
if ((i_this->m408 == 1) || (i_this->m408 == 2)) {
|
||||
i_this->m408 = 35;
|
||||
}
|
||||
kieru_brk(i_this, 0);
|
||||
if (i_this->m68F != 0) {
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
i_this->m3A4[0] = 30;
|
||||
}
|
||||
else {
|
||||
i_this->m386 = 0;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 0;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -934,16 +935,16 @@ void fail(fganon_class* i_this) {
|
||||
fopAc_ac_c* a_this = (fopAc_ac_c*)i_this;
|
||||
|
||||
i_this->m3AE = 3;
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
kieru_brk(i_this, 1);
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
anm_init(i_this, 7, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
break;
|
||||
}
|
||||
case 1: {
|
||||
if (i_this->mpMorf->isStop()) {
|
||||
i_this->m388 = 2;
|
||||
i_this->mMode = 2;
|
||||
i_this->m3A4[0] = 30;
|
||||
|
||||
dBgS_LinChk linChk;
|
||||
@@ -1013,7 +1014,7 @@ void fail(fganon_class* i_this) {
|
||||
else {
|
||||
i_this->m698 = 0.0f;
|
||||
i_this->m3A4[0] = 0;
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1023,7 +1024,7 @@ void fail(fganon_class* i_this) {
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
kieru_brk(i_this, 2);
|
||||
i_this->m3A4[0] = 10;
|
||||
i_this->m388 = 4;
|
||||
i_this->mMode = 4;
|
||||
i_this->mBokoID = fopAcM_create(PROC_BOKO, 5, &i_this->current.pos, i_this->current.roomNo);
|
||||
}
|
||||
break;
|
||||
@@ -1052,7 +1053,7 @@ void fail(fganon_class* i_this) {
|
||||
void standby(fganon_class* i_this) {
|
||||
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
|
||||
i_this->m3AE = 3;
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case -1: {
|
||||
if (i_this->m2BC == 2) {
|
||||
if (!dComIfGs_checkGetItem(dItem_LIGHT_ARROW_e)) {
|
||||
@@ -1069,7 +1070,7 @@ void standby(fganon_class* i_this) {
|
||||
float distXZ = std::sqrtf(xOffset * xOffset + zOffset * zOffset);
|
||||
if (distXZ < i_this->m2BD * 10.0f) {
|
||||
i_this->m3A4[0] = l_HIO.m08;
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
fopAcM_OnStatus(i_this, fopAcStts_SHOWMAP_e);
|
||||
i_this->mB89 = 22;
|
||||
}
|
||||
@@ -1077,13 +1078,13 @@ void standby(fganon_class* i_this) {
|
||||
}
|
||||
case 0: {
|
||||
i_this->m3A4[0] = l_HIO.m08;
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
// fallthrough
|
||||
}
|
||||
case 1: {
|
||||
if (i_this->m3A4[0] == 0) {
|
||||
i_this->m386 = 1;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 1;
|
||||
i_this->mMode = 0;
|
||||
i_this->m69C = 0.0f;
|
||||
i_this->m698 = 0.0f;
|
||||
i_this->m694 = 0.0f;
|
||||
@@ -1101,13 +1102,13 @@ void start(fganon_class* i_this) {
|
||||
i_this->m3AE = 3;
|
||||
fopAcM_OffStatus(i_this, 0);
|
||||
i_this->attention_info.flags = 0;
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
offset = player->current.pos - i_this->home.pos;
|
||||
float distXZ = std::sqrtf(offset.x * offset.x + offset.z * offset.z);
|
||||
if (distXZ < i_this->m2BD * 10.0f) {
|
||||
i_this->mB54 = 1;
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
anm_init(i_this, FGANON_BCK_WAIT1, 0.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
mDoAud_bgmAllMute(30);
|
||||
}
|
||||
@@ -1120,11 +1121,11 @@ void start(fganon_class* i_this) {
|
||||
case 2: {
|
||||
anm_init(i_this, FGANON_BCK_WARAU1, 5.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_LAUGH_2, 0);
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
break;
|
||||
}
|
||||
case 4: {
|
||||
i_this->m388 = 5;
|
||||
i_this->mMode = 5;
|
||||
i_this->m3A4[0] = REG0_S(0) + 0x50;
|
||||
anm_init(i_this, FGANON_BCK_TAME1, 10.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
}
|
||||
@@ -1162,9 +1163,9 @@ void end(fganon_class* i_this) {
|
||||
fopAcM_OffStatus(i_this, 0);
|
||||
i_this->attention_info.flags = 0;
|
||||
s32 mFrame = i_this->mpMorf->mFrameCtrl.getFrame();
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
anm_init(i_this, FGANON_BCK_LAST_DAMAGE1, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->mB54 = 50;
|
||||
dComIfGs_onEventBit(0x3f20); // PG_DEFEATED? It appears further down in `energy_ball_move`
|
||||
@@ -1179,13 +1180,13 @@ void end(fganon_class* i_this) {
|
||||
deru_brk(i_this);
|
||||
anm_init(i_this, FGANON_BCK_WARAU1, 1.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
fopAcM_monsSeStart(i_this, JA_SE_CV_PG_LAUGH_2, 0);
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
break;
|
||||
}
|
||||
case 4: {
|
||||
deru_brk(i_this);
|
||||
anm_init(i_this, FGANON_BCK_SARU1, 1.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->m388 = 5;
|
||||
i_this->mMode = 5;
|
||||
i_this->speed.y = 0.0f;
|
||||
fopAcM_seStart(i_this, JA_SE_CM_PG_END_1, 0);
|
||||
}
|
||||
@@ -1199,7 +1200,7 @@ void end(fganon_class* i_this) {
|
||||
kieru_brk2(i_this);
|
||||
}
|
||||
if (mFrame == 48) {
|
||||
i_this->m388 = 6;
|
||||
i_this->mMode = 6;
|
||||
}
|
||||
}
|
||||
case 6:
|
||||
@@ -1214,9 +1215,9 @@ void last_end(fganon_class* i_this) {
|
||||
i_this->m3AE = 3;
|
||||
fopAcM_OffStatus(i_this, 0);
|
||||
i_this->attention_info.flags = 0;
|
||||
switch(i_this->m388) {
|
||||
switch(i_this->mMode) {
|
||||
case 0: {
|
||||
i_this->m388 = 1;
|
||||
i_this->mMode = 1;
|
||||
anm_init(i_this, FGANON_BCK_MOGAKU1, 2.0f, J3DFrameCtrl::EMode_NONE, 1.0f, -1);
|
||||
i_this->mB54 = 100;
|
||||
i_this->m3C0 = 10000.0f;
|
||||
@@ -1225,7 +1226,7 @@ void last_end(fganon_class* i_this) {
|
||||
}
|
||||
case 1: {
|
||||
if (i_this->m3A4[1] == 0) {
|
||||
i_this->m388 = 2;
|
||||
i_this->mMode = 2;
|
||||
i_this->m3A4[1] = 20;
|
||||
i_this->m2D0 = 1;
|
||||
i_this->mB54++;
|
||||
@@ -1237,7 +1238,7 @@ void last_end(fganon_class* i_this) {
|
||||
cLib_addCalc2(&i_this->scale.z, 0.1f, 1.0f, 0.05f);
|
||||
cLib_addCalc2(&i_this->scale.y, 0.1f, 1.0f, 0.05f);
|
||||
if (i_this->m3A4[1] == 0) {
|
||||
i_this->m388 = 3;
|
||||
i_this->mMode = 3;
|
||||
i_this->m3A4[1] = 30;
|
||||
fopAcM_seStart(i_this, JA_SE_CM_L_ARROW_PASS_AWAY, 0);
|
||||
}
|
||||
@@ -1251,7 +1252,7 @@ void last_end(fganon_class* i_this) {
|
||||
i_this->scale.x = 0.0f;
|
||||
i_this->scale.y = 0.0f;
|
||||
i_this->scale.z = 0.0f;
|
||||
i_this->m388 = 4;
|
||||
i_this->mMode = 4;
|
||||
i_this->m3A4[1] = 30;
|
||||
}
|
||||
break;
|
||||
@@ -1270,7 +1271,7 @@ void last_end(fganon_class* i_this) {
|
||||
mBoko->setMatrix(i_this->mpKenModel->getBaseTRMtx());
|
||||
if (i_this->m3A4[1] == 1) {
|
||||
fopAcM_cancelCarryNow(mBoko);
|
||||
i_this->m388 = 5;
|
||||
i_this->mMode = 5;
|
||||
i_this->mB54++;
|
||||
i_this->mB56 = 0;
|
||||
}
|
||||
@@ -1340,8 +1341,8 @@ void damage_check(fganon_class* i_this) {
|
||||
dComIfGp_particle_set(dPa_name::ID_COMMON_NORMAL_HIT, &i_this->eyePos, &local_a0, &local_44);
|
||||
dKy_SordFlush_set(i_this->eyePos, 1);
|
||||
|
||||
i_this->m386 = 22;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 22;
|
||||
i_this->mMode = 0;
|
||||
i_this->m3AE = 1000;
|
||||
|
||||
mDoAud_subBgmStop();
|
||||
@@ -1364,8 +1365,8 @@ void damage_check(fganon_class* i_this) {
|
||||
i_this->speedF = 0.0f;
|
||||
}
|
||||
else {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
if ((i_this->m408 == 1) || (i_this->m408 == 2)) {
|
||||
i_this->m408 = 35;
|
||||
}
|
||||
@@ -1408,8 +1409,8 @@ void damage_check(fganon_class* i_this) {
|
||||
dComIfGp_particle_set(dPa_name::ID_COMMON_NORMAL_HIT, &i_this->eyePos, &local_a0, &local_44);
|
||||
dKy_SordFlush_set(i_this->eyePos, 1);
|
||||
|
||||
i_this->m386 = 8;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 8;
|
||||
i_this->mMode = 0;
|
||||
i_this->m3B0 = REG8_F(11) + 80.0f;
|
||||
i_this->m3B8 = REG8_S(2) + 7;
|
||||
|
||||
@@ -1426,7 +1427,7 @@ void damage_check(fganon_class* i_this) {
|
||||
}
|
||||
}
|
||||
if (i_this->m68F) {
|
||||
if ((i_this->mCyl.ChkTgHit()) || (master->m386 == 8)) {
|
||||
if ((i_this->mCyl.ChkTgHit()) || (master->mAction == 8)) {
|
||||
mEmitter = dComIfGp_particle_set(dPa_name::ID_SCENE_826B, &i_this->current.pos, NULL);
|
||||
if (mEmitter != NULL) {
|
||||
mEmitter->setGlobalRTMatrix(i_this->mpMorf->getModel()->getAnmMtx(0));
|
||||
@@ -1438,7 +1439,7 @@ void damage_check(fganon_class* i_this) {
|
||||
if ((i_this->mCyl.ChkTgHit()) || (i_this->m68C)) {
|
||||
i_this->m3AE = 6;
|
||||
if (i_this->mCyl.ChkTgHit()) {
|
||||
if(((i_this->m386 == 8) || (i_this->m386 == 7)) || (i_this->m386 == 10)) {
|
||||
if(((i_this->mAction == 8) || (i_this->mAction == 7)) || (i_this->mAction == 10)) {
|
||||
atInfo.mpObj = i_this->mCyl.GetTgHitObj();
|
||||
pPos = i_this->mCyl.GetTgHitPosP();
|
||||
atInfo.pParticlePos = pPos;
|
||||
@@ -1472,14 +1473,14 @@ void damage_check(fganon_class* i_this) {
|
||||
|
||||
dComIfGp_particle_set(dPa_name::ID_COMMON_NORMAL_HIT, pPos, &local_a0, &local_44);
|
||||
|
||||
if ((i_this->m386 == 7) || (i_this->m386 == 10)) {
|
||||
i_this->m386 = 8;
|
||||
i_this->m388 = 0;
|
||||
if ((i_this->mAction == 7) || (i_this->mAction == 10)) {
|
||||
i_this->mAction = 8;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
else if (i_this->m2BC == 0) {
|
||||
if (i_this->health <= 0) {
|
||||
i_this->m386 = 21;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 21;
|
||||
i_this->mMode = 0;
|
||||
i_this->m3AE = 1000;
|
||||
mDoAud_subBgmStop();
|
||||
}
|
||||
@@ -1487,17 +1488,17 @@ void damage_check(fganon_class* i_this) {
|
||||
i_this->m690 -= atInfo.mDamage;
|
||||
if (i_this->m690 <= 0) {
|
||||
i_this->m690 = 10;
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
else {
|
||||
i_this->m388 = 10;
|
||||
i_this->mMode = 10;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (i_this->m2BC == 1) {
|
||||
i_this->m386 = 3;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 3;
|
||||
i_this->mMode = 0;
|
||||
i_this->health = 0;
|
||||
mDoAud_subBgmStop();
|
||||
}
|
||||
@@ -1519,8 +1520,8 @@ void damage_check(fganon_class* i_this) {
|
||||
dComIfGp_particle_set(dPa_name::ID_COMMON_NORMAL_HIT, &i_this->eyePos, &local_a0, &local_44);
|
||||
dKy_SordFlush_set(i_this->eyePos, 1);
|
||||
|
||||
i_this->m386 = 8;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 8;
|
||||
i_this->mMode = 0;
|
||||
i_this->m3B0 = REG8_F(11) + 80.0f;
|
||||
i_this->m3B8 = REG8_S(2) + 7;
|
||||
|
||||
@@ -1537,8 +1538,8 @@ void damage_check(fganon_class* i_this) {
|
||||
/* 00006288-00006560 .text move__FP12fganon_class */
|
||||
s32 move(fganon_class* i_this) {
|
||||
int res = 0;
|
||||
if (!dComIfGp_checkPlayerStatus0(0, daPyStts0_SHIP_RIDE_e) && !dComIfGp_checkPlayerStatus0(0, daPyStts0_SWIM_e) && i_this->m386) {
|
||||
if (i_this->m386 == 10) {
|
||||
if (!dComIfGp_checkPlayerStatus0(0, daPyStts0_SHIP_RIDE_e) && !dComIfGp_checkPlayerStatus0(0, daPyStts0_SWIM_e) && i_this->mAction) {
|
||||
if (i_this->mAction == 10) {
|
||||
dCam_getBody()->SetTypeForce("P_Ganon3", NULL);
|
||||
}
|
||||
else if (i_this->m2BC != 1) {
|
||||
@@ -1548,17 +1549,17 @@ s32 move(fganon_class* i_this) {
|
||||
dCam_getBody()->SetTypeForce("P_Ganon2", NULL);
|
||||
}
|
||||
}
|
||||
if ((i_this->m2BC == 0) && (i_this->m386 < 20)) {
|
||||
if ((i_this->m2BC == 0) && (i_this->mAction < 20)) {
|
||||
fopAc_ac_c* player = (fopAc_ac_c*)dComIfGp_getPlayer(0);
|
||||
if ((i_this->m386 == 0) && (player->current.pos.y < 710.0f)) {
|
||||
if ((i_this->mAction == 0) && (player->current.pos.y < 710.0f)) {
|
||||
return 0;
|
||||
}
|
||||
if ((i_this->m386 != 2) && (player->current.pos.y < 710.0f)) {
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
if ((i_this->mAction != 2) && (player->current.pos.y < 710.0f)) {
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
}
|
||||
}
|
||||
switch(i_this->m386) {
|
||||
switch(i_this->mAction) {
|
||||
case 0:
|
||||
standby(i_this);
|
||||
break;
|
||||
@@ -1734,14 +1735,14 @@ void demo_camera(fganon_class* i_this) {
|
||||
cLib_addCalc2(&i_this->mB80, 0.1f, 1.0f, REG8_F(7) + 0.01f);
|
||||
}
|
||||
if (i_this->mB56 == 110) {
|
||||
i_this->m388 = 2;
|
||||
i_this->mMode = 2;
|
||||
}
|
||||
if (i_this->mB56 == 180) {
|
||||
i_this->m388 = 4;
|
||||
i_this->mMode = 4;
|
||||
}
|
||||
if (i_this->mB56 == 280) {
|
||||
i_this->m386 = 6;
|
||||
i_this->m388 = 1;
|
||||
i_this->mAction = 6;
|
||||
i_this->mMode = 1;
|
||||
i_this->m3A4[0] = 29;
|
||||
i_this->mB54 = 150;
|
||||
if (i_this->m2BF != 0xFF) {
|
||||
@@ -1822,7 +1823,7 @@ void demo_camera(fganon_class* i_this) {
|
||||
player->setPlayerPosAndAngle(&transformedPos, 0.0f);
|
||||
|
||||
if (i_this->mB56 == 10) {
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
|
||||
i_this->current.pos.x = (i_this->mB68.x - 50.0f) + REG0_F(4);
|
||||
@@ -1859,7 +1860,7 @@ void demo_camera(fganon_class* i_this) {
|
||||
|
||||
i_this->mB68 = i_this->eyePos;
|
||||
i_this->mB68.y -= REG0_F(11) + 30.0f;
|
||||
i_this->m388++;
|
||||
i_this->mMode++;
|
||||
}
|
||||
case 54: {
|
||||
cLib_addCalc2(&i_this->mB68.y, (i_this->eyePos.y - 30.0f) + REG0_F(11), 0.1f, 20.0f);
|
||||
@@ -2130,8 +2131,8 @@ void energy_ball_move(fganon_class* i_this) {
|
||||
if (i_this->m40A != 0) {
|
||||
return;
|
||||
}
|
||||
i_this->m386 = 2;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 2;
|
||||
i_this->mMode = 0;
|
||||
i_this->m40A = 50;
|
||||
return;
|
||||
}
|
||||
@@ -2283,10 +2284,10 @@ void energy_ball_move(fganon_class* i_this) {
|
||||
|
||||
if (i_this->mBallAtSph.ChkAtHit() != 0) {
|
||||
atInfo.mpActor = i_this->mBallAtSph.GetAtHitObj()->GetAc();
|
||||
if ((atInfo.mpActor && (fopAcM_GetName(atInfo.mpActor) == PROC_PLAYER)) && (i_this->m386 != 22)) {
|
||||
if ((atInfo.mpActor && (fopAcM_GetName(atInfo.mpActor) == PROC_PLAYER)) && (i_this->mAction != 22)) {
|
||||
i_this->m68B = 1;
|
||||
i_this->m386 = 5;
|
||||
i_this->m388 = 1;
|
||||
i_this->mAction = 5;
|
||||
i_this->mMode = 1;
|
||||
i_this->m3A4[1] = (cM_rndF(30.0f)) + 70.f;
|
||||
}
|
||||
}
|
||||
@@ -2336,7 +2337,7 @@ static BOOL daFganon_Execute(fganon_class* i_this) {
|
||||
fpcM_Search(&mahou_se_set, i_this);
|
||||
g_env_light.settingTevStruct(TEV_TYPE_ACTOR, &i_this->current.pos, &i_this->tevStr);
|
||||
|
||||
if (((((i_this->m386 == 5) || (i_this->m386 == 9)) || (i_this->m386 == 7)) || (i_this->m386 == 10)) && ((i_this->m68B != 0 && (i_this->m68A == 0)))) {
|
||||
if (((((i_this->mAction == 5) || (i_this->mAction == 9)) || (i_this->mAction == 7)) || (i_this->mAction == 10)) && ((i_this->m68B != 0 && (i_this->m68A == 0)))) {
|
||||
i_this->m68B = 0;
|
||||
anm_init(i_this, FGANON_BCK_WARAU1, 6.0f, J3DFrameCtrl::EMode_LOOP, 1.0f, -1);
|
||||
i_this->m68A = 60;
|
||||
@@ -2431,7 +2432,7 @@ static BOOL daFganon_Execute(fganon_class* i_this) {
|
||||
energy_ball_move(i_this);
|
||||
|
||||
for (int i = 0; i < 2; i++) {
|
||||
if ((i_this->mbIsMaterialized != 0) && (i_this->m386 != 22)) {
|
||||
if ((i_this->mbIsMaterialized != 0) && (i_this->mAction != 22)) {
|
||||
if (i_this->mEmitters1[i] != NULL) {
|
||||
i_this->mEmitters1[i]->setGlobalRTMatrix(i_this->mpMorf->getModel()->getAnmMtx(jno[i]));
|
||||
}
|
||||
@@ -2831,8 +2832,8 @@ static cPhs_State daFganon_Create(fopAc_ac_c* i_act) {
|
||||
if (i_this->m68F == 0) {
|
||||
master = i_this;
|
||||
if (i_this->m2BC == 0) {
|
||||
i_this->m386 = 20;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 20;
|
||||
i_this->mMode = 0;
|
||||
kieru_brk(i_this, 0);
|
||||
i_this->max_health = 30;
|
||||
i_this->health = 30;
|
||||
@@ -2841,14 +2842,14 @@ static cPhs_State daFganon_Create(fopAc_ac_c* i_act) {
|
||||
else {
|
||||
i_this->max_health = 100;
|
||||
i_this->health = 100;
|
||||
i_this->m386 = 0;
|
||||
i_this->m388= -1;
|
||||
i_this->mAction = 0;
|
||||
i_this->mMode= -1;
|
||||
}
|
||||
i_this->current.pos.y += 10000.0f;
|
||||
}
|
||||
else {
|
||||
i_this->m386 = 10;
|
||||
i_this->m388 = 0;
|
||||
i_this->mAction = 10;
|
||||
i_this->mMode = 0;
|
||||
deru_brk(i_this);
|
||||
}
|
||||
i_this->initBt(REG8_F(8) + 300.0f, 300.0f);
|
||||
@@ -2877,7 +2878,7 @@ actor_process_profile_definition g_profile_FGANON = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E6,
|
||||
/* Priority */ PRIO_FGANON,
|
||||
/* Actor SubMtd */ &l_daFganon_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "d/actor/d_a_fgmahou.h"
|
||||
#include "d/d_procname.h"
|
||||
#include "d/d_priority.h"
|
||||
|
||||
/* 00000078-000000E4 .text daFgmahou_Draw__FP13fgmahou_class */
|
||||
static BOOL daFgmahou_Draw(fgmahou_class*) {
|
||||
@@ -64,7 +65,7 @@ actor_process_profile_definition g_profile_FGMAHOU = {
|
||||
/* SizeOther */ 0,
|
||||
/* Parameters */ 0,
|
||||
/* Leaf SubMtd */ &g_fopAc_Method.base,
|
||||
/* Priority */ 0x00E7,
|
||||
/* Priority */ PRIO_FGMAHOU,
|
||||
/* Actor SubMtd */ &l_daFgmahou_Method,
|
||||
/* Status */ fopAcStts_UNK40000_e,
|
||||
/* Group */ fopAc_ENEMY_e,
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user