Mouseover Animation issue - Animation doesnt work

0 favourites
  • 6 posts
From the Asset Store
Ninja char for your game! Make your own Shinobi game with this art.
  • Hi,

    Description:

    Create a "Cursor over object" event and set animation.

    Expected:

    When mouse is moved over the object, animation happens.

    When the mouse is moved away from object, animation should stop.

    Please note: Animation is not set in loop.

    What is happening:

    When mouse is moved over the object, animation is happening.

    But when mouse is moved away and again brought on the object animation doesnt happen.

    I have tried combinations with using Stop animation, using set current frame. But it doesn't work.

    Release: r66

    OS: Windows XP

    Browser: Chrome 15.x

    What is the correct way to do it?

    1. I am looking at playing an animation when mouse is over and object and when mouse is not over it, the animation should stop.

    2. When mouse goes back on it, the animation should continue from the last frame that was running.

  • Seems like what's happening is the animation is constantly (i.e. on every tick) started as long as the mouse is over it.

    In Construct Classic we had a "Trigger once" option, in C2 workarounds are necessary, it seems.

    Check out the example.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Okay Got it.

    1. I've used invert mouse event .. was looking for it in "add event". :)

    2. Still, what is the right way to

    "When mouse goes back on it, the animation should continue from the last frame that was running."?

  • Well, the animation seems to continue right where it left off.

    But if like, you say, yours doesn't loop it'll just go till the end and that's it.

  • True. It should go till end.

    But whenever I bring the mouse back on the object, shouldn't the animation start again from the beginning?

    My action says "set animation to <animation name> from beginning"

  • krish: then add an action "animation start" right under "set animation"

    Somebody : There is a system.Trigger once while true condition too in C2.

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