2011-03-19 10:59:01 +08:00
|
|
|
/****************************************************************************
|
|
|
|
Copyright (c) 2010-2011 cocos2d-x.org
|
|
|
|
Copyright (c) 2008-2009 Jason Booth
|
|
|
|
|
|
|
|
http://www.cocos2d-x.org
|
|
|
|
|
|
|
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
|
|
of this software and associated documentation files (the "Software"), to deal
|
|
|
|
in the Software without restriction, including without limitation the rights
|
|
|
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
|
|
copies of the Software, and to permit persons to whom the Software is
|
|
|
|
furnished to do so, subject to the following conditions:
|
|
|
|
|
|
|
|
The above copyright notice and this permission notice shall be included in
|
|
|
|
all copies or substantial portions of the Software.
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
|
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
|
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
|
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
|
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
|
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
|
|
THE SOFTWARE.
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#ifndef __ACTION_CCEASE_ACTION_H__
|
|
|
|
#define __ACTION_CCEASE_ACTION_H__
|
|
|
|
|
|
|
|
#include "CCActionInterval.h"
|
|
|
|
|
|
|
|
namespace cocos2d {
|
|
|
|
|
|
|
|
class CCObject;
|
|
|
|
class CCZone;
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Base class for Easing actions
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCActionEase : public CCActionInterval
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual ~CCActionEase(void);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
/** initializes the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
bool initWithAction(CCActionInterval *pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-28 12:02:10 +08:00
|
|
|
virtual void startWithTarget(CCNode *pTarget);
|
2010-08-10 14:02:13 +08:00
|
|
|
virtual void stop(void);
|
2011-03-19 10:59:01 +08:00
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCActionEase* actionWithAction(CCActionInterval *pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
protected:
|
2010-12-22 15:43:54 +08:00
|
|
|
CCActionInterval *m_pOther;
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Base class for Easing actions with rate parameters
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseRateAction : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual ~CCEaseRateAction(void);
|
|
|
|
|
2010-09-28 16:18:05 +08:00
|
|
|
/** set rate value for the actions */
|
|
|
|
inline void setRate(float rate) { m_fRate = rate; }
|
|
|
|
/** get rate value for the actions */
|
|
|
|
inline float getRate(void) { return m_fRate; }
|
|
|
|
|
2010-08-10 14:02:13 +08:00
|
|
|
/** Initializes the action with the inner action and the rate parameter */
|
2010-12-22 15:43:54 +08:00
|
|
|
bool initWithAction(CCActionInterval *pAction, float fRate);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
public:
|
|
|
|
/** Creates the action with the inner action and the rate parameter */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseRateAction* actionWithAction(CCActionInterval* pAction, float fRate);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
protected:
|
|
|
|
float m_fRate;
|
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseIn action with a rate
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseIn : public CCEaseRateAction
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the rate parameter */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseIn* actionWithAction(CCActionInterval* pAction, float fRate);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseOut action with a rate
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseOut : public CCEaseRateAction
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the rate parameter */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseOut* actionWithAction(CCActionInterval* pAction, float fRate);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseInOut action with a rate
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseInOut : public CCEaseRateAction
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the rate parameter */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseInOut* actionWithAction(CCActionInterval* pAction, float fRate);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEase Exponential In
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseExponentialIn : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseExponentialIn* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Exponential Out
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseExponentialOut : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseExponentialOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Exponential InOut
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseExponentialInOut : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseExponentialInOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Sine In
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseSineIn : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseSineIn* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Sine Out
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseSineOut : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseSineOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Sine InOut
|
2010-08-10 14:02:13 +08:00
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseSineInOut : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseSineInOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Elastic abstract class
|
2010-08-10 14:02:13 +08:00
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseElastic : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** get period of the wave in radians. default is 0.3 */
|
2010-08-10 14:02:13 +08:00
|
|
|
inline float getPeriod(void) { return m_fPeriod; }
|
2010-09-28 16:18:05 +08:00
|
|
|
/** set period of the wave in radians. */
|
2010-08-10 14:02:13 +08:00
|
|
|
inline void setPeriod(float fPeriod) { m_fPeriod = fPeriod; }
|
|
|
|
|
|
|
|
/** Initializes the action with the inner action and the period in radians (default is 0.3) */
|
2010-12-22 15:43:54 +08:00
|
|
|
bool initWithAction(CCActionInterval *pAction, float fPeriod);
|
2010-09-28 16:18:05 +08:00
|
|
|
/** initializes the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
bool initWithAction(CCActionInterval *pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElastic* actionWithAction(CCActionInterval *pAction);
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the period in radians (default is 0.3) */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElastic* actionWithAction(CCActionInterval *pAction, float fPeriod);
|
2010-08-10 14:02:13 +08:00
|
|
|
|
|
|
|
protected:
|
|
|
|
float m_fPeriod;
|
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Elastic In action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseElasticIn : public CCEaseElastic
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElasticIn* actionWithAction(CCActionInterval *pAction);
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the period in radians (default is 0.3) */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElasticIn* actionWithAction(CCActionInterval *pAction, float fPeriod);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Elastic Out action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseElasticOut : public CCEaseElastic
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElasticOut* actionWithAction(CCActionInterval *pAction);
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the period in radians (default is 0.3) */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElasticOut* actionWithAction(CCActionInterval *pAction, float fPeriod);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief Ease Elastic InOut action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseElasticInOut : public CCEaseElastic
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
|
|
|
public:
|
2010-09-28 16:18:05 +08:00
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElasticInOut* actionWithAction(CCActionInterval *pAction);
|
2010-09-28 16:18:05 +08:00
|
|
|
/** Creates the action with the inner action and the period in radians (default is 0.3) */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseElasticInOut* actionWithAction(CCActionInterval *pAction, float fPeriod);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseBounce abstract class.
|
2010-08-10 14:02:13 +08:00
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBounce : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
ccTime bounceTime(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBounce* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseBounceIn action.
|
|
|
|
@warning This action doesn't use a bijective function. Actions like Sequence might have an unexpected result when used with this action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBounceIn : public CCEaseBounce
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBounceIn* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief EaseBounceOut action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBounceOut : public CCEaseBounce
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBounceOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseBounceInOut action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBounceInOut : public CCEaseBounce
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBounceInOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseBackIn action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBackIn : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBackIn* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseBackOut action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBackOut : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2010-12-22 15:43:54 +08:00
|
|
|
virtual CCActionInterval* reverse(void);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBackOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
2010-09-28 18:27:33 +08:00
|
|
|
/**
|
|
|
|
@brief CCEaseBackInOut action.
|
2010-08-10 14:02:13 +08:00
|
|
|
@warning This action doesn't use a bijective fucntion. Actions like Sequence might have an unexpected result when used with this action.
|
|
|
|
@since v0.8.2
|
|
|
|
*/
|
2011-03-07 17:11:57 +08:00
|
|
|
class CC_DLL CCEaseBackInOut : public CCActionEase
|
2010-08-10 14:02:13 +08:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void update(ccTime time);
|
2011-03-07 17:11:57 +08:00
|
|
|
virtual CCObject* copyWithZone(CCZone* pZone);
|
2010-08-25 18:31:55 +08:00
|
|
|
|
2011-03-19 10:59:01 +08:00
|
|
|
public:
|
|
|
|
/** creates the action */
|
2010-12-22 15:43:54 +08:00
|
|
|
static CCEaseBackInOut* actionWithAction(CCActionInterval* pAction);
|
2010-08-10 14:02:13 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // __ACTION_CCEASE_ACTION_H__
|
|
|
|
|
|
|
|
}
|