Entity::Entity(std::string fn, ResourceCache<Mesh>& mesh_map, ResourceCache<Texture>& tex_map, glm::vec3 pos, unsigned int entflags/*, std::string override_name, float minlod*/) { shared_ptr<Mesh> mesh_ptr = mesh_map.cache(fn); if(!mesh_ptr->good()) mesh_ptr->load(fn, tex_map); addMesh(mesh_ptr); position(pos); m_Flags = entflags; }