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

Summary

We have learned how to deal with input from users in several ways and how to make it transparent for the GameEngine.

To get a proper visual feedback from the controller, we created a Player game object that updates its position based on the values from the InputController. We also learned how to add and remove game objects to and from the GameEngine while playing.

We created a very basic keypad that later evolved into a virtual joystick. We also learned how to handle external controllers.

At this point, our game has a spaceship that moves along the screen and fires bullets. It can be controlled using a virtual joystick or a gamepad, independently.

The current implementation does lag occasionally and we have barely started drawing objects on the screen. It is time to fix this. Next stop: improve the rendering by drawing directly on the view instead of relying on positioning views on the screen.

主站蜘蛛池模板: 稻城县| 娱乐| 正安县| 洪洞县| 特克斯县| 雷州市| 黄陵县| 扶余县| 山阴县| 楚雄市| 霍林郭勒市| 龙井市| 革吉县| 临城县| 石城县| 新兴县| 惠水县| 任丘市| 巴南区| 柯坪县| 伊宁市| 洞口县| 文山县| 凯里市| 萨迦县| 大荔县| 平武县| 巴里| 渭源县| 武隆县| 宁强县| 小金县| 平果县| 滁州市| 静宁县| 田东县| 开阳县| 南丹县| 建德市| 双江| 宁乡县|