Link carryInfoMgr.cpp

This commit is contained in:
HeartPiece 2024-05-04 23:58:32 +10:00
parent 62a3c71dc2
commit e887c6dca4
11 changed files with 129 additions and 2733 deletions

File diff suppressed because it is too large Load Diff

View File

@ -843,7 +843,7 @@ LIBS = [
["plugProjectYamashitaU/chappyAnimator", True],
["plugProjectYamashitaU/chappyMgr", True],
["plugProjectYamashitaU/lifeGaugeMgr", False],
["plugProjectYamashitaU/carryInfoMgr", False],
["plugProjectYamashitaU/carryInfoMgr", True],
["plugProjectYamashitaU/gameLightMgr", False],
["plugProjectYamashitaU/vtxAnm", False],
["plugProjectYamashitaU/enemyInfo", True],

View File

@ -29,14 +29,14 @@
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JGadget/std-list.cpp">JGadget/std-list.cpp</a> | 6905 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio/jstudio-math.cpp">JStudio/jstudio-math.cpp</a> | 9130 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JParticle/JPAResourceLoader.cpp">JParticle/JPAResourceLoader.cpp</a> | 9871 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAI/JAISequenceHeap.cpp">JAudio//JAI/JAISequenceHeap.cpp</a> | 9983 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JParticle/JPAMath.cpp">JParticle/JPAMath.cpp</a> | 10154 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAI/JAIInitData.cpp">JAudio//JAI/JAIInitData.cpp</a> | 10317 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio_JStage/object-light.cpp">JStudio_JStage/object-light.cpp</a> | 11420 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASDSPChannel.cpp">JAudio//JAS/JASDSPChannel.cpp</a> | 11462 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio_JStage/object-light.cpp">JStudio_JStage/object-light.cpp</a> | 11420 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASDSPChannel.cpp">JAudio//JAS/JASDSPChannel.cpp</a> | 11896 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASTaskThread.cpp">JAudio//JAS/JASTaskThread.cpp</a> | 12200 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASWSParser.cpp">JAudio//JAS/JASWSParser.cpp</a> | 12435 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DJoint.cpp">J3D/J3DJoint.cpp</a> | 13780 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JParticle/JPADynamicsBlock.cpp">JParticle/JPADynamicsBlock.cpp</a> | 13972 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASAiCtrl.cpp">JAudio//JAS/JASAiCtrl.cpp</a> | 14267 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DShape.cpp">J3D/J3DShape.cpp</a> | 14990 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JGadget/std-vector.cpp">JGadget/std-vector.cpp</a> | 16058 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio_JParticle/object-particle.cpp">JStudio_JParticle/object-particle.cpp</a> | 16762 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio/stb.cpp">JStudio/stb.cpp</a> | 16978 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio_JStage/object-camera.cpp">JStudio_JStage/object-camera.cpp</a> | 17767 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DCluster.cpp">J3D/J3DCluster.cpp</a> | 18579 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAI/JAISystemInterface.cpp">JAudio//JAI/JAISystemInterface.cpp</a> | 19058 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DTextBoxEx.cpp">J2D/J2DTextBoxEx.cpp</a> | 19100 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASChannel.cpp">JAudio//JAS/JASChannel.cpp</a> | 19166 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DTextBoxEx.cpp">J2D/J2DTextBoxEx.cpp</a> | 19100 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASChannel.cpp">JAudio//JAS/JASChannel.cpp</a> | 19212 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JMessage/resource.cpp">JMessage/resource.cpp</a> | 19364 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASBNKParser.cpp">JAudio//JAS/JASBNKParser.cpp</a> | 19529 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DTevs.cpp">J3D/J3DTevs.cpp</a> | 20295 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio/fvb.cpp">JStudio/fvb.cpp</a> | 20306 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DModelLoaderCalcSize.cpp">J3D/J3DModelLoaderCalcSize.cpp</a> | 21199 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DMaterial.cpp">J3D/J3DMaterial.cpp</a> | 21468 |
@ -47,7 +47,7 @@
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DScreen.cpp">J2D/J2DScreen.cpp</a> | 30767 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAI/JAIBasic.cpp">JAudio//JAI/JAIBasic.cpp</a> | 30939 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J3D/J3DMaterialFactory_v21.cpp">J3D/J3DMaterialFactory_v21.cpp</a> | 35148 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio_JStage/object-actor.cpp">JStudio_JStage/object-actor.cpp</a> | 35187 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JMessage/processor.cpp">JMessage/processor.cpp</a> | 35637 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JParticle/JPAParticle.cpp">JParticle/JPAParticle.cpp</a> | 36971 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DMaterialFactory.cpp">J2D/J2DMaterialFactory.cpp</a> | 39462 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASAramStream.cpp">JAudio//JAS/JASAramStream.cpp</a> | 40005 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DMaterialFactory.cpp">J2D/J2DMaterialFactory.cpp</a> | 39462 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASAramStream.cpp">JAudio//JAS/JASAramStream.cpp</a> | 40087 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DPicture.cpp">J2D/J2DPicture.cpp</a> | 46511 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/J2D/J2DWindowEx.cpp">J2D/J2DWindowEx.cpp</a> | 47228 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAS/JASSeqParser.cpp">JAudio//JAS/JASSeqParser.cpp</a> | 48617 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JSystem/JStudio/functionvalue.cpp">JStudio/functionvalue.cpp</a> | 50054 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAI/JAIStreamMgr.cpp">JAudio//JAI/JAIStreamMgr.cpp</a> | 52959 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/JAudio/JSystem/JAI/JAISound.cpp">JAudio//JAI/JAISound.cpp</a> | 56856 |
@ -164,10 +164,10 @@
| File | Size (bytes) | File | Size (bytes) |
| ---- | ---- | ---- | ---- |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/enemyStoneDrawInfo.cpp">enemyStoneDrawInfo.cpp</a> | 19341 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/lifeGaugeMgr.cpp">lifeGaugeMgr.cpp</a> | 19694 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/carryInfoMgr.cpp">carryInfoMgr.cpp</a> | 20453 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/singleGS_ZukanParms.cpp">singleGS_ZukanParms.cpp</a> | 21961 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/vtxAnm.cpp">vtxAnm.cpp</a> | 31268 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/enemyAction.cpp">enemyAction.cpp</a> | 51416 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/generalEnemyMgr.cpp">generalEnemyMgr.cpp</a> | 54814 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/kochappyState.cpp">kochappyState.cpp</a> | 65633 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/gameLightMgr.cpp">gameLightMgr.cpp</a> | 74718 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/chappyState.cpp">chappyState.cpp</a> | 76087 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/singleGS_ZukanParms.cpp">singleGS_ZukanParms.cpp</a> | 21961 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/vtxAnm.cpp">vtxAnm.cpp</a> | 31268 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/enemyAction.cpp">enemyAction.cpp</a> | 51416 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/generalEnemyMgr.cpp">generalEnemyMgr.cpp</a> | 54814 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/kochappyState.cpp">kochappyState.cpp</a> | 65633 | <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/gameLightMgr.cpp">gameLightMgr.cpp</a> | 74718 |
| <a href="https://github.com/projectPiki/pikmin2/tree/main/src/plugProjectYamashitaU/chappyState.cpp">chappyState.cpp</a> | 76087 | | |
### <section id="sysBootupU">sysBootupU</section>
| File | Size (bytes) | File | Size (bytes) |

View File

@ -103,6 +103,10 @@ struct PokoInfoOwner : public CarryInfoOwner, public CNode {
// vtable 2 (CNode)
virtual ~PokoInfoOwner() { } // _1C (thunked at _14) (weak)
// unused/inlined:
bool update();
void start(CarryInfoList*, const Vector3f&, int);
// _00 = VTBL 1
// _04 = VTBL 2
// _04-_1C = CNode

View File

@ -27,6 +27,7 @@ struct InfoListBase : public JKRDisposer {
virtual ~InfoListBase() // _08
{
// this LOOKS like it should use pop() but IT DOES NOT, doing so destroys carryInfoMgr weak ordering
if (mPrev) {
mPrev->mNext = mNext;
}
@ -41,6 +42,30 @@ struct InfoListBase : public JKRDisposer {
virtual void draw(Graphics&) { } // _14
virtual bool isFinish() = 0; // _18
inline void pop()
{
if (mPrev) {
mPrev->mNext = mNext;
}
if (mNext) {
mNext->mPrev = mPrev;
}
mNext = nullptr;
mPrev = nullptr;
}
inline List* find(Owner* owner)
{
FOREACH_NODE(List, mNext, cList)
{
if (cList->mOwner == owner) {
return cList;
}
}
return nullptr;
}
// _00 = VTBL
// _00-_18 = JKRDisposer
List* mPrev; // _18
@ -52,12 +77,11 @@ template <typename Owner, typename List>
struct InfoMgr : public InfoMgrBase {
InfoMgr(int);
virtual ~InfoMgr() { } // _08
virtual List* regist(Owner* owner); // _18
virtual void scratch(Owner* owner); // _1C
virtual void loadResource() = 0; // _0C
virtual void update(); // _10
virtual void draw(Graphics& gfx); // _14
virtual List* regist(Owner* owner); // _18
virtual void scratch(Owner* owner); // _1C
List* search(List* list, Owner* owner);
void addActiveList(List* list);
@ -114,15 +138,7 @@ template <typename Owner, typename List>
List* InfoMgr<Owner, List>::regist(Owner* owner)
{
// SHOULD be using search, but wont inline (it needs to not inline in scratch so idk)
List* list;
FOREACH_NODE(List, list, cList)
{
if (cList->mOwner == owner) {
list = cList;
break;
}
}
// list = nullptr;
List* list = mActiveList.find(owner);
if (list == nullptr) {
list = (mInactiveList).mNext;
@ -146,16 +162,7 @@ void InfoMgr<Owner, List>::scratch(Owner* owner)
template <typename Owner, typename List>
void InfoMgr<Owner, List>::addActiveList(List* list)
{
if (list->mPrev) {
list->mPrev->mNext = list->mNext;
}
if (list->mNext) {
list->mNext->mPrev = list->mPrev;
}
list->mNext = nullptr;
list->mPrev = nullptr;
list->pop();
list->mPrev = &mActiveList;
list->mNext = mActiveList.mNext;
@ -170,16 +177,7 @@ template <typename Owner, typename List>
void InfoMgr<Owner, List>::addInactiveList(List* list)
{
list->mOwner = nullptr;
if (list->mPrev) {
list->mPrev->mNext = list->mNext;
}
if (list->mNext) {
list->mNext->mPrev = list->mPrev;
}
list->mNext = nullptr;
list->mPrev = nullptr;
list->pop();
list->mPrev = &mInactiveList;
list->mNext = mInactiveList.mNext;

View File

@ -7,7 +7,8 @@
#include "types.h"
// fabricated
struct JASGenericMem { };
struct JASGenericMem {
};
struct JASGenericMemPool {
JASGenericMemPool();
@ -25,21 +26,26 @@ struct JASGenericMemPool {
};
namespace JASCreationPolicy {
struct NewFromRootHeap { };
struct NewFromRootHeap {
};
/** @fabricated */
struct NewFromSystemHeap { };
struct NewFromSystemHeap {
};
} // namespace JASCreationPolicy
namespace JASThreadingModel {
struct SingleThreaded { };
struct SingleThreaded {
};
/** @fabricated */
struct MultiThreaded { };
struct MultiThreaded {
};
}; // namespace JASThreadingModel
template <typename T, typename ThreadingModel>
struct JASMemPool : public JASGenericMemPool { };
struct JASMemPool : public JASGenericMemPool {
};
template <typename T, typename CreationPolicy>
struct JASSingletonHolder {

View File

@ -440,21 +440,6 @@ struct Matrixf {
(*this)(2, 3) = pos.z;
}
inline void set(f32 scale, Matrixf* viewMtx)
{
(*this)(0, 0) = viewMtx->mMatrix.mtxView[0][0] * scale;
(*this)(1, 0) = viewMtx->mMatrix.mtxView[0][1] * scale;
(*this)(2, 0) = viewMtx->mMatrix.mtxView[0][2] * scale;
(*this)(0, 1) = viewMtx->mMatrix.mtxView[1][0] * scale;
(*this)(1, 1) = viewMtx->mMatrix.mtxView[1][1] * scale;
(*this)(2, 1) = viewMtx->mMatrix.mtxView[1][2] * scale;
(*this)(0, 2) = viewMtx->mMatrix.mtxView[2][0] * scale;
(*this)(1, 2) = viewMtx->mMatrix.mtxView[2][1] * scale;
(*this)(2, 2) = viewMtx->mMatrix.mtxView[2][2] * scale;
}
/**
* @brief Calculates the scaled translation of a 2D vector using the current matrix.
*

View File

@ -729,7 +729,7 @@ void JFWDrawDoneAlarm()
alarm.createAlarm();
alarm.appendLink();
OSRestoreInterrupts(status);
OSSetAlarm(&alarm, (OS_TIMER_CLOCK) * 0.5, JFWGXAbortAlarmHandler);
OSSetAlarm(&alarm, (OS_TIMER_CLOCK)*0.5, JFWGXAbortAlarmHandler);
GXDrawDone();
status = OSDisableInterrupts();
alarm.cancelAlarm();

View File

@ -14,7 +14,7 @@ YAMASHITA_FILES:=\
$(BUILD_DIR)/src/plugProjectYamashitaU/chappyAnimator.o\
$(BUILD_DIR)/src/plugProjectYamashitaU/chappyMgr.o\
$(BUILD_DIR)/asm/plugProjectYamashitaU/lifeGaugeMgr.o\
$(BUILD_DIR)/asm/plugProjectYamashitaU/carryInfoMgr.o\
$(BUILD_DIR)/src/plugProjectYamashitaU/carryInfoMgr.o\
$(BUILD_DIR)/asm/plugProjectYamashitaU/gameLightMgr.o\
$(BUILD_DIR)/asm/plugProjectYamashitaU/vtxAnm.o\
$(BUILD_DIR)/src/plugProjectYamashitaU/enemyInfo.o\

View File

@ -35,7 +35,6 @@ CarryInfoMgr* carryInfoMgr;
*/
CarryInfo::CarryInfo()
{
// guess, but something like this
mGrowRate = 0.0f;
mYOffset = 0.0f;
mState = CINFO_Hidden;
@ -162,384 +161,75 @@ void CarryInfo::update(const CarryInfoParam& param)
void CarryInfo::draw(Graphics& gfx, CarryInfoParam& param)
{
if (mState != CINFO_Hidden) {
Matrixf mtx;
Viewport* vp = gfx.mCurrentViewport;
mtx.set(mScale, vp->getMatrix(true));
Vector3f pos(param.mPosition.x, param.mPosition.y + mYOffset, param.mPosition.z);
mtx.setTranslation(pos);
Mtx storemtx;
Matrixf mtx;
Viewport* vp = gfx.mCurrentViewport;
Matrixf* viewMtx = vp->getMatrix(true);
mtx(0, 0) = viewMtx->mMatrix.mtxView[0][0] * mScale;
mtx(1, 0) = viewMtx->mMatrix.mtxView[0][1] * mScale;
mtx(2, 0) = viewMtx->mMatrix.mtxView[0][2] * mScale;
mtx(0, 1) = viewMtx->mMatrix.mtxView[1][0] * mScale;
mtx(1, 1) = viewMtx->mMatrix.mtxView[1][1] * mScale;
mtx(2, 1) = viewMtx->mMatrix.mtxView[1][2] * mScale;
mtx(0, 2) = viewMtx->mMatrix.mtxView[2][0] * mScale;
mtx(1, 2) = viewMtx->mMatrix.mtxView[2][1] * mScale;
mtx(2, 2) = viewMtx->mMatrix.mtxView[2][2] * mScale;
mtx(0, 3) = param.mPosition.x;
mtx(1, 3) = param.mPosition.y + mYOffset;
mtx(2, 3) = param.mPosition.z;
PSMTXConcat(vp->getMatrix(true)->mMatrix.mtxView, mtx.mMatrix.mtxView, storemtx);
GXLoadPosMtxImm(storemtx, 0);
switch (param.mUseType) {
case CINFOTYPE_Table:
f32 scale1, scale2, offs1, offs2;
f32 offs1, offs2;
f32 scale1, scale2;
if (!param.mIsTopFirst) {
scale1 = 0.75f;
scale2 = 1.1;
offs1 = 7.7f;
offs2 = -10.15f;
scale2 = 1.1f;
offs1 = 7.7000003f;
offs2 = -10.150001f;
} else {
scale1 = 1.1f;
scale2 = 0.75f;
offs1 = 10.15f;
offs2 = -7.7f;
offs1 = 10.150001f;
offs2 = -7.7000003f;
}
GXColor* top = &sColorTableNumerator[param.mColor];
Color4 colortop(top->r, top->g, top->b, mAlpha);
Color4 colortop, colorbottom;
colortop.set(sColorTableNumerator[param.mColor].r, sColorTableNumerator[param.mColor].g, sColorTableNumerator[param.mColor].b,
mAlpha);
colorbottom.set(sColorTableDenominator[param.mColor].r, sColorTableDenominator[param.mColor].g,
sColorTableDenominator[param.mColor].b, mAlpha);
GXColor* bottom = &sColorTableDenominator[param.mColor];
Color4 colorbottom(bottom->r, bottom->g, bottom->b, mAlpha);
drawNumberPrim(gfx, 0.0f, 0.0f, 10, colortop, 1.0f);
drawNumber(gfx, 0.0f, offs1, param.mCurrentWeight, colortop, scale1);
drawNumber(gfx, 0.0f, offs2, param.mMaxWeight, colorbottom, scale2);
break;
case CINFOTYPE_Scale:
f32 x = 7.0f;
f32 temp = (f32)mCounter * TAU * 0.03125;
temp = sinf(temp);
temp = (temp + 1.0f) * 0.5f;
Color4 color2, color;
color2.a = mAlpha;
f32 angle = (TAU * (f32)(mCounter % 32)) / 32;
f32 offset = 1.0f;
f32 temp = (offset + sinf(angle)) * 0.5f;
f32 x = 7.0f;
Color4 color2(255, 138, 21, mAlpha);
Color4 color(127, 11, 0, mAlpha);
color.r = temp * (255.0f);
color.g = temp * (155.0f);
color.b = temp * (59.0f);
color.a = temp * mAlpha;
color.r = temp * (255.0f - (f32)color.r) + (f32)(color.r);
color.g = temp * (155.0f - (f32)color.g) + (f32)(color.g);
color.b = temp * (59.0f - (f32)color.b) + (f32)(color.b);
color.a = temp * (mAlpha - (f32)color.a) + (f32)(color.a);
color2.r = 0xff;
color2.g = 0x8a;
color2.b = 0x15;
drawNumber(gfx, 7.0f, 0.0f, param.mValue, color2, 1.0f);
drawNumberPrim(gfx, (-x * 0.5f - 3.0f), 0.0f, 11, color, 1.0f);
f32 num = drawNumber(gfx, 7.0f, 0.0f, param.mValue, color2, 1.0f);
drawNumberPrim(gfx, -num * 0.5f - 3.0f, 0.0f, 11, color, 1.0f);
break;
default:
JUT_PANICLINE(403, "Illegal useType %d\n", param.mUseType);
break;
}
}
/*
stwu r1, -0x150(r1)
mflr r0
stw r0, 0x154(r1)
stfd f31, 0x140(r1)
psq_st f31, 328(r1), 0, qr0
stfd f30, 0x130(r1)
psq_st f30, 312(r1), 0, qr0
stfd f29, 0x120(r1)
psq_st f29, 296(r1), 0, qr0
stfd f28, 0x110(r1)
psq_st f28, 280(r1), 0, qr0
stmw r27, 0xfc(r1)
mr r29, r3
mr r30, r4
lbz r0, 0xc(r3)
mr r31, r5
cmplwi r0, 2
beq lbl_8011B6B8
lwz r27, 0x25c(r30)
li r4, 1
mr r3, r27
bl getMatrix__8ViewportFb
lfs f0, 0(r3)
li r4, 1
lfs f1, 8(r29)
fmuls f0, f0, f1
stfs f0, 0x18(r1)
lfs f0, 4(r3)
fmuls f0, f0, f1
stfs f0, 0x28(r1)
lfs f0, 8(r3)
fmuls f0, f0, f1
stfs f0, 0x38(r1)
lfs f0, 0x10(r3)
fmuls f0, f0, f1
stfs f0, 0x1c(r1)
lfs f0, 0x14(r3)
fmuls f0, f0, f1
stfs f0, 0x2c(r1)
lfs f0, 0x18(r3)
fmuls f0, f0, f1
stfs f0, 0x3c(r1)
lfs f0, 0x20(r3)
fmuls f0, f0, f1
stfs f0, 0x20(r1)
lfs f0, 0x24(r3)
fmuls f0, f0, f1
stfs f0, 0x30(r1)
lfs f0, 0x28(r3)
mr r3, r27
fmuls f0, f0, f1
stfs f0, 0x40(r1)
lfs f0, 4(r31)
stfs f0, 0x24(r1)
lfs f1, 8(r31)
lfs f0, 4(r29)
fadds f0, f1, f0
stfs f0, 0x34(r1)
lfs f0, 0xc(r31)
stfs f0, 0x44(r1)
bl getMatrix__8ViewportFb
addi r4, r1, 0x18
addi r5, r1, 0x48
bl PSMTXConcat
addi r3, r1, 0x48
li r4, 0
bl GXLoadPosMtxImm
lwz r6, 0(r31)
cmpwi r6, 1
beq lbl_8011B458
bge lbl_8011B69C
cmpwi r6, 0
bge lbl_8011B368
b lbl_8011B69C
lbl_8011B368:
lwz r0, 0x1c(r31)
cmpwi r0, 0
bne lbl_8011B388
lfs f29, lbl_80517B7C@sda21(r2)
lfs f28, lbl_80517B80@sda21(r2)
lfs f31, lbl_80517B84@sda21(r2)
lfs f30, lbl_80517B88@sda21(r2)
b lbl_8011B398
lbl_8011B388:
lfs f29, lbl_80517B80@sda21(r2)
lfs f28, lbl_80517B7C@sda21(r2)
lfs f31, lbl_80517B8C@sda21(r2)
lfs f30, lbl_80517B90@sda21(r2)
lbl_8011B398:
lbz r0, 0x15(r31)
lis r4, "sColorTableNumerator__26@unnamed@carryInfoMgr_cpp@"@ha
lis r3, "sColorTableDenominator__26@unnamed@carryInfoMgr_cpp@"@ha
lbz r10, 0xd(r29)
slwi r5, r0, 2
addi r0, r4, "sColorTableNumerator__26@unnamed@carryInfoMgr_cpp@"@l
add r4, r0, r5
addi r0, r3, "sColorTableDenominator__26@unnamed@carryInfoMgr_cpp@"@l
add r5, r0, r5
lfs f1, lbl_80517B60@sda21(r2)
lbz r9, 2(r4)
mr r3, r29
lbz r8, 1(r4)
fmr f2, f1
lbz r7, 0(r4)
mr r4, r30
lbz r12, 2(r5)
addi r6, r1, 0x14
lbz r11, 1(r5)
lbz r0, 0(r5)
li r5, 0xa
stb r7, 0x14(r1)
lfs f3, lbl_80517B6C@sda21(r2)
stb r8, 0x15(r1)
stb r9, 0x16(r1)
stb r10, 0x17(r1)
stb r0, 0x10(r1)
stb r11, 0x11(r1)
stb r12, 0x12(r1)
stb r10, 0x13(r1)
bl drawNumberPrim__9CarryInfoFR8GraphicsffiR6Color4f
fmr f2, f31
lfs f1, lbl_80517B60@sda21(r2)
fmr f3, f29
lhz r5, 0x16(r31)
mr r3, r29
mr r4, r30
addi r6, r1, 0x14
bl drawNumber__9CarryInfoFR8GraphicsffiR6Color4f
fmr f2, f30
lfs f1, lbl_80517B60@sda21(r2)
fmr f3, f28
lhz r5, 0x18(r31)
mr r3, r29
mr r4, r30
addi r6, r1, 0x10
bl drawNumber__9CarryInfoFR8GraphicsffiR6Color4f
b lbl_8011B6B8
lbl_8011B458:
lbz r3, 0xe(r29)
lis r0, 0x4330
stw r0, 0x78(r1)
slwi r0, r3, 0x1b
srwi r3, r3, 0x1f
subf r0, r3, r0
lfd f5, lbl_80517BB8@sda21(r2)
rotlwi r0, r0, 5
lfs f6, lbl_80517B94@sda21(r2)
add r0, r0, r3
lfs f2, lbl_80517B98@sda21(r2)
xoris r0, r0, 0x8000
lfs f0, lbl_80517B60@sda21(r2)
stw r0, 0x7c(r1)
lfs f3, lbl_80517B74@sda21(r2)
lfd f4, 0x78(r1)
lfs f1, lbl_80517B6C@sda21(r2)
fsubs f4, f4, f5
fmuls f4, f6, f4
fmuls f2, f4, f2
fcmpo cr0, f2, f0
bge lbl_8011B4DC
lfs f0, lbl_80517B9C@sda21(r2)
lis r3, sincosTable___5JMath@ha
addi r3, r3, sincosTable___5JMath@l
fmuls f0, f2, f0
fctiwz f0, f0
stfd f0, 0x80(r1)
lwz r0, 0x84(r1)
rlwinm r0, r0, 3, 0x12, 0x1c
lfsx f0, r3, r0
fneg f0, f0
b lbl_8011B500
lbl_8011B4DC:
lfs f0, lbl_80517BA0@sda21(r2)
lis r3, sincosTable___5JMath@ha
addi r3, r3, sincosTable___5JMath@l
fmuls f0, f2, f0
fctiwz f0, f0
stfd f0, 0x88(r1)
lwz r0, 0x8c(r1)
rlwinm r0, r0, 3, 0x12, 0x1c
lfsx f0, r3, r0
lbl_8011B500:
lbz r27, 0xd(r29)
lis r5, 0x4330
li r7, 0x7f
li r10, 0xb
li r9, 0
clrlwi r0, r27, 0x18
stw r7, 0x94(r1)
fadds f2, f1, f0
li r28, 0xff
li r12, 0x8a
stw r5, 0x90(r1)
li r11, 0x15
lfd f0, lbl_80517BC0@sda21(r2)
lfd f1, 0x90(r1)
fmuls f4, f3, f2
stw r10, 0xac(r1)
mr r3, r29
fsubs f2, f1, f0
lfs f3, lbl_80517B70@sda21(r2)
stw r5, 0xa8(r1)
lfs f5, lbl_80517BA4@sda21(r2)
mr r4, r30
lfd f1, 0xa8(r1)
stw r9, 0xc4(r1)
fsubs f10, f3, f2
fsubs f3, f1, f0
lfs f7, lbl_80517BA8@sda21(r2)
stw r5, 0xc0(r1)
addi r6, r1, 0xc
lfs f1, lbl_80517BAC@sda21(r2)
lfd f2, 0xc0(r1)
stw r27, 0xdc(r1)
fsubs f9, f5, f3
fsubs f6, f2, f0
lfs f2, lbl_80517B60@sda21(r2)
stw r5, 0xd8(r1)
lfs f3, lbl_80517B6C@sda21(r2)
lfd f5, 0xd8(r1)
fsubs f7, f7, f6
stw r0, 0xe4(r1)
fsubs f6, f5, f0
stw r5, 0xe0(r1)
lfd f5, 0xe0(r1)
stw r7, 0x9c(r1)
fsubs f5, f5, f0
stw r5, 0x98(r1)
lfd f8, 0x98(r1)
fsubs f6, f6, f5
stw r10, 0xb4(r1)
fsubs f8, f8, f0
stw r5, 0xb0(r1)
lfd f5, 0xb0(r1)
fmadds f10, f4, f10, f8
stw r9, 0xcc(r1)
fsubs f8, f5, f0
stw r5, 0xc8(r1)
fctiwz f10, f10
lfd f5, 0xc8(r1)
fmadds f8, f4, f9, f8
stfd f10, 0xa0(r1)
fsubs f5, f5, f0
fctiwz f8, f8
stw r0, 0xec(r1)
lwz r8, 0xa4(r1)
stw r5, 0xe8(r1)
fmadds f7, f4, f7, f5
lfd f5, 0xe8(r1)
fctiwz f7, f7
stfd f8, 0xb8(r1)
fsubs f0, f5, f0
stb r7, 8(r1)
lwz r7, 0xbc(r1)
fmadds f0, f4, f6, f0
stfd f7, 0xd0(r1)
stb r10, 9(r1)
fctiwz f0, f0
lwz r5, 0xd4(r1)
stb r9, 0xa(r1)
stfd f0, 0xf0(r1)
stb r27, 0xb(r1)
lwz r0, 0xf4(r1)
stb r28, 0xc(r1)
stb r12, 0xd(r1)
stb r11, 0xe(r1)
stb r27, 0xf(r1)
stb r8, 8(r1)
stb r7, 9(r1)
stb r5, 0xa(r1)
stb r0, 0xb(r1)
lwz r5, 0x20(r31)
bl drawNumber__9CarryInfoFR8GraphicsffiR6Color4f
fneg f1, f1
lfs f3, lbl_80517B74@sda21(r2)
lfs f0, lbl_80517BB0@sda21(r2)
mr r3, r29
lfs f2, lbl_80517B60@sda21(r2)
mr r4, r30
fmsubs f1, f3, f1, f0
lfs f3, lbl_80517B6C@sda21(r2)
addi r6, r1, 8
li r5, 0xb
bl drawNumberPrim__9CarryInfoFR8GraphicsffiR6Color4f
b lbl_8011B6B8
lbl_8011B69C:
lis r3, lbl_8047B268@ha
lis r4, lbl_8047B27C@ha
addi r5, r4, lbl_8047B27C@l
addi r3, r3, lbl_8047B268@l
li r4, 0x193
crclr 6
bl panic_f__12JUTExceptionFPCciPCce
lbl_8011B6B8:
psq_l f31, 328(r1), 0, qr0
lfd f31, 0x140(r1)
psq_l f30, 312(r1), 0, qr0
lfd f30, 0x130(r1)
psq_l f29, 296(r1), 0, qr0
lfd f29, 0x120(r1)
psq_l f28, 280(r1), 0, qr0
lfd f28, 0x110(r1)
lmw r27, 0xfc(r1)
lwz r0, 0x154(r1)
mtlr r0
addi r1, r1, 0x150
blr
*/
}
/**
@ -655,6 +345,30 @@ void PokoInfoOwner::getCarryInfoParam(CarryInfoParam& param)
param.mValue = mValue;
}
/**
* @note Address: N/A
* @note Size: 0x9C
*/
void PokoInfoOwner::start(CarryInfoList* list, const Vector3f&, int) { list->InfoListBase::init(); }
/**
* @note Address: N/A
* @note Size: 0x9C
*/
bool PokoInfoOwner::update()
{
bool res = false;
if (mList->isFinish() || mList->mOwner != this) {
res = true;
} else {
mTimer += sys->mDeltaTime;
if (mTimer > 1.5f) {
mList->mParam.mCarryInfo.mState = CINFO_Disappear;
}
}
return res;
}
/**
* @note Address: 0x8011BC94
* @note Size: 0xD4
@ -733,7 +447,7 @@ void CarryInfoMgr::loadResource()
*/
void CarryInfoMgr::draw(Graphics& gfx)
{
if (!Game::moviePlayer || !Game::moviePlayer->mFlags.isSet(1)) {
if (!Game::moviePlayer || !Game::moviePlayer->isFlag(Game::MVP_IsActive)) {
Graphics::clearInitGX();
GXSetNumChans(1);
GXSetTevDirect(GX_TEVSTAGE0);
@ -750,12 +464,12 @@ void CarryInfoMgr::draw(Graphics& gfx)
GXSetVtxAttrFmt(GX_VTXFMT0, GX_VA_TEX0, GX_POS_XYZ, GX_F32, 0);
GXSetBlendMode(GX_BM_BLEND, GX_BL_SRCALPHA, GX_BL_INVSRCALPHA, GX_LO_SET);
GXSetZMode(GX_FALSE, GX_LESS, GX_FALSE);
GXSetCurrentMtx(0);
GXSetCurrentMtx(GX_PNMTX0);
GXSetNumTexGens(1);
GXSetTexCoordGen2(GX_TEXCOORD0, GX_TG_MTX3X4, GX_TG_TEXCOORD0, 0x3c, GX_FALSE, 0x7d);
GXSetTexCoordGen2(GX_TEXCOORD0, GX_TG_MTX3X4, GX_TG_TEXCOORD0, GX_IDENTITY, GX_FALSE, GX_PTIDENTITY);
Matrixf mtx;
PSMTXIdentity(mtx.mMatrix.mtxView);
GXLoadTexMtxImm(mtx.mMatrix.mtxView, 0x1e, GX_MTX2x4);
GXLoadTexMtxImm(mtx.mMatrix.mtxView, GX_TEXMTX0, GX_MTX2x4);
mTexture->load(GX_TEXMAP0);
InfoMgr<CarryInfoOwner, CarryInfoList>::draw(gfx);
}
@ -787,17 +501,7 @@ void CarryInfoMgr::updatePokoInfoOwners()
for (obj; obj != 0;) {
current = (PokoInfoOwner*)(obj->mNext);
doDelete = false;
if (obj->mList->isFinish() || obj->mList->mOwner != obj) {
doDelete = true;
} else {
obj->mTimer += sys->mDeltaTime;
if (obj->mTimer > 1.5f) {
obj->mList->mParam.mCarryInfo.mState = CINFO_Disappear;
}
}
if (doDelete) {
if (obj->update()) {
obj->del();
mPoko_node.add(obj);
}

View File

@ -959,3 +959,5 @@ You have 4315 out of 10000 Pokos and 110 out of 201 treasures.",2024-05-04 00:22
You have 4321 out of 10000 Pokos and 110 out of 201 treasures.",2024-05-04 02:05:15.054225
4334,2016548,0.4334469962719932,110,392404,0.550467415579023,"
You have 4334 out of 10000 Pokos and 110 out of 201 treasures.",2024-05-04 14:11:30.731573
4345,2021532,0.4345182823655648,110,392815,0.5510439696095705,"
You have 4345 out of 10000 Pokos and 110 out of 201 treasures.",2024-05-04 23:49:41.977217

1 code_count_in_pokos code_completion_in_bytes code_completion_in_percentage data_count_in_treasures data_completion_in_bytes data_completion_in_percentage sentence created_at
959
960
961
962
963