Skip to content

Commit 58809c8

Browse files
committed
fix assigning keys for keybinds
1 parent 47d85a5 commit 58809c8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

sources/libengine/keybinds.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,7 @@ namespace cage
312312

313313
bool guiAssign(const GenericInput &in)
314314
{
315+
CAGE_ASSERT(assigningIndex < matchers.size());
315316
if (in.has<input::WindowFocusLose>())
316317
{
317318
cancel();
@@ -337,6 +338,8 @@ namespace cage
337338
}
338339
if (in.has<input::MouseDoublePress>() || in.has<input::MouseRelease>() || in.has<input::MouseMove>() || in.has<input::MouseRelativeMove>())
339340
return false;
341+
if (in.has<input::EngineTick>() || in.has<input::GameTick>())
342+
return false;
340343
override(assigningIndex, in);
341344
cancel();
342345
return true;

0 commit comments

Comments
 (0)