void AddTextureToTileTxtMap(std::string txtPath, std::string key) { std::shared_ptr<sf::Texture> tempText(new sf::Texture()); if(!(*tempText).loadFromFile(txtPath)) { std::cout << " texture was not loaded!" << std::endl; } txtMap->insert(MapPair(key, tempText)); }
void Manager::AddConnection(const ID& id, const Id& evtId, Function fct) { manager_mutex.lock(); auto it = _event_fct_map.find(id); if (it != _event_fct_map.end()) { it->second.insert(MultimapPair(evtId, fct)); } else { Multimap evt_map; evt_map.insert(MultimapPair(evtId, fct)); _event_fct_map.insert(MapPair(id, evt_map)); } manager_mutex.unlock(); }