mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-07-03 12:35:51 +00:00
CLogBookScreen: Dehardcode constants where applicable
We can just query the containers for the iteration value
This commit is contained in:
parent
4b78d51a85
commit
3951a07bfa
@ -34,7 +34,7 @@ bool CLogBookScreen::IsScanComplete(CSaveWorld::EScanCategory category, CAssetId
|
|||||||
}
|
}
|
||||||
|
|
||||||
void CLogBookScreen::InitializeLogBook() {
|
void CLogBookScreen::InitializeLogBook() {
|
||||||
for (int i = 0; i < 5; ++i) {
|
for (size_t i = 0; i < x19c_scanCompletes.size(); ++i) {
|
||||||
x19c_scanCompletes[i].reserve(g_MemoryCardSys->GetScanCategoryCount(CSaveWorld::EScanCategory(i + 1)));
|
x19c_scanCompletes[i].reserve(g_MemoryCardSys->GetScanCategoryCount(CSaveWorld::EScanCategory(i + 1)));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -345,7 +345,7 @@ void CLogBookScreen::Draw(float transInterp, float totalAlpha, float yOff) {
|
|||||||
bool CLogBookScreen::VReady() const { return true; }
|
bool CLogBookScreen::VReady() const { return true; }
|
||||||
|
|
||||||
void CLogBookScreen::VActivate() {
|
void CLogBookScreen::VActivate() {
|
||||||
for (int i = 0; i < 5; ++i) {
|
for (int i = 0; i < int(xa8_textpane_categories.size()); ++i) {
|
||||||
if (IsScanCategoryReady(CSaveWorld::EScanCategory(i + 1))) {
|
if (IsScanCategoryReady(CSaveWorld::EScanCategory(i + 1))) {
|
||||||
xa8_textpane_categories[i]->TextSupport().SetText(xc_pauseStrg.GetString(i + 1));
|
xa8_textpane_categories[i]->TextSupport().SetText(xc_pauseStrg.GetString(i + 1));
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user