示例#1
0
        public override CCFiniteTimeAction reverse()
        {
            ccBezierConfig _ccBezierConfig = new ccBezierConfig();

            _ccBezierConfig.endPosition    = CCPointExtension.ccpNeg(this.m_sConfig.endPosition);
            _ccBezierConfig.controlPoint_1 = CCPointExtension.ccpAdd(this.m_sConfig.controlPoint_2, CCPointExtension.ccpNeg(this.m_sConfig.endPosition));
            _ccBezierConfig.controlPoint_2 = CCPointExtension.ccpAdd(this.m_sConfig.controlPoint_1, CCPointExtension.ccpNeg(this.m_sConfig.endPosition));
            return(CCBezierBy.actionWithDuration(this.m_fDuration, _ccBezierConfig));
        }
示例#2
0
        public override CCFiniteTimeAction reverse()
        {
            ccBezierConfig r;

            r.endPosition    = CCPointExtension.ccpNeg(m_sConfig.endPosition);
            r.controlPoint_1 = CCPointExtension.ccpAdd(m_sConfig.controlPoint_2, CCPointExtension.ccpNeg(m_sConfig.endPosition));
            r.controlPoint_2 = CCPointExtension.ccpAdd(m_sConfig.controlPoint_1, CCPointExtension.ccpNeg(m_sConfig.endPosition));

            CCBezierBy action = CCBezierBy.actionWithDuration(m_fDuration, r);

            return(action);
        }