diff --git a/lib/controls.lua b/lib/controls.lua index f051fad..50de9ab 100644 --- a/lib/controls.lua +++ b/lib/controls.lua @@ -48,6 +48,13 @@ function controls:cache() end end +--- marks a control consumed for the current frame +--- the control will no longer be considered active +--- @param key string +function controls:consume(key) + currentKeys[key] = nil +end + --- check if a control is active --- @param key string function controls:isDown(key)