testing version of LuaBIOS and OpenOS

people were having issues getting them to work so now we promote consistency
This commit is contained in:
2025-06-28 20:41:49 +02:00
parent 8210e20939
commit 687cfebd00
182 changed files with 14016 additions and 1 deletions

View File

@@ -0,0 +1,12 @@
local event = require("event")
local keyboard = require("keyboard")
local function onKeyChange(ev, _, char, code)
-- nil might be slightly more mem friendly during runtime
-- and `or nil` appears to only cost 30 bytes
keyboard.pressedChars[char] = ev == "key_down" or nil
keyboard.pressedCodes[code] = ev == "key_down" or nil
end
event.listen("key_down", onKeyChange)
event.listen("key_up", onKeyChange)