mirror of
https://github.com/projectPiki/pikmin2.git
synced 2025-02-25 16:20:52 +00:00
Rename some GameMessage
This commit is contained in:
parent
3b966db64f
commit
fcf2f8560f
@ -102,15 +102,15 @@ struct GameMessageVsGetOtakara : public GameMessage {
|
||||
};
|
||||
|
||||
struct GameMessageVsGotCard : public GameMessage {
|
||||
inline GameMessageVsGotCard(u32 onyonType)
|
||||
: _04(onyonType)
|
||||
inline GameMessageVsGotCard(u32 userIndex)
|
||||
: mUserIndex(userIndex)
|
||||
{
|
||||
}
|
||||
|
||||
virtual bool actVs(VsGameSection*); // _10
|
||||
|
||||
// _00 = VTBL
|
||||
u32 _04; // _04, onyon type according to ghidra, but that enum is meant to be a short
|
||||
u32 mUserIndex; // _04
|
||||
};
|
||||
|
||||
struct GameMessageVsPikminDead : public GameMessage {
|
||||
@ -127,11 +127,11 @@ struct GameMessageVsRedOrSuckStart : public GameMessage {
|
||||
};
|
||||
|
||||
struct GameMessageVsUseCard : public GameMessage {
|
||||
GameMessageVsUseCard(int id) { _04 = id; }
|
||||
GameMessageVsUseCard(int id) { mSlotIndex = id; }
|
||||
virtual bool actVs(VsGameSection*); // _10
|
||||
|
||||
// _00 = VTBL
|
||||
int _04; // _04
|
||||
int mSlotIndex; // _04
|
||||
};
|
||||
|
||||
} // namespace Game
|
||||
|
@ -970,11 +970,11 @@ bool GameMessageVsPikminDead::actVs(VsGameSection* section)
|
||||
*/
|
||||
bool GameMessageVsGotCard::actVs(VsGameSection* section)
|
||||
{
|
||||
VsGame::CardMgr::SlotMachine* slot = §ion->mCardMgr->mSlotMachines[_04];
|
||||
VsGame::CardMgr::SlotMachine* slot = §ion->mCardMgr->mSlotMachines[mUserIndex];
|
||||
if (!slot->_18 && slot->mSlotID != VsGame::UNRESOLVED) {
|
||||
section->useCard();
|
||||
}
|
||||
section->mCardMgr->gotPlayerCard(_04);
|
||||
section->mCardMgr->gotPlayerCard(mUserIndex);
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -990,11 +990,11 @@ bool GameMessageVsUseCard::actVs(VsGameSection* section)
|
||||
}
|
||||
}
|
||||
if (gGameConfig.mParms.mVsY.mData == 0) {
|
||||
if (section->mCardMgr->usePlayerCard(_04, section->mTekiMgr)) {
|
||||
if (section->mCardMgr->usePlayerCard(mSlotIndex, section->mTekiMgr)) {
|
||||
section->useCard();
|
||||
}
|
||||
} else {
|
||||
section->mCardMgr->stopSlot(_04);
|
||||
section->mCardMgr->stopSlot(mSlotIndex);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user