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

Function QueryKeyToDo

engine/Poseidon/Input/InputSubsystem.cpp:109–125  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

107}
108
109static bool QueryKeyToDo(Input& in, int dik, bool reset, bool checkFocus)
110{
111 if (checkFocus && in.gameFocusLost > 0)
112 return false;
113#if _ENABLE_CHEATS
114 if (in.keyboard.cheat1 || in.keyboard.cheat2)
115 return false;
116#endif
117 if (in.keyboard.awaitCheat)
118 return false;
119 if (dik < 0 || dik >= SDL_SCANCODE_COUNT)
120 return false;
121 bool ret = in.keyboard.keysToDo[dik];
122 if (reset)
123 in.keyboard.keysToDo[dik] = false;
124 return ret;
125}
126
127static bool QueryDoubleTapKeyToDo(Input& in, int dik, bool reset, bool checkFocus)
128{

Callers 3

QueryActionToDoFunction · 0.85
QueryProfileCodeToDoFunction · 0.85
GetKeyToDoMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected