Kelsidavis-WoWee/tools/editor/asset_browser.hpp
Kelsi a6b8cd75f6 feat(editor): map browser for loading existing WoW zones
- Load Map Tile dialog now shows a searchable list of all available
  maps from the manifest (Azeroth, Kalimdor, Outland, dungeons, etc.)
- Click a map name to select it, then pick tile X/Y coordinates
- Helpful tile range hints shown below coordinates
- Maps indexed from WDT files in the manifest on startup
- Foundation for loading and modifying sections of existing WoW maps
2026-05-05 06:01:42 -07:00

49 lines
1.4 KiB
C++

#pragma once
#include <string>
#include <vector>
#include <unordered_map>
namespace wowee {
namespace pipeline { class AssetManager; }
namespace editor {
struct AssetEntry {
std::string wowPath;
std::string displayName;
std::string directory;
};
class AssetBrowser {
public:
void initialize(pipeline::AssetManager* am);
const std::vector<AssetEntry>& getTextures() const { return textures_; }
const std::vector<AssetEntry>& getM2Models() const { return m2Models_; }
const std::vector<AssetEntry>& getWMOs() const { return wmos_; }
const std::vector<std::string>& getTextureDirectories() const { return textureDirs_; }
const std::vector<std::string>& getM2Directories() const { return m2Dirs_; }
const std::vector<std::string>& getWMODirectories() const { return wmoDirs_; }
const std::vector<std::string>& getMapNames() const { return mapNames_; }
bool isInitialized() const { return initialized_; }
private:
static std::string extractFilename(const std::string& path);
static std::string extractDirectory(const std::string& path);
std::vector<AssetEntry> textures_;
std::vector<AssetEntry> m2Models_;
std::vector<AssetEntry> wmos_;
std::vector<std::string> textureDirs_;
std::vector<std::string> m2Dirs_;
std::vector<std::string> wmoDirs_;
std::vector<std::string> mapNames_;
bool initialized_ = false;
};
} // namespace editor
} // namespace wowee