D6JointDrive.generated.cs 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. using System;
  2. using System.Runtime.CompilerServices;
  3. using System.Runtime.InteropServices;
  4. namespace BansheeEngine
  5. {
  6. /** @addtogroup Physics
  7. * @{
  8. */
  9. /// <summary>
  10. /// Specifies parameters for a drive that will attempt to move the joint bodies to the specified drive position and
  11. /// velocity.
  12. /// </summary>
  13. [StructLayout(LayoutKind.Sequential), SerializeObject]
  14. public partial struct D6JointDrive
  15. {
  16. /// <summary>Initializes the struct with default values.</summary>
  17. public static D6JointDrive Default()
  18. {
  19. D6JointDrive value = new D6JointDrive();
  20. value.stiffness = 0f;
  21. value.damping = 0f;
  22. value.forceLimit = 3.40282347E+38f;
  23. value.acceleration = false;
  24. return value;
  25. }
  26. /// <summary>Spring strength. Force proportional to the position error.</summary>
  27. public float stiffness;
  28. /// <summary>Damping strength. Force propertional to the velocity error.</summary>
  29. public float damping;
  30. /// <summary>Maximum force the drive can apply.</summary>
  31. public float forceLimit;
  32. /// <summary>
  33. /// If true the drive will generate acceleration instead of forces. Acceleration drives are easier to tune as they
  34. /// account for the masses of the actors to which the joint is attached.
  35. /// </summary>
  36. public bool acceleration;
  37. }
  38. /** @} */
  39. }