How do i make spring work good?

I jump onto spring and it works good, but i walk into it and it change velocity multiple times. I tried adding a wait 100ms block, but it added weird delay, and didnt even fix problem?!?!? Is there a way i could fix this without adding weird delay?

2 Likes

it’'s because the duck is constantly overlapping the sprite, also you shouldn’t use blocks like “change”, instead it’s better to use “set” since change will cause the duck to go up, but if it happens again, then it will add up with the previous block, and over and over like acceleration, set only sets the velocity to whatever you put it, and will not go up, only with the number you set it to

hope this helps

2 Likes

Instead of changing the sprite’s velocity, set its velocity so it moves up at a consistent speed.

2 Likes

make sure the character sprite has a set ay velocity not velocity

2 Likes

Use Set velocity instead of Change velocity, that way it sends you at the same speed no matter what and the double change won’t be an issue.

2 Likes

Use a set instead of a change, this way velocity is always the same when coming off the spring rather than adding more depending how long the overlap is:

1 Like

I’d say you would want it to be “set velocity” rather than “change velocity”, allows for more consistent movement.

1 Like

thanks everyone!

How would set ay help?

my problem was that the velocity wasnt the same everytime so the set one works because instead of changing the vy, (which could be nearly doubled by also jumping), it *sets* the value so its always the same height.

1 Like