mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2024-11-15 04:38:21 +00:00
Update Zone.cpp
This commit is contained in:
parent
1ea65b3549
commit
3f9d1a18f0
@ -241,33 +241,15 @@ void Zone::LoadScene(std::istream& file) {
|
||||
m_Scenes.insert(std::make_pair(lwoSceneID, scene));
|
||||
}
|
||||
|
||||
<<<<<<< Updated upstream
|
||||
void Zone::LoadLUTriggers(std::string triggerFile, SceneRef& scene) {
|
||||
auto buffer = Game::assetManager->GetFileAsBuffer((m_ZonePath + triggerFile).c_str());
|
||||
=======
|
||||
std::vector<LUTriggers::Trigger*> Zone::LoadLUTriggers(std::string triggerFile, LWOSCENEID sceneID) {
|
||||
std::vector<LUTriggers::Trigger*> lvlTriggers;
|
||||
|
||||
auto file = Game::assetManager->GetFile((m_ZonePath + triggerFile).c_str());
|
||||
>>>>>>> Stashed changes
|
||||
|
||||
if (!file) {
|
||||
LOG("Failed to load %s from disk. Skipping loading triggers", (m_ZonePath + triggerFile).c_str());
|
||||
return;
|
||||
}
|
||||
|
||||
std::stringstream data;
|
||||
data << file.rdbuf();
|
||||
|
||||
<<<<<<< Updated upstream
|
||||
buffer.close();
|
||||
|
||||
data.seekg(0, std::ios::end);
|
||||
int32_t size = data.tellg();
|
||||
data.seekg(0, std::ios::beg);
|
||||
=======
|
||||
if (data.str().size() == 0) return lvlTriggers;
|
||||
>>>>>>> Stashed changes
|
||||
|
||||
if (size == 0) return;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user