Class DOTSDynamicBoneClass
This holds and displays all the data needs to modify to create the DOTSDynamicBone data
Inheritance
Namespace: DOTSDynamicBone
Assembly: cs.temp.dll.dll
Syntax
[Serializable]
public class DOTSDynamicBoneClass
Remarks
This holds and displays all the data needs to modify to create the DOTSDynamicBone data
Constructors
DOTSDynamicBoneClass()
Declaration
public DOTSDynamicBoneClass()
Fields
Disable
Declaration
public bool Disable
Field Value
Type | Description |
---|---|
System.Boolean | Set to true to disable the calculations done on the the bones Particles |
m_BoneTotalLength
Declaration
public float m_BoneTotalLength
Field Value
Type | Description |
---|---|
System.Single |
m_Colliders
Declaration
public List<DOTSDynamicBoneCollider> m_Colliders
Field Value
Type | Description |
---|---|
List<DOTSDynamicBoneCollider> | Collider objects interact with the bones. |
m_Damping
Declaration
public float m_Damping
Field Value
Type | Description |
---|---|
System.Single | How much the bones slowed down. |
m_DampingDistrib
Declaration
public AnimationCurve m_DampingDistrib
Field Value
Type | Description |
---|---|
AnimationCurve | How much the bones slowed down over a distribution curve. |
m_DistanceToObject
Declaration
public float m_DistanceToObject
Field Value
Type | Description |
---|---|
System.Single | distnace the Entity has to be from the referenced Entity |
m_DistantDisable
Declaration
public bool m_DistantDisable
Field Value
Type | Description |
---|---|
System.Boolean | Disable physics simulation automatically if Entity is far from the m_ReferencedObject Entity. |
m_Elasticity
Declaration
public float m_Elasticity
Field Value
Type | Description |
---|---|
System.Single | How much the force applied to return each bone to original orientation. |
m_ElasticityDistrib
Declaration
public AnimationCurve m_ElasticityDistrib
Field Value
Type | Description |
---|---|
AnimationCurve | How much the force applied to return each bone to original orientation over a distribution curve. |
m_EndLength
Declaration
public float m_EndLength
Field Value
Type | Description |
---|---|
System.Single | If End Length is not zero, an extra bone is generated at the end of transform hierarchy. |
m_EndOffset
Declaration
public Vector3 m_EndOffset
Field Value
Type | Description |
---|---|
Vector3 | If End Offset is not zero, an extra bone is generated at the end of transform hierarchy. |
m_Exclusions
Declaration
public List<ExcludeEntityFromSimulation> m_Exclusions
Field Value
Type | Description |
---|---|
List<ExcludeEntityFromSimulation> | Bones excluded from physics simulation. |
m_Force
Declaration
public Vector3 m_Force
Field Value
Type | Description |
---|---|
Vector3 | The force apply to bones. |
m_FreezeAxis
Declaration
public DOTSDynamicBone.FreezeAxis m_FreezeAxis
Field Value
Type | Description |
---|---|
DOTSDynamicBone.FreezeAxis | Constrain bones to move on specified plane. |
m_Friction
Declaration
public float m_Friction
Field Value
Type | Description |
---|---|
System.Single | How much the bones slowed down when collide. |
m_FrictionDistrib
Declaration
public AnimationCurve m_FrictionDistrib
Field Value
Type | Description |
---|---|
AnimationCurve | How much the bones slowed down when collide over a distribution curve. |
m_Gravity
Declaration
public Vector3 m_Gravity
Field Value
Type | Description |
---|---|
Vector3 | The force apply to bones. Partial force apply to character's initial pose is cancelled out. |
m_Inert
Declaration
public float m_Inert
Field Value
Type | Description |
---|---|
System.Single | How much character's position change is ignored in physics simulation. |
m_InertDistrib
Declaration
public AnimationCurve m_InertDistrib
Field Value
Type | Description |
---|---|
AnimationCurve | How much character's position change is ignored in physics simulation over a distribution curve. |
m_Radius
Declaration
public float m_Radius
Field Value
Type | Description |
---|---|
System.Single | Each bone can be a sphere to collide with colliders. Radius describe sphere's size. |
m_RadiusDistrib
Declaration
public AnimationCurve m_RadiusDistrib
Field Value
Type | Description |
---|---|
AnimationCurve | Each bone can be a sphere to collide with colliders. Radius describe sphere's size over a distribution curve. |
m_ReferenceObject
Declaration
public Transform m_ReferenceObject
Field Value
Type | Description |
---|---|
Transform | Entity to be referenced for m_DistantDisable |
m_Root
Declaration
public Transform m_Root
Field Value
Type | Description |
---|---|
Transform | The root of the transform hierarchy to apply physics. |
m_Stiffness
Declaration
public float m_Stiffness
Field Value
Type | Description |
---|---|
System.Single | How much bone's original orientation are preserved. |
m_StiffnessDistrib
Declaration
public AnimationCurve m_StiffnessDistrib
Field Value
Type | Description |
---|---|
AnimationCurve | How much bone's original orientation are preserved over a distribution curve. |
m_UpdateDataFrom
Declaration
public DOTSDynamicBoneClass.UpdateDataFrom m_UpdateDataFrom
Field Value
Type | Description |
---|---|
DOTSDynamicBoneClass.UpdateDataFrom | An option to choose where the data updates from. |
m_UpdateMode
Declaration
public DOTSDynamicBone.UpdateMode m_UpdateMode
Field Value
Type | Description |
---|---|
DOTSDynamicBone.UpdateMode | Internal physics simulation type. |
m_UpdateRate
Declaration
public float m_UpdateRate
Field Value
Type | Description |
---|---|
System.Single | Internal physics simulation rate. |
m_Weight
Declaration
public float m_Weight
Field Value
Type | Description |
---|---|
System.Single |
Name
Declaration
public string Name
Field Value
Type | Description |
---|---|
System.String | Just The name of the root bone (so you can see it in the editor easier, changing it won't break anything but may confuse you |
RigComponent
Declaration
public RigComponent RigComponent
Field Value
Type | Description |
---|---|
RigComponent | This should be the GameObject this script is attached to |
UpdateLocalToWorldTransforms
Declaration
public bool UpdateLocalToWorldTransforms
Field Value
Type | Description |
---|---|
System.Boolean | Set to true to update the LocalToWorld of the Particle's Corresponding Entity |
UpdateRotationTransforms
Declaration
public bool UpdateRotationTransforms
Field Value
Type | Description |
---|---|
System.Boolean | Set to true to update the Rotation of the Particle's Corresponding Entity |
UpdateTranslationTransforms
Declaration
public bool UpdateTranslationTransforms
Field Value
Type | Description |
---|---|
System.Boolean | Set to true to update the Translation of the Particle's Corresponding Entity |
UseAnimatedLocalToRoot
Declaration
public bool UseAnimatedLocalToRoot
Field Value
Type | Description |
---|---|
System.Boolean | Set to true if the entity is Animated using th Unity.Animations Package |
UseNaturalColliders
Declaration
public bool UseNaturalColliders
Field Value
Type | Description |
---|---|
System.Boolean | Set this to true to use enable DOTS PhysicCollider collisions. |
Methods
AddDOTSDynamicBoneCalculationCulling(EntityManager, Entity, ref DOTSDynamicBone, Entity, Single)
Declaration
public static void AddDOTSDynamicBoneCalculationCulling(EntityManager em, Entity e, ref DOTSDynamicBone bone, Entity reference_entity, float distance)
Parameters
Type | Name | Description |
---|---|---|
EntityManager | em | |
Entity | e | |
DOTSDynamicBone | bone | |
Entity | reference_entity | |
System.Single | distance |
AddDOTSDynamicBoneColliderComponentsToEntity(EntityManager, Entity, Boolean, Boolean)
adds some DynamicBoneColliderComponents to the given entity
Declaration
public static void AddDOTSDynamicBoneColliderComponentsToEntity(EntityManager em, Entity e, bool useNaturalColliders, bool excludePhysics)
Parameters
Type | Name | Description |
---|---|---|
EntityManager | em | EntityManager |
Entity | e | Entity |
System.Boolean | useNaturalColliders | |
System.Boolean | excludePhysics |
RemoveDOTSDynamicBoneCalculationCulling(EntityManager, Entity)
Declaration
public static void RemoveDOTSDynamicBoneCalculationCulling(EntityManager em, Entity e)
Parameters
Type | Name | Description |
---|---|---|
EntityManager | em | |
Entity | e |
RemoveDOTSDynamicBoneCalculationCulling(EntityManager, Entity, ref DOTSDynamicBone)
Declaration
public static void RemoveDOTSDynamicBoneCalculationCulling(EntityManager em, Entity e, ref DOTSDynamicBone bone)
Parameters
Type | Name | Description |
---|---|---|
EntityManager | em | |
Entity | e | |
DOTSDynamicBone | bone |
RemoveDOTSDynamicBoneNaturalColliderComponentsFromEntity(EntityManager, Entity)
Declaration
public static void RemoveDOTSDynamicBoneNaturalColliderComponentsFromEntity(EntityManager em, Entity e)
Parameters
Type | Name | Description |
---|---|---|
EntityManager | em | |
Entity | e |
SetDOTSDynamicBoneCalculationCulling(ref DOTSDynamicBone, Entity, Single, Boolean)
Declaration
public static void SetDOTSDynamicBoneCalculationCulling(ref DOTSDynamicBone bone, Entity reference_entity, float distance, bool ActivateCulling = true)
Parameters
Type | Name | Description |
---|---|---|
DOTSDynamicBone | bone | |
Entity | reference_entity | |
System.Single | distance | |
System.Boolean | ActivateCulling |
ToDOTSDynamicBone(GameObjectConversionSystem, RigComponent, Transform, EntityManager, Entity, DOTSDynamicBoneClass)
Creates a valid DOTSDynamicBone
Declaration
public DOTSDynamicBone ToDOTSDynamicBone(GameObjectConversionSystem m_ConversionSystem, RigComponent RigComponent, Transform Root, EntityManager dstManager, Entity rootEntity, DOTSDynamicBoneClass boneComponent)
Parameters
Type | Name | Description |
---|---|---|
GameObjectConversionSystem | m_ConversionSystem | Provided GameObjectConversionSystem |
RigComponent | RigComponent | RigComponent to be used on the conversion |
Transform | Root | The Root GameObject with the RigComponent |
EntityManager | dstManager | EntityManager |
Entity | rootEntity | Entity where the root DOTSDynamicBone will affect |
DOTSDynamicBoneClass | boneComponent | Bone related data |
Returns
Type | Description |
---|---|
DOTSDynamicBone | DOTSDynamicBone |
ToDOTSDynamicBone(GameObjectConversionSystem, RigComponent, Transform, EntityManager, Entity, DOTSDynamicBoneClass, ref DynamicBuffer<Particle>)
Creates a valid DOTSDynamicBone
Declaration
public DOTSDynamicBone ToDOTSDynamicBone(GameObjectConversionSystem m_ConversionSystem, RigComponent RigComponent, Transform Root, EntityManager dstManager, Entity rootEntity, DOTSDynamicBoneClass boneComponent, ref DynamicBuffer<Particle> m_Particles)
Parameters
Type | Name | Description |
---|---|---|
GameObjectConversionSystem | m_ConversionSystem | Provided GameObjectConversionSystem |
RigComponent | RigComponent | RigComponent to be used on the conversion |
Transform | Root | The Root GameObject with the RigComponent |
EntityManager | dstManager | EntityManager |
Entity | rootEntity | Entity where the root DOTSDynamicBone will affect |
DOTSDynamicBoneClass | boneComponent | Bone related data |
DynamicBuffer<Particle> | m_Particles | Buffer of particles to ppopulate with data. |
Returns
Type | Description |
---|---|
DOTSDynamicBone | DOTSDynamicBone |
UpdateName()
Updates the name of the Name property. (Used only in the Editor)
Declaration
public void UpdateName()