TerraForge3D  2.3.1
3D Terrain And Landscape Generator

◆ GetAsset()

std::string ProjectManager::GetAsset ( std::string  id)

Definition at line 46 of file ProjectData.cpp.

47{
48 if(projectDatase.find(id) != projectDatase.end())
49 {
50 std::string path = projectDatase[id];
51#ifndef TERR3D_WIN32
52 // replace \ with /
53 for(int i = 0; i < path.size(); i++)
54 {
55 if(path[i] == '\\')
56 {
57 path[i] = '/';
58 }
59 }
60#endif
61 return path;
62 }
63
64 return "";
65}
iterator end() noexcept
returns an iterator to one past the last element
Definition: json.hpp:22448
iterator find(KeyT &&key)
find an element in a JSON object
Definition: json.hpp:22223