MCPcopy Create free account
hub / github.com/codereader/DarkRadiant / getMapFormatForFilename

Method getMapFormatForFilename

radiantcore/map/format/MapFormatManager.cpp:63–74  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

61}
62
63MapFormatPtr MapFormatManager::getMapFormatForFilename(const std::string& filename)
64{
65 if (!GlobalGameManager().currentGame())
66 {
67 return MapFormatPtr();
68 }
69
70 // Look up the module name which loads the given extension
71 std::string gameType = GlobalGameManager().currentGame()->getKeyValue("type");
72
73 return getMapFormatForGameType(gameType, os::getExtension(filename));
74}
75
76std::set<MapFormatPtr> MapFormatManager::getAllMapFormats()
77{

Callers 5

TEST_FFunction · 0.80
TEST_FFunction · 0.80
getInfoFilePathFunction · 0.80
getFormatMethod · 0.80

Calls 3

getExtensionFunction · 0.85
currentGameMethod · 0.45
getKeyValueMethod · 0.45

Tested by

no test coverage detected