40 lines
738 B
C#
40 lines
738 B
C#
using System;
|
|
using UnityEngine;
|
|
|
|
namespace PhysicsTools
|
|
{
|
|
[Serializable]
|
|
public class SerializedSoftJointLimitSpring
|
|
{
|
|
public float spring = 30000f;
|
|
|
|
public float damper = 30000f;
|
|
|
|
public SerializedSoftJointLimitSpring()
|
|
{
|
|
spring = 30000f;
|
|
damper = 30000f;
|
|
}
|
|
|
|
private SerializedSoftJointLimitSpring(SoftJointLimitSpring c)
|
|
{
|
|
damper = c.damper;
|
|
spring = c.spring;
|
|
}
|
|
|
|
public static implicit operator SoftJointLimitSpring(SerializedSoftJointLimitSpring c)
|
|
{
|
|
return new SoftJointLimitSpring
|
|
{
|
|
spring = c.spring,
|
|
damper = c.damper
|
|
};
|
|
}
|
|
|
|
public static explicit operator SerializedSoftJointLimitSpring(SoftJointLimitSpring c)
|
|
{
|
|
return new SerializedSoftJointLimitSpring(c);
|
|
}
|
|
}
|
|
}
|