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 ...
随机推荐
- java编程排序之内置引用类型的排序规则实现,和自定义规则实现+冒泡排序运用
第一种排序:[冒泡排序]基本数据类型的排序. [1]最简易的冒泡排序.效率低.因为比较的次数和趟数最多. /** * 最原始的冒泡排序. * 效率低. * 因为趟数和次数最多.都是按最大化的循环次数进 ...
- Struts2自定义标签2自定义一个按班级id查询出该班级下的学生,存放进值栈,并遍历出来。
Struts2自定义标签的流程概念: (1)需要两个类:标签类(继承相应的tag类),基本类(继承Component).标签类专门负责从客户端取得用户输入的一些属性,这个普通的jsp自定义标签一样,取 ...
- 在服务器上运行db:seed数据填充时,出错的问题解决
在服务器上运行db:seed数据填充时,出错的问题解决 运行composer dump-autoload
- hasura graphql 角色访问控制
目前从官方文档以及测试可以看出不加任何header的请求访问的是所有的数据,对于具有访问 控制的请求需要添加请求头,实际生产的使用需要集合web hook 的实现访问控制. 参考配置 访问请求 目前数 ...
- 【ZedGraph】右键菜单和鼠标滚轴的移动缩放等功能的启用和禁用 (转)
通过[ZedGraph]控件属性修改: 1.禁用右键菜单: IsShowContextMenu = false; 2.禁用鼠标滚轴移动: IsEnableHPan = false; //禁止横向移动; ...
- Kafka问题排查(消费者自动关闭)
问题描述: 在消费端能够正常消费到Kafka数据并成功生产到producer topic 中,当将kafka的一台机器关机之后,正常情况下应该是 消费端是不受影响的.因为有还有两 ...
- Phonegap 通信原理
下图为JavaScript调用本地代码的通信过程 Phonegap的核心API都是基于插件的,这些JavaScript API都会调用cordova.exec() 函数来完成操作.cordova.ex ...
- spring boot打包部署到Linux环境
打包部署说白了就两步:打包.部署.废话不多说,直接拿spring boot自动生成的项目骨架,再添加一个文件用来演示: package com.crocodile.springboot; import ...
- mysql 查询所有父级名称
SELECT T2.id, T2.name FROM ( SELECT @r AS _id, ,,@stop) as stop, (SELECT @r := p_id FROM goods_class ...
- python3调用阿里云短信服务
#!/usr/bin/env python#-*- coding:utf-8 -*-#Author:lzd import uuidimport datetimeimport hmacimport ba ...