About Game Controllers
【About Game Controllers】
Game Controller(GC),框架从iOS 7和OS X v10.9开始加入,用于便捷使用控制器(手柄). Once discovered, your game reads control inputs as part of its normal gameplay. There are three kinds of controllers available:
- A standard form-fitting controller: An iOS device sits inside the controller and the player can access both the iOS device’s screen and the controller elements.
- An extended form-fitting controller: An iOS device sits inside the controller and the player can access both the iOS device’s screen and the controller elements.
- An extended wireless controller: A controller that wirelessly connects to an iOS device or Mac.
在使用GC的时候,须把GC设为可选,即游戏没有手柄,也要能玩。GC的主要类是GCController,通过以下2方法来管理无线手柄的同步:

When designing your game, you can use one of the following strategies to read the profile’s input elements:
- In your game loop, poll the values of the elements you are interested in. Reading an input directly works best for elements that need to be read every frame, such as directional pads. (每帧读取)
- Register a block to be called when values change. You can choose to register a block for a single element or for all of the elements in the profile. Callbacks work best when you need to guarantee that a change is always detected. (设置回调读取)
- Periodically save a snapshot of the controller state. All of the controls are read simultaneously. Then, at a later point in the game, the controller data is processed.(保存完整profile数据,之后读取)
About Game Controllers的更多相关文章
- ASP.NET Core 中文文档 第四章 MVC(4.1)Controllers, Actions 和 Action Results
原文:Controllers, Actions, and Action Results 作者:Steve Smith 翻译:姚阿勇(Dr.Yao) 校对:许登洋(Seay) Action 和 acti ...
- 【转】Controllers and Routers in ASP.NET MVC 3
Controllers and Routers in ASP.NET MVC 3 ambilykk, 3 May 2011 CPOL 4.79 (23 votes) Rate: vote 1vote ...
- 控制器层(Controllers)
本章译者:@freewind 业务逻辑代码通常位于模型(model)层.客户端(比如浏览器)无法直接调用其中的代码,所以模型对象提供的功能,必须作为资源以URI方式暴露给外部. 客户端使用HTTP协议 ...
- Presenting view controllers on detached view controllers is discouraged <CallViewController: 0x14676e240>.
今天在优化app时,发现程序出现这种警告:“ Presenting view controllers on detached view controllers is discouraged <C ...
- [译]在AngularJS中何时应该使用Directives,Controllers或者Service
原文: http://kirkbushell.me/when-to-use-directives-controllers-or-services-in-angular/ Services Servic ...
- How to Create Mixed Reality Videos for the Vive - with Two Controllers
http://secondreality.co.uk/blog/how-to-create-mixed-reality-videos-for-the-vive-with-two-controllers ...
- 玩转单元测试之Testing Spring MVC Controllers
玩转单元测试之 Testing Spring MVC Controllers 转载注明出处:http://www.cnblogs.com/wade-xu/p/4311657.html The Spri ...
- 就是这么简单(续)!使用 RestAssuredMockMvc 测试 Spring MVC Controllers
就是这么简单(续)!使用 RestAssuredMockMvc 测试 Spring MVC Controllers 转载注明出处:http://www.cnblogs.com/wade-xu/p/43 ...
- 更轻量的 View Controllers
iew controllers 通常是 iOS 项目中最大的文件,并且它们包含了许多不必要的代码.所以 View controllers 中的代码几乎总是复用率最低的.我们将会看到给 view con ...
- 【IOS笔记】Resource Management in View Controllers
Resource Management in View Controllers 视图控制器的资源管理 View controllers are an essential part of managin ...
随机推荐
- cocos2dx Scene,Layer,Sprite的理解
layer,scene,sprite的默认锚点都是0.5,0.5 三者都继承自Node节点,暂时没看出有什么区别,或者下面的话是对的吧. 在cocos2d-x中,一个应用可以有多个scene,但任何时 ...
- 记 TP-Link 路由器的 WDS 设置
记 TP-Link 路由器的 WDS 设置 有一台旧的 TP-Link 路由器,是以前朋友送的,外壳看起来还不错,也挺新的. 本来已经有一台极路由了,看到信号还是不够好,所以想使用 TP-Link 的 ...
- Firefox渗透插件—Web渗透必备工具
1:Firebug Firefox的 五星级强力推荐插件之一,不许要多解释 2:User Agent Switcher 改变客户端的User Agent的一款插件 3:Hackbar 攻城师们的必备工 ...
- Docker中配置国内镜像
1. 为什么要为docker配置国内镜像 在正常情况下,docker有一个默认连接的国外官方镜像,在国外的网友访问该官方镜像自然不成问题,但是国内毕竟不是国外,由于国情不同,中国的网络访问国外官方 ...
- ubuntu 16.04安装HUSTOJ过程
一.背景介绍: 因为工作需要,想在学校搭建一个OJ平台用于程序测试与评价.于是需要搭建oJ,由于之前都是在云端服务器搭建系统,没有在实际服务器平台搭建过,所以遇到不少坑,都靠自己来填补.故而写下此教程 ...
- erlang单独配置文件
一种是erl启动的时候加参数 doudizhu.config [ {doudizhu,[ {listen_port, }, {node_caller_prefix,"ruby"}, ...
- Fragment 横竖屏切换问题
转自:http://my.oschina.net/u/614511/blog/76444 在默认情况下当发生横竖屏切换时,当前Activity中的fragment都会通过Fragment.instan ...
- 常用数据结构的功能及复杂度总结(OI)
不定长数组 维护一个序列 在末尾插入/删除均摊O(1) 任意位置插入O(n) 指定位置查询/修改O(1) 空间O(n) 链表 维护一个序列 定位到第i个位置O(n) 在任意位置(已定位到该位置)插入/ ...
- linux中强大的screen命令
今天发现了一个“宝贝”,就是Linux的screen命令,对于远程登录来说,不仅提供了类似于nohup的功能,而且提供了我非常喜欢的“多个桌面”的功能. 平常开一个putty远程登录,经常需要在两个程 ...
- Spring batch学习 持久化表结构详解(2)
#接上一篇 这一篇讲一下持久化需要表 batch_job_execution, batch_job_execution_context, batch_job_execution_params, bat ...