Как получить несколько одновременных входов с клавиатуры в Corona SDK? - PullRequest
0 голосов
/ 20 марта 2020
-- let's say you have an "app" (or "system", or whatever) class to hold this stuff
app = {}
-- then..
app.keyStates = {}
app.key = function(self, event)
  -- (could filter subset of keys, not shown here)
  self.keyStates[event.keyName] = (event.phase=="down")
end
Runtime:addEventListener("key", app)
...