BaseCloth

Overview

A common class for cloth components.
BaseCloth is the base class for BoneCloth / BoneSpring / MeshCloth / MeshSpring.

 


public void ResetCloth()

Resets the cloth simulation particle position.

 


public void SetTimeScale(float timeScale)

Set the time scale.
Slow playback is possible for each component individually.

timeScale Time scale.
Specify from 0.0 (0%) to 1.0 (100%).

 


public float GetTimeScale()

Get the time scale.

 


public void AddForce(Vector3 force, PhysicsManagerTeamData.ForceMode mode)

Apply external force.

force External force vector
mode Speed change mode.
[VelocityAdd]
Add to velocity (affected by mass)
[VelocityChange]
Change velocity (affected by mass)
[VelocityAddWithoutMass]
Add to velocity (ignoring mass)
[VelocityChangeWithoutMass]
Change velocity (ignoring mass)

 


public float BlendWeight

Blending ratio with original posture.
(0.0 = 0%, 1.0 = 100%)

 


public void AddCollider(ColliderComponent collider)

Add Collider.

 


public void RemoveCollider(ColliderComponent collider)

Remove Collider.

 


public void Radius_SetRadius(float startVal, float endVal, float curveVal = 0)

Change the [Radius] parameter particle radius.

 


public void Mass_SetMass(float startVal, float endVal, float curveVal = 0)

Change the particle weight in the [Mass] parameter.

 


public void Gravity_SetGravity(float startVal, float endVal, float curveVal = 0)

Change the gravitational acceleration of the [Gravity] parameter.

 


public void Drag_SetDrag(float startVal, float endVal, float curveVal = 0)

Change the air resistance of the [Drag] parameter.

 


public bool DistanceDisable_Active

Changes the active state of the [Distance Disable] parameter.

 


public Transform DistanceDisable_ReferenceObject

Changes the distance measurement target of the [Distance Disable] parameter.
If you specify null, the current main camera will be the target.

 


public float DistanceDisable_Distance

Changes the distance at which the [Distance Disable] parameter is disabled.

 


public float DistanceDisable_FadeDistance

Changes the fade distance of the [Distance Disable] parameter.
The fade starts at DistanceDisable_Distance minus this distance.

 


public float ExternalForce_MassInfluence

Changes the influence of particle weight on the [External Force] parameter.
The value is between 0.0 (0%) and 1.0 (100%).

 


public float ExternalForce_WindInfluence

Changes the wind influence rate of the [External Force] parameter.
The value is between 0.0 (0%) and 1.0 (100%).
A value of 1.0 or more can be set.

 


public float ExternalForce_WindRandomScale

Changes the wind random rate of the [ExternalForce] parameter.
The value is between 0.0 (0%) and 1.0 (100%).
A value of 1.0 or more can be set.

 


public void WorldInfluence_SetMovementInfluence(float startVal, float endVal, float curveVal = 0)

Change the movement influence rate of the [World Influence] parameter.

 


public void WorldInfluence_SetRotationInfluence(float startVal, float endVal, float curveVal = 0)

Change the rotation influence rate of the [World Influence] parameter.

 


public bool WorldInfluence_ResetAfterTeleport

Change the automatic teleport enable setting for the [World Influence] parameter.

 


public float WorldInfluence_TeleportDistance

Change the automatic teleport of [World Influence] parameter and the moving distance of one frame to be detected.

 


public float WorldInfluence_TeleportRotation

Change the auto teleport of the [World Influence] parameter and the rotation angle (0 – 360) of one frame to be detected.

 


public bool ColliderCollision_Active

Change the active state of the [Collider Collision] parameter.

 


public bool Penetration_Active

Changes the active state of the [Penetration] parameter.