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

Method OnUpdate

library/PluginManager.cpp:1047–1058  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1045}
1046
1047void PluginManager::OnUpdate(color_ostream &out)
1048{
1049 auto &core = Core::getInstance();
1050 auto &counters = core.perf_counters;
1051 for (auto it = begin(); it != end(); ++it) {
1052 auto & plugin_name = it->first;
1053 auto & plugin = it->second;
1054 uint32_t start_ms = core.p->getTickCount();
1055 plugin->on_update(out);
1056 counters.incCounter(counters.update_per_plugin[plugin_name], start_ms);
1057 }
1058}
1059
1060void PluginManager::OnStateChange(color_ostream &out, state_change_event event)
1061{

Callers 1

onUpdateMethod · 0.80

Calls 4

beginFunction · 0.85
getTickCountMethod · 0.80
incCounterMethod · 0.80
on_updateMethod · 0.45

Tested by

no test coverage detected