mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2026-09-22 22:07:08 +00:00
feat: combine loading bar and zone list
This commit is contained in:
@@ -4,15 +4,26 @@
|
||||
#include "Zone/Zone.h"
|
||||
|
||||
#include <memory>
|
||||
#include <shared_mutex>
|
||||
#include <vector>
|
||||
|
||||
class LoadedZone
|
||||
{
|
||||
public:
|
||||
std::unique_ptr<Zone> m_zone;
|
||||
std::string m_file_path;
|
||||
|
||||
LoadedZone(std::unique_ptr<Zone> zone, std::string filePath);
|
||||
};
|
||||
|
||||
class FastFileContext
|
||||
{
|
||||
public:
|
||||
void Destroy();
|
||||
|
||||
result::Expected<Zone*, std::string> LoadFastFile(const std::string& path);
|
||||
result::Expected<LoadedZone*, std::string> LoadFastFile(const std::string& path);
|
||||
result::Expected<NoResult, std::string> UnloadZone(const std::string& zoneName);
|
||||
|
||||
std::vector<std::unique_ptr<Zone>> m_loaded_zones;
|
||||
std::vector<std::unique_ptr<LoadedZone>> m_loaded_zones;
|
||||
std::shared_mutex m_zone_lock;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user