Quantcast
Channel: Cocos Forums - Latest topics
Viewing all articles
Browse latest Browse all 17076

Cant clone an action in order to ease it

$
0
0

@cubby208 wrote:

I am trying to get the following code running

    Vec2 buffer = Vec2((width / 2) / 3.5, (height / 2) / 3.5);
    Vec2 b1 = Vec2(width / 5, height / 5);
Vec2 b2 = Vec2(width - buffer.x, height - buffer.y);

auto p1x = MoveBy::create(9, b1);
auto p2x = MoveBy::create(9, b2);
auto p1 = EaseInOut::create(p1x->clone());
auto p2 = EaseInOut::create(p2x->clone());
auto seq = Sequence::create(p1, p2, nullptr);
auto seqf = RepeatForever::create(seq->clone());
diagonal->runAction(seqf);
diagonal->setPosition(Vec2(width / 2, height / 2));

However the compiler simply states "no matching function for call to 'cocos2d::EaseInOUt::create(cocos2d::MoveBy*)'.

Posts: 10

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 17076

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>