官术网_书友最值得收藏!

  • Lua Game Development Cookbook
  • Mário Ka?uba
  • 152字
  • 2021-07-16 13:23:08

Introduction

Event-driven design offers a cheap and efficient way to detect user input without the need to check for input device status in each frame. A na?ve approach to this is to query all input devices for changes in their state. There are many types of input devices such as keyboard, mouse, joystick, keypad controller, tablet, touch screen, and so on. LuaSDL relies on the library libSDL 1.2, which supports only basic input devices such as keyboard, mouse, and joystick. This version doesn't support the use of multiple devices of the same kind. This limitation has been removed with libSDL 2.x, which is used in LuaSDL 2. LuaSDL 2 is the successor of a former LuaSDL library and it's in the stage of early development at the time of writing. This chapter will cover the use of an older LuaSDL library, as the LuaSDL 2 interface is not so different.

主站蜘蛛池模板: 南靖县| 太康县| 武穴市| 柳江县| 莱阳市| 湘潭县| 平度市| 丹东市| 广灵县| 桃园县| 西宁市| 沾益县| 湘阴县| 阳城县| 雅江县| 永春县| 元谋县| 井冈山市| 清镇市| 九台市| 全州县| 深水埗区| 全州县| 嘉义县| 巴林左旗| 正阳县| 宜宾县| 河北省| 宜昌市| 栖霞市| 上栗县| 竹溪县| 潜山县| 河南省| 平乡县| 德清县| 桑植县| 寿宁县| 收藏| 黄龙县| 马尔康县|