1#ifndef YAZE_APP_EDITOR_DUNGEON_DUNGEON_PROJECT_LABELS_H
2#define YAZE_APP_EDITOR_DUNGEON_DUNGEON_PROJECT_LABELS_H
7#include "absl/strings/str_format.h"
35 if (tag && !tag->enabled) {
36 label +=
" (disabled)";
44 size_t* dungeon_index =
nullptr) {
56 for (
size_t i = 0; i < dungeons.size(); ++i) {
57 const auto& dungeon = dungeons[i];
58 for (
const auto& room : dungeon.rooms) {
59 if (room.id == room_id) {
76 for (
const auto& room : dungeon->
rooms) {
77 if (room.id == room_id) {
85 if (dungeon.
id.empty()) {
88 if (dungeon.
name.empty()) {
91 return absl::StrFormat(
"%s %s", dungeon.
id, dungeon.
name);
103 room && !room->
floor.empty()) {
106 return std::string();
112 room && !room->
name.empty()) {
std::optional< RoomTagEntry > GetRoomTag(uint8_t tag_id) const
Get the full room tag entry for a tag ID.
const ProjectRegistry & project_registry() const
bool HasProjectRegistry() const
Unified interface for accessing resource labels with project overrides.
std::unordered_map< std::string, LabelMap > ProjectLabels
void SetHackManifest(const core::HackManifest *manifest)
Set the hack manifest reference for ASM-defined labels.
void SetProjectLabels(ProjectLabels *labels)
Set the project labels reference (typically from YazeProject)
zelda3::ResourceLabelProvider LabelsForProject(const project::YazeProject *project)
std::string GetRoomTagLabel(const project::YazeProject *project, int id)
std::string GetRoomLabel(const project::YazeProject *project, int room_id)
const core::DungeonEntry * FindDungeonForRoom(const project::YazeProject *project, int room_id, size_t *dungeon_index=nullptr)
std::string GetDungeonNameForRoom(const project::YazeProject *project, int room_id)
const core::DungeonRoom * FindDungeonRoom(const project::YazeProject *project, int room_id)
std::string GetRoomFloorLabel(const project::YazeProject *project, int room_id)
std::string FormatDungeonName(const core::DungeonEntry &dungeon)
ResourceLabelProvider & GetResourceLabels()
Get the global ResourceLabelProvider instance.
A complete dungeon entry with rooms and connections.
std::vector< DungeonRoom > rooms
A room within a dungeon, with spatial and metadata info.
std::vector< DungeonEntry > dungeons
Modern project structure with comprehensive settings consolidation.
bool project_opened() const
core::HackManifest hack_manifest
std::unordered_map< std::string, std::unordered_map< std::string, std::string > > resource_labels