Changing Animations

0 favourites
From the Asset Store
Simplistic hyper-casual game with nature elements. Tap to switch between the 4 elements and reach a better score.
  • "To prevent the player standing up inside a wall do something like:

    If the player is crawling and down is not pressed then

       change the player size to (39,126)

       if the player is not overlapping wall at offset 0,-1 then

          stand up... set animations etc..

       else

          set size back to (39,126) + stay crouching"

    After spending many hours breaking my capx, I haven't been able to get this to work either. <img src="smileys/smiley5.gif" border="0" align="middle">

    It was kinda tricky. You have to make sure the player can't jump while crouching, crouch while flying, fly while crawling, etc etc...

    I think this covers everything:

    animationTest3.capx

  • Wow! Thanks.

    I didn't think to separate the animations from the player object size. Also, thanks for the heads up on instance variables. I tried doing something similar (vaguely) with global variables, but it never worked.

  • > I've searched around a bit but haven't been able to find an expression to set height or width to a percentage of their original. Any takers?

    I believe the only way it's to use a math formula.

    Dividing by 100 will give you 1% of the original value, multiplying that value by say 50, will give you 50% of the original value.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • tl;dr all answers.

    Did you fix the Crawl and Stuck walking bug? <img src="smileys/smiley1.gif" border="0" align="middle" />

  • Yes. The animation now works as I intended.

    See Ramones' post from July 6, 2012 - 3:48 pm for the capx.

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