- Home /
A good way to attach a mechanical part to another object at runtime and let it rotate? Like an axle.
So I wasn't sure of the best way to word the title, so sorry about that.
Anyway, my situation is this. I need to make a system in my game where the player can look at anything, left click, and place a rotating part that I call a "Rotator". This allows players to then attach wheels or other parts to that rotator to make various contraptions. Think of Scrap Mechanic.
My problem is that I am having a hard time figuring out how to go about this. My main question is this;
Should I make everything custom or should I use something like a ConfigurableJoint for this system? And also what might be a good general method for attaching the rotator to the object you aim at so that it moves with it, but can still rotate freely on one axis like an axle.
It needs to be able to rotate freely on the forward axis, so if you attach a wheel, it rolls the wheel.
I am using C# for all scripting, I am open to any suggestions, and yes, I have looked through tons of posts on here and google, nothing found yet :P
So thanks in advance!
Your answer
Follow this Question
Related Questions
Distribute terrain in zones 3 Answers
Multiple Cars not working 1 Answer
How to make wheels turn more? 0 Answers
For loop C#? 2 Answers
C# WheelHit.force display wheel suspensions on meshes 0 Answers