MCPcopy Create free account
hub / github.com/Lovrom8/RSMods / DispatchCommand

Function DispatchCommand

DLL/Keybindings.cpp:227–241  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225 }
226
227 void DispatchCommand(WPARAM keyPressed, const std::map<std::string, ModCommand, std::less<>>& commands)
228 {
229 for (const auto& [key, value] : commands) {
230
231 if (keyPressed == Settings::GetKeyBind(key)) {
232 value.action();
233
234 if (!value.logMessage.empty()) {
235 LOG_INFO("Triggered: " << value.logMessage << std::endl);
236 }
237
238 return;
239 }
240 }
241 }
242
243 void InitializeCommands()
244 {

Callers 2

HandleKeyUpFunction · 0.85
HandleKeyDownFunction · 0.85

Calls 1

emptyMethod · 0.45

Tested by

no test coverage detected