Weird movements using interpolate when doing simple movements

revoltandreverbrevoltandreverb Member Posts: 159
edited February 2014 in Working with GS (Mac)
Hi Guys.

1. When my game begins I want my actor to start at selfposx 20, since the actor is 40px wide.
2. I'm trying to move the actor to a specific location when the right arrow key is pressed repeatedly e.g. press it once it goes to selfpos 60, press it again it goes to selfpos 100, press it again it goes back to selfpos 20.

I tried "move to" but the actor was floating off the screen. I came across a forum post that said to use interpolate instead. I'm using interpolate now, but sometimes the actor stays in one place or moves the opposite direction

Also as far as I can see using 0 for the interpolate duration is not a very smooth animation, it's very jurky, a value of 1 is way to slow. "move to" was perfect with a value of 500.

3. Any way to make the animation not so jurky?

4. How can I make a rule so that when the key is held in, the actor won't move repeatedly to the next location specified, only if you press the key and lift your finger and press again i.e. pressing the key longer than a split second shouldn't make a difference and shouldn't make the actor move.

This is my logic http://grab.by/ux3u

Thanks!
revoltandreverb

Comments

  • SocksSocks London, UK.Member Posts: 12,822
    Also as far as I can see using 0 for the interpolate duration is not a very smooth animation, it's very jurky, a value of 1 is way to slow.
    If 0 is too fast and 1 is too slow, try a value inbetween.
  • revoltandreverbrevoltandreverb Member Posts: 159
    thanks Socks, I tried that but when using 0.3 for example it resets to 0. im not too worried about animation for now, just thought I'd putt it out there, any ideas on the other 3 questions? thanks!
  • revoltandreverbrevoltandreverb Member Posts: 159
    I'm new to game salad. Are these question more of a paid support type questions? Is there a place you guys can point me to with some more detailed documentation about move to and interpolate?

    Thanks!
Sign In or Register to comment.