Firstborn/Library/PackageCache/com.unity.inputsystem@1.5.1/InputSystem/Controls/DoubleControl.cs
Schaken-Mods 9092858a58 updated to the latest editor
I updated everything to the latest Unity Editor. Also realized I had the wrong shaders on my hairs, those are fixed and the hairs look MUCH better!
2023-05-07 17:43:11 -05:00

31 lines
818 B
C#

using UnityEngine.InputSystem.LowLevel;
namespace UnityEngine.InputSystem.Controls
{
/// <summary>
/// A control reading a <see cref="double"/>.
/// </summary>
public class DoubleControl : InputControl<double>
{
/// <summary>
/// Default-initialize the control.
/// </summary>
public DoubleControl()
{
m_StateBlock.format = InputStateBlock.FormatDouble;
}
/// <inheritdoc/>
public override unsafe double ReadUnprocessedValueFromState(void* statePtr)
{
return m_StateBlock.ReadDouble(statePtr);
}
/// <inheritdoc/>
public override unsafe void WriteValueIntoState(double value, void* statePtr)
{
m_StateBlock.WriteDouble(statePtr, value);
}
}
}