Skip to content

Commit

Permalink
another fix for lua key events
Browse files Browse the repository at this point in the history
  • Loading branch information
jacob1 committed Jul 17, 2016
1 parent b8cdf4a commit 8a0496e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lua/LegacyLuaAPI.cpp
Expand Up @@ -457,7 +457,7 @@ int luacon_keyevent(int key, Uint16 character, int modifier, int event)
for (int i = 1; i <= len && kycontinue; i++)
{
lua_rawgeti(l, -1, i);
if ((modifier & KEY_MOD_CONTROL) && (character < ' ' || character > '~'))
if ((modifier & KEY_MOD_CONTROL) && (character < ' ' || character > '~') && key < 256)
lua_pushlstring(l, (const char*)&key, 1);
else
lua_pushlstring(l, (const char*)&character, 1);
Expand Down

0 comments on commit 8a0496e

Please sign in to comment.