summaryrefslogtreecommitdiff
path: root/_ActiveRagdoll/SetRigidbodySettings.cs
blob: 5f8695a7fb995ead67f64a80653cedc243623128 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
using UnityEngine;

public class SetRigidbodySettings : MonoBehaviour
{
	public float maxAngular;//1000

    private void Start()
	{
		Rigidbody[] componentsInChildren = GetComponentsInChildren<Rigidbody>();
		foreach (Rigidbody rigidbody in componentsInChildren)
		{
			rigidbody.maxAngularVelocity = maxAngular;
			rigidbody.maxDepenetrationVelocity = 10000f;
		}
	}

	private void Update()
	{
	}
}