//
// Generated by Brutal.Jolt.Generate; do not edit by hand.
#nullable enable
using System.Runtime.CompilerServices;
using Brutal.Interop;
using Brutal.Numerics;
namespace Brutal.JoltApi
{
///
///
/// An anti rollbar is a stiff spring that connects two wheels to reduce the amount of roll the vehicle makes in
/// sharp corners See: https://en.wikipedia.org/wiki/Anti-roll_bar
///
///
/// C++:
/// Jolt/Physics/Vehicle/VehicleAntiRollBar.h:15
///
/// class VehicleAntiRollBar
///
///
[StructLayout(LayoutKind.Explicit, Size = 12)]
public partial struct VehicleAntiRollBar
{
///
///
/// Index (in mWheels) that represents the left wheel of this anti-rollbar
///
///
/// C++:
/// Jolt/Physics/Vehicle/VehicleAntiRollBar.h:26
///
/// int mLeftWheel = 0
///
///
[FieldOffset(0)]
public int LeftWheel;
///
///
/// Index (in mWheels) that represents the right wheel of this anti-rollbar
///
///
/// C++:
/// Jolt/Physics/Vehicle/VehicleAntiRollBar.h:27
///
/// int mRightWheel = 1
///
///
[FieldOffset(4)]
public int RightWheel;
///
///
/// Stiffness (spring constant in N/m) of anti rollbar, can be 0 to disable the anti-rollbar
///
///
/// C++:
/// Jolt/Physics/Vehicle/VehicleAntiRollBar.h:28
///
/// float mStiffness = 1000.0f
///
///
[FieldOffset(8)]
public float Stiffness;
///
///
/// Saves the contents in binary form to inStream.
///
///
/// C++:
/// Jolt/Physics/Vehicle/VehicleAntiRollBar.h:21
///
/// void SaveBinaryState(StreamOut &inStream) const
///
///
public readonly void SaveBinaryState(StreamOut stream) =>
Jolt.PInvoke.VehicleAntiRollBar_SaveBinaryState(ref Unsafe.AsRef(in this), stream);
///
///
/// Restores the contents in binary form to inStream.
///
///
/// C++:
/// Jolt/Physics/Vehicle/VehicleAntiRollBar.h:24
///
/// void RestoreBinaryState(StreamIn &inStream)
///
///
public void RestoreBinaryState(StreamIn stream) =>
Jolt.PInvoke.VehicleAntiRollBar_RestoreBinaryState(ref this, stream);
}
}