MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / readFileContent

Function readFileContent

engine/Evaluator/EvalState.cpp:709–717  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

707#include <sstream>
708
709static std::string readFileContent(const std::string& path)
710{
711 std::ifstream f(path);
712 if (!f.is_open())
713 return "";
714 std::stringstream ss;
715 ss << f.rdbuf();
716 return ss.str();
717}
718
719// In-game exec is non-blocking; the evaluator runs the SQS synchronously.
720static GameValue CmdExec(const GameState* state, GameValuePar lhs, GameValuePar rhs)

Callers 1

CmdExecFunction · 0.85

Calls 1

strMethod · 0.80

Tested by

no test coverage detected