MCPcopy Create free account
hub / github.com/dds-bridge/dds / PrintFunctionTable

Method PrintFunctionTable

library/src/moves/moves.cpp:1099–1117  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1097}
1098
1099auto Moves::PrintFunctionTable(const moveStatsType &stat) const -> string {
1100 if (stat.nfuncs == 0)
1101 return "";
1102
1103 stringstream ss;
1104 ss << setw(15) << left << "Function" << setw(6) << "Avg" << setw(6) << "Len"
1105 << setw(5) << "%" << setw(9) << "Count" << setw(9) << "Imp" << "\n";
1106
1107 for (int fr = 0; fr < static_cast<int>(MgType::SIZE); fr++) {
1108 for (int f = 0; f < stat.nfuncs; f++) {
1109 if (stat.list[f].findex != fr)
1110 continue;
1111
1112 ss << setw(15) << left << funcName[fr]
1113 << Moves::FullAverageString(stat.list[f]) << "\n";
1114 }
1115 }
1116 return ss.str();
1117}
1118
1119auto Moves::PrintTrickStats(ofstream &fout) const -> void {
1120 fout << "Overall statistics\n\n";

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected