在做rpg类游戏的过程中,经常遇到要判断周围怪物相对自身的方位
1.判断目标在自己的前后方位可以使用下面的方法:
Vector3.Dot(transform.forward, target.position)
返回值为正时,目标在自己的前方,反之在自己的后方
2.判断目标在机子的左右方位可以使用下面的方法:
Vector3.Cross(tra...
分类:
其他好文 时间:
2014-08-01 16:10:11
阅读次数:
224
题目:Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. The same re....
分类:
编程语言 时间:
2014-08-01 10:43:21
阅读次数:
266
题目还原
Two Sum
Given an array of integers, find two numbers such that they add up to a specific target number.
The function twoSum should return indices of the two numbers such that they add up t...
分类:
其他好文 时间:
2014-08-01 02:25:11
阅读次数:
391
Problem Description:
Given an array of integers, find two numbers such that they add up to a specific target number.
The function twoSum should return indices of the two numbers such that they...
分类:
其他好文 时间:
2014-07-31 20:48:17
阅读次数:
215
今天遇到了一个很恶心的问题。。。htc某些机器的menu键是在屏幕里的,可以由系统控制显示和隐藏。今天遇到了一个问题,有两个应用,一个运行后显示menu键,另一个不显示。。。找了好一会儿,发现是android:targetSdkVersion="18"的问题最终sdk build version 1...
分类:
移动开发 时间:
2014-07-31 20:29:37
阅读次数:
231
CSS3 :target伪类用来改变页面中锚链接URL所指向的ID样式,例如你要改变描链接指向#tab的元素字体颜色为蓝色,哪么你可以这样写成#tab:target {color:blue}浏览器支持:不支持IE8及以下的IE版本,IE9支持这个属性,其它非IE内核浏览器如:Firefox、Chro...
分类:
Web程序 时间:
2014-07-31 19:38:07
阅读次数:
205
委托回调静态方法和实例方法有何区别 当委托绑定静态方法时,内部的对象成员变量_target会被设置成null 当委托绑定实例方法是,_target将会设置成指向该实例方法所属的一个实例对象 当委托被执行时,该对象实例将会用来调用实例方法 1 class DelegateReturn 2 ...
分类:
其他好文 时间:
2014-07-31 16:46:17
阅读次数:
210
1、将程序导入到工作空间,修改target=android-XX为本地android SDK版本。 2、在项目中点击右键选择Properties->Android Library,添加ANDROID-BOOTSTRAP开源项目。 3、拷贝开源包中的fontawesome-webfont.tt...
分类:
移动开发 时间:
2014-07-31 16:29:26
阅读次数:
417
为了减少IT运维成本,管理员通常不希望手动安装ConfigurationManager客户端,这时可以利用强大的组策略自动部署ConfigurationManager客户端,不需要人为干预。1.登陆DC服务器,点击工具,点击组策略管理2.创建“部署ConfigurationManager客户端”GPO3.右键GPO,点击编辑4.点击..
分类:
其他好文 时间:
2014-07-31 03:10:16
阅读次数:
320
步骤一:导入JniHelper.h头文件,#if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID)
#include "JniHelper.h"
#endif;此时会遇到JniHelper.h头文件无法找到的问题,需要添加附加包含目录即可解决问题。具体操作步骤如下:右击项目---->c/c++---->常规---->附加包含目录---->添加JniHelper...
分类:
其他好文 时间:
2014-07-30 20:57:34
阅读次数:
385