MCPcopy Create free account
hub / github.com/DFHack/dfhack / getPercentage

Function getPercentage

plugins/dwarfmonitor.cpp:101–105  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

99}
100
101static int getPercentage(const int n, const int d)
102{
103 return static_cast<int>(
104 static_cast<float>(n) / static_cast<float>(d) * 100.0);
105}
106
107static string getUnitName(df::unit * unit)
108{

Callers 3

populateDwarfColumnMethod · 0.85
populateFortColumnMethod · 0.85
getFortAverageMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected