Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions soh/soh/Enhancements/randomizer/item_category_adj.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,32 @@ GetItemCategory Randomizer_AdjustItemCategory(GetItemEntry item) {

return category;
}

// Singular, since this names a single check's contents (e.g. what a chest's
// size and texture convey), not a group of them.
const CustomMessage& ItemCategoryName(GetItemCategory category) {
static const CustomMessage major = CustomMessage("Major Item", "Wichtiger Gegenstand", "Objet majeur");
static const CustomMessage bossKeys = CustomMessage("Boss Key", "Master-Schlüssel", "Clé d'Or");
static const CustomMessage smallKeys = CustomMessage("Small Key", "Kleiner Schlüssel", "Petite Clé");
static const CustomMessage tokens = CustomMessage("Skulltula Token", "Skulltula-Symbol", "Symbole de Skulltula");
static const CustomMessage hearts = CustomMessage("Heart", "Herz", "Cœur");
static const CustomMessage lesser = CustomMessage("Lesser Item", "Kleinerer Gegenstand", "Objet mineur");
static const CustomMessage junk = CustomMessage("Junk Item", "Nutzloser Gegenstand", "Objet inutile");
switch (category) {
case ITEM_CATEGORY_MAJOR:
return major;
case ITEM_CATEGORY_BOSS_KEY:
return bossKeys;
case ITEM_CATEGORY_SMALL_KEY:
return smallKeys;
case ITEM_CATEGORY_SKULLTULA_TOKEN:
return tokens;
case ITEM_CATEGORY_HEALTH:
return hearts;
case ITEM_CATEGORY_LESSER:
return lesser;
case ITEM_CATEGORY_JUNK:
default:
return junk;
}
}
6 changes: 6 additions & 0 deletions soh/soh/Enhancements/randomizer/item_category_adj.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ GetItemCategory Randomizer_AdjustItemCategory(GetItemEntry item);

#ifdef __cplusplus
}

#include "soh/Enhancements/custom-message/CustomMessageManager.h"

// Localized name for an item category, e.g. the label a chest's size and
// texture convey. Shared by the hint and check trackers.
const CustomMessage& ItemCategoryName(GetItemCategory category);
#endif

#endif
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ RANDO_ENUM_END(RandomizerCheckArea)
// Check tracker check visibility categories
RANDO_ENUM_BEGIN(RandomizerCheckStatus)
RANDO_ENUM_ITEM(RCSHOW_UNCHECKED)
RANDO_ENUM_ITEM(RCSHOW_CATEGORY)
RANDO_ENUM_ITEM(RCSHOW_SEEN_OR_HINTED)
RANDO_ENUM_ITEM(RCSHOW_IDENTIFIED)
RANDO_ENUM_ITEM(RCSHOW_SCUMMED)
Expand Down
Loading
Loading