Jump to content
Spriter Forums

Calling animations using Keyboard object.


Malakyas

Recommended Posts

Hi Malakyas,

 

This actually has nothing directly to do with Spriter, and everything to do with basic game-coding logic.

If you analyze that one event you have you'll see the problem.  What is it actually saying?  It's saying "every tick (60 or so times a second) IF the down arrow is being pressed, then play the animation from the beginning"

Clearly you'd never see anything but one frame of the first 60th of a second of the animation, so long as down arrow key is being pressed.

The solution? Add a condition to the event:

Is Down arrow key pressed down

AND is animation crouch NOT playing

 

THEN set animation to "crouch" and play from beginning

 

I hope this helps.

 

Cheers.
-Mike at BrashMonkey

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...