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

Method LoadForCurrentMod

plugins/dm.editing/ReadmeTxt.cpp:43–58  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

41}
42
43ReadmeTxtPtr ReadmeTxt::LoadForCurrentMod()
44{
45 std::string readmeTxtPath = GetOutputPathForCurrentMod() + NAME();
46
47 rMessage() << "Trying to open file " << readmeTxtPath << std::endl;
48
49 ArchiveTextFilePtr file = GlobalFileSystem().openTextFileInAbsolutePath(readmeTxtPath);
50
51 if (file)
52 {
53 std::istream stream(&(file->getInputStream()));
54 return CreateFromStream(stream);
55 }
56
57 return std::make_shared<ReadmeTxt>();
58}
59
60std::string ReadmeTxt::toString()
61{

Callers

nothing calls this directly

Calls 2

rMessageFunction · 0.85

Tested by

no test coverage detected