// --------------------------------------------------------------------------------------------------------------------
//
// Copyright (c) VRMADA, All rights reserved.
//
// --------------------------------------------------------------------------------------------------------------------
using UltimateXR.Core;
using UnityEngine;
namespace UltimateXR.Devices.Integrations
{
///
/// Dummy input class that is used when there is no active input component in the avatar.
/// It has the advantage of avoiding to check for null input component and it doesn't generate any type of input
/// events.
///
public class UxrDummyControllerInput : UxrControllerInput
{
#region Public Overrides UxrControllerInput
///
public override UxrControllerSetupType SetupType => UxrControllerSetupType.Dual;
///
public override string LeftControllerName => "Dummy Left";
///
public override string RightControllerName => "Dummy Right";
///
public override bool IsHandednessSupported => true;
///
public override bool IsControllerEnabled(UxrHandSide handSide)
{
return false;
}
///
public override bool HasControllerElements(UxrHandSide handSide, UxrControllerElements controllerElement)
{
return false;
}
///
public override float GetInput1D(UxrHandSide handSide, UxrInput1D input1D, bool getIgnoredInput = false)
{
return 0.0f;
}
///
public override Vector2 GetInput2D(UxrHandSide handSide, UxrInput2D input2D, bool getIgnoredInput = false)
{
return Vector2.zero;
}
///
public override UxrControllerInputCapabilities GetControllerCapabilities(UxrHandSide handSide)
{
return 0;
}
#endregion
}
}