Spring Behavior Unity 2d Scene

Hello everyone…

I am making game based on physics. Like https://play.google.com/store/apps/details?id=com.rovio.amazingalex.trial&hl=en .

Here i want to make spring tool like any object fall down on the spring then spring type force to be added and spring animation i want to create.

I have seen video of spring joint. But still i am confused about how to add spring animation and spring force?

All these i want to do using sprite as my scene is 2d.

Please guys make my doubt clear and help me to make this spring behavior.

30045-spring.png

Have you read the Unity documentation manual on Spring Joint and see if it solves your purpose …

It can be attached to a game object via add components->physics in inspector.
See if you can get that to work according to your needs.

There are two way you can do same task. Using spring joint create spring like complex object. That result in real behavior as per physics is related.

Other approach is some what fake one but it is easy to implement.
In this way apply manual force on collision detection and play spring animation that you create from your designer.