25-03-2019, 10:09 PM
Has the API Docs been updated for softbody? I may be overlooking it or using an outdated link.
Before I write my own methods, I have a few questions:
I'm replacing my rigidbody with a softbody. Do these methods/fields or something equivalent exist for softbodies.
for setting mass: I was going to divide the total mass with the particle count and add that value to each particle.
for getting velocity: since each particle has a velocity, I was going to use the first particle as the velocity.
but does a single particle velocity represent the velocity of the entire softbody? Not sure this will work.
And Lastly - Since you have to initialize a softbody in the editor, It's not possible to create a softbody at runtime, right?
I'm in the dark and guessing without the softbody API documentation (using the source helps, but creates more questions).
Any help would be greatly appreciated.
Thanks.
Before I write my own methods, I have a few questions:
I'm replacing my rigidbody with a softbody. Do these methods/fields or something equivalent exist for softbodies.
- Rigidbody.GetPointVelocity(Vector3 worldPoint) - returns the pointVelocity .
- Rigidbody.AddForceAtPosition(Vector3 force, Vector3 position)
- Rigibody.centerOfMass - get and set the center of mass of softbody.
- Rigibody.mass - [i]get and set the total mass of softbody.[/i]
- Rigibody.velocity - gets the softbody velocity
for setting mass: I was going to divide the total mass with the particle count and add that value to each particle.
for getting velocity: since each particle has a velocity, I was going to use the first particle as the velocity.
but does a single particle velocity represent the velocity of the entire softbody? Not sure this will work.
And Lastly - Since you have to initialize a softbody in the editor, It's not possible to create a softbody at runtime, right?
I'm in the dark and guessing without the softbody API documentation (using the source helps, but creates more questions).
Any help would be greatly appreciated.
Thanks.
Studio Tatsu
Twitter | YouTube | | Instagram
Twitter | YouTube | | Instagram