2019-06-19 15:08:49 +03:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
|
|
|
|
using Steamworks.Data;
|
|
|
|
|
|
|
|
|
|
namespace Steamworks
|
|
|
|
|
{
|
|
|
|
|
[TestClass]
|
|
|
|
|
[DeploymentItem( "steam_api64.dll" )]
|
2020-02-22 23:29:37 +03:00
|
|
|
|
[DeploymentItem( "steam_api.dll" )]
|
|
|
|
|
[DeploymentItem( "controller_config/game_actions_252490.vdf" )]
|
2019-06-19 15:08:49 +03:00
|
|
|
|
public class InputTest
|
|
|
|
|
{
|
|
|
|
|
[TestMethod]
|
|
|
|
|
public void ControllerList()
|
|
|
|
|
{
|
2019-06-19 18:18:12 +03:00
|
|
|
|
foreach ( var controller in SteamInput.Controllers )
|
2019-06-19 15:08:49 +03:00
|
|
|
|
{
|
2019-06-19 18:18:12 +03:00
|
|
|
|
Console.Write( $"Controller: {controller}" );
|
2019-06-20 12:41:57 +03:00
|
|
|
|
|
2019-06-20 13:39:13 +03:00
|
|
|
|
var dstate = controller.GetDigitalState( "fire" );
|
|
|
|
|
var astate = controller.GetAnalogState( "Move" );
|
2019-06-19 15:08:49 +03:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
2019-06-19 18:18:12 +03:00
|
|
|
|
|