CCOrbitCamera
Cocos2d-x提供了一中根据球面坐标轨迹旋转的方式CCOrbitCamera
CC_DEPRECATED_ATTRIBUTE static CCOrbitCamera* actionWithDuration(float t, float radius, float deltaRadius, float angleZ, float deltaAngleZ, float angleX, float deltaAngleX);
参数分别为旋转的时间,起始半径,半径差,起始z角,旋转z角差,起始x角,旋转x角差
CCActionInterval* orbit1 = CCOrbitCamera::create(,, , , , , );
CCFiniteTimeAction* action1 = CCSequence::create(
orbit1,
orbit1->reverse(),
NULL); CCActionInterval* orbit2 = CCOrbitCamera::create(,, , , , -, );
CCFiniteTimeAction* action2 = CCSequence::create(
orbit2,
orbit2->reverse(),
NULL); CCActionInterval* orbit3 = CCOrbitCamera::create(,, , , , , );
CCFiniteTimeAction* action3 = CCSequence::create(
orbit3,
orbit3->reverse(),
NULL); m_kathia->runAction(CCRepeatForever::create((CCActionInterval*)action1));
m_tamara->runAction(CCRepeatForever::create((CCActionInterval*)action2));
m_grossini->runAction(CCRepeatForever::create((CCActionInterval*)action3));
CCOrbitCamera的更多相关文章
- CCOrbitCamera卡牌翻转效果
static CCOrbitCamera* create(float t, float radius, float deltaRadius, float angleZ, float deltaAngl ...
- cocos2dx 利用CCOrbitCamera实现扑克牌翻牌效果
[cpp] view plaincopy #include "HelloWorldScene.h" #include "SimpleAudioEngine.h" ...
- cocos2d-x中使用CCOrbitCamera做水平翻转
项目中需要用到水平翻转效果,这里偷懒了- 首先翻转,它只是转到了180度,多了就觉得很奇怪了. 所以这里设定就是先从0 ~ 90度,然后再从270 ~ 360,90 – 270 视觉上是感觉不到变 ...
- cocos2d-x--精灵反转效果--CCOrbitCamera
CCSprite* pSprite = CCSprite::spriteWithFile("grossini.png"); pSprite->setPosition(ccp( ...
- cocos2dx常见的46中+22中动作详解
cocos2dx常见的46中+22中动作详解 分类: iOS2013-10-16 00:44 1429人阅读 评论(0) 收藏 举报 bool HelloWorld::init(){ ///// ...
- coco2dx实现翻拍效果
昨天吃饭看见同事演示他做的翻牌效果,感觉不错,我心血来潮也来搞个,很简单直接上代码. class FlipCard : public CCNode { public: CREATE_FUNC(Flip ...
- 转载cocos2dx的各种动作用法
以下内容来源于:http://www.cnblogs.com/linux-ios/archive/2013/04/06/3001946.html 转载时请保留以上链接. bool HelloWorld ...
- cc.Sprite
Classcc.Sprite Defined in: CCSprite.js Extends cc.NodeRGBA Class Summary Constructor Attributes Cons ...
- cocos2d-x 仿真树叶飘落效果的实现
转自:http://blog.csdn.net/ufolr/article/details/7624851 最近项目中需要一个落叶的效果,本来想用粒子特效来实现,但是几经调试,虽然调出了落叶的效果,但 ...
随机推荐
- Excel实现二级菜单联动
项目中需要导入一个Excel模板需要实现二级联动,现记录如下: 首先看一下原始数据,原始信息在一张工作表,第一行是省市名称,下面的若干行为对应省市下面的地名和区名.需要在另外一张工作表中A列和B列建立 ...
- SQL用例集锦
SQL 语句分类 DDL - 数据定义语句 (CREATE,ALTER,DROP,DECLARE) DML - 数据操纵语句 (SELECT,DELETE,UPDATE,INSERT) DCL - 数 ...
- linux 网络设备驱动
linux 网络驱动 谨以此文纪念过往的岁月 一.前言在linux中网络驱动也是一个大头,如何去理解网络驱动是作为一个linux驱动工程师必备的技能.不过同样的设备,在不同人的手中会有不同的效果,其原 ...
- 如何在android模拟器中导入搜狗输入法?
1.下载输入法程序,如:sogouinput_android_1.6_sweb.apk 2.然后cmd进入sdk的tools(有的是platform-tools)目录,输入adb install C: ...
- javascript数组去重的4个方法(转)
原文地址:http://blog.csdn.net/chengxuyuan20100425/article/details/8497277 面试前端必须准备的一个问题:怎样去掉Javascript的A ...
- php stdClass 的使用
原文:http://www.php.cn/php-weizijiaocheng-371767.html ------------------------------------------------ ...
- [AngularJS] AngularJS 1.3 $scope.$watchGroup
$watchGroup can monitor an array or expression. We watch both email and password by using the same c ...
- angularjs中使用$scope.$watch监控对象模型的变化
如果对象模型发生变化时,可以使用$scope.$watch监控变化 <html ng-app="myApp"> <head> <title>an ...
- CAS lock-free
转:http://www.cnblogs.com/lucifer1982/archive/2009/04/08/1431992.html http://en.wikipedia.org/wiki/Co ...
- iOS 设置app语言中文,比如 copy中文,拍照按钮cancel 中文
iOS 设置app语言中文,比如 copy中文,拍照按钮cancel 中文 一:如何设置项目中文环境 targets--->Locatization native development reg ...