How do I fix this MoveTo issue?

0 favourites
  • 4 posts
  • I'm having trouble figuring out the "not moving" part of the moveTo function. Here's the code:

    I just want the cow sprite to move to a point, then change its animation, but the "not moving" condition is never met. The cow does stop moving along the X axis, but the animation doesn't change. I've also tried checking every tick if the cow is moving (also tried checking if the speed is zero), but that doesn't work, either.

    Any help would be appreciated, thanks.

    Tagged:

  • You may need something like a 'wait' command before the switch to 'idle' animation. Or alternatively, you could just make the idle switching a completely separate event.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You can not pick a newly created object like that. Not until the next top level event.

    You can pick it by UID, or Pick Last Created Cow1

    but because the new instance is not fully created yet, you can't pick it by checking if it is moving or not.

  • Thanks SK. Allan - thanks, that explains what I was doing wrong, and now I've fixed it. Much appreciated :)

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)