- Home /
How to get ball and chain effect like in SkullChainz?
https://chaoclypse.itch.io/skullchainz
I've been searching many forum posts and trying many ways to work with Unity's 2D physics engine but I just can't get an effect similar to the one in the game above, with a moving character and a swinging ball off of it. I've tried working with 2d hinge joints but nothing I do seems to provide the desirable effect. If anyone knows how to accomplish this, any help would be greatly appreciated!
Answer by Chaoclypse · Oct 24, 2017 at 01:37 AM
Hey, I'll type out a longer answer later once I get back from school (my laptop with the source code is back home). I'm going off memory right now, so I may be way off, but try it out and let me know.
Basically, if I remember right, I did not use hinge joints. It has a spring effect that made it very hard to use properly.
Instead, I used distance joints. In addition, I modified the linear and angular drag of the rigidbodies so that they wouldn't come to a halt so quickly.
Oh, and optionally add a force to the segments of the rope in addition to using rigidbody2D's moveposition on the origin object to make it look more natural!
But yeah, I'll go back and check later. Again, I may be way off, haha.
Sorry for the late reply, been a bit busy with school lately. Thank you for the answer btw, got me a lot closer to the desired affect! I'm still having one issue though that I'm wondering how you got to implement in this mechanic. When I move the character, I can get the ball of course to basically dash back, but it doesn't get the violent, erratic style movements present in Skullchainz, ins$$anonymous$$d it follows a much more circular, floaty movement. Any idea on how I can resolve this?
That sounds like a problem with drag! Try modifying both of the drag attributes, and upping the force. This will allow your objects to be swung in a much more forceful manner while also bringing them to a halt faster.
Your answer
Follow this Question
Related Questions
Firing projectiles on the XZ Plane 2 Answers
Problem with unity ads 0 Answers
unity ads after google play publishing ?? 0 Answers
WebGL compiler errors 0 Answers
problem with button touch zone 0 Answers