您的位置:首页 > 移动开发 > Cocos引擎

cocos2d-x节点(CCActionInterval.h)API

2013-12-03 15:07 441 查看
本文来自http://blog.csdn.net/runaying ,引用必须注明出处!


cocos2d-x节点(CCActionInterval.h)API

温馨提醒:为了大家能更好学习,强烈推荐大家看看本人的这篇博客 Cocos2d-X权威指南笔记

scene 过渡
///cocos2d-x-3.0alpha0/cocos2dx/layers_scenes_transitions_nodes
//scene 过渡

#ifndef __CCPAGE_TURN_TRANSITION_H__
#define __CCPAGE_TURN_TRANSITION_H__

#include "CCTransition.h"

NS_CC_BEGIN

/**
* @addtogroup transition
* @{
*/

/**
@brief A transition which peels back the bottom right hand corner of a scene
to transition to the scene beneath it simulating a page turn.

This uses a 3DAction so it's strongly recommended that depth buffering
is turned on in Director using:

Director::getInstance()->setDepthBufferFormat(kDepthBuffer16);

@since v0.8.2
*/
class CC_DLL TransitionPageTurn : public TransitionScene
{
public:
/**
* 使用 duration、传入的scene 创建一个 scene.
* 如果返回 true 传入效果会出现反转
* scene 从左覆盖传入 scene.
*/
static TransitionPageTurn* create(float t,Scene* scene,bool backwards);
/**
* @js ctor
*/
TransitionPageTurn();
/**
* @js NA
* @lua NA
*/
virtual ~TransitionPageTurn();

/**
* 使用 duration、传入的scene 创建一个 scene.
* 如果返回 true 传入效果会出现反转
* scene 从左覆盖传入 scene.
*/
bool initWithDuration(float t,Scene* scene,bool backwards);

ActionInterval* actionWithSize(const Size& vector);

//
// Overrides
//
virtual void onEnter() override;

protected:
virtual void sceneOrder() override;

protected:
bool    _back;

};

// end of transition group
/// @}

NS_CC_END

#endif // __CCPAGE_TURN_TRANSITION_H__
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: