MCPcopy Create free account
hub / github.com/OpenFodder/openfodder / Demo_Load

Method Demo_Load

Source/Fodder.cpp:18744–18758  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18742}
18743
18744bool cFodder::Demo_Load() {
18745
18746 std::ifstream DemoContent(mStartParams->mDemoFile, std::ios::binary);
18747 if (DemoContent.is_open()) {
18748
18749 std::string SaveGameContent(
18750 (std::istreambuf_iterator<char>(DemoContent)),
18751 (std::istreambuf_iterator<char>())
18752 );
18753
18754 mGame_Data.mDemoRecorded.FromJson(SaveGameContent);
18755 return true;
18756 }
18757 return false;
18758}
18759
18760void cFodder::Window_UpdateScreenSize() {
18761

Callers 1

RunTestsMethod · 0.80

Calls 1

FromJsonMethod · 0.45

Tested by 1

RunTestsMethod · 0.64