mirror of
https://github.com/zeldaret/ss
synced 2026-09-02 17:53:15 -04:00
Merge pull request #301 from robojumper/d_lyt_meter_suiryu_score
d_lyt_suiryu_score mostly OK
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
#ifndef MISC_ACTOR_H
|
||||
#define MISC_ACTOR_H
|
||||
|
||||
#include "common.h"
|
||||
#include "d/flag/sceneflag_manager.h"
|
||||
#include "d/t/d_t_clef_game.h"
|
||||
|
||||
// TODO - this header might be unnecessary; a lot of functions in
|
||||
// the split corresponding to this header clearly are REL functions
|
||||
// that were moved to the DOL because they need to be called from the DOL.
|
||||
@@ -9,4 +13,47 @@
|
||||
bool checkIsInSkykeepPuzzle();
|
||||
void restoreSkykeepPuzzleFromGlobal();
|
||||
|
||||
extern const u8 sTadtoneSceneflags[];
|
||||
extern const u8 sTadtoneGroupSizes[];
|
||||
|
||||
inline bool isValidTadtoneGroupIndex(s32 i) {
|
||||
return 0 <= i && i <= 17 - 1;
|
||||
}
|
||||
|
||||
inline void unkTadtoneInline(s32 i, u8 *result) {
|
||||
if (result != nullptr) {
|
||||
if (isValidTadtoneGroupIndex(i)) {
|
||||
if (SceneflagManager::sInstance->isNotTempOrZoneFlag(sTadtoneSceneflags[i])) {
|
||||
if (SceneflagManager::sInstance->checkTempOrSceneflag(sTadtoneSceneflags[i])) {
|
||||
*result = sTadtoneGroupSizes[i];
|
||||
} else if (dTgClefGame_c::GetInstance() == nullptr) {
|
||||
*result = 0;
|
||||
} else {
|
||||
*result = dTgClefGame_c::GetInstance()->getField_0x14C(i);
|
||||
}
|
||||
} else {
|
||||
*result = sTadtoneGroupSizes[i];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
inline void unkTadtoneInline2(s32 i, u8 *result) {
|
||||
if (result != nullptr) {
|
||||
if (isValidTadtoneGroupIndex(i)) {
|
||||
*result = sTadtoneGroupSizes[i];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
inline void unkTadtoneInline3(s32 i, u8 *result) {
|
||||
if (result != nullptr) {
|
||||
if (isValidTadtoneGroupIndex(i)) {
|
||||
if (dTgClefGame_c::GetInstance() != nullptr) {
|
||||
*result = dTgClefGame_c::GetInstance()->getField_0x15D(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user