17.01.2021
+ WPF-Support + Game Controller System + GameKeybind System + SM_WPF_TEST
This commit is contained in:
parent
af90d617d3
commit
6f23a80f7f
60 changed files with 1536 additions and 143 deletions
39
SMOptionals/SM.Game/Controls/GameController.cs
Normal file
39
SMOptionals/SM.Game/Controls/GameController.cs
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
using SharpDX.XInput;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameController
|
||||
{
|
||||
public static float GlobalDeadband = 2500;
|
||||
|
||||
private Controller _controller;
|
||||
|
||||
public float Deadband { get; set; }
|
||||
public bool IsConnected => _controller.IsConnected;
|
||||
|
||||
public UserIndex Index { get; private set; }
|
||||
|
||||
public GameController(int id) : this((UserIndex)id)
|
||||
{}
|
||||
|
||||
public GameController(UserIndex index = UserIndex.Any)
|
||||
{
|
||||
_controller = new Controller(index);
|
||||
Index = index;
|
||||
Deadband = GlobalDeadband;
|
||||
}
|
||||
|
||||
public GameControllerState GetState()
|
||||
{
|
||||
if (!IsConnected)
|
||||
{
|
||||
return new GameControllerState(true);
|
||||
}
|
||||
|
||||
Gamepad state = _controller.GetState().Gamepad;
|
||||
|
||||
return new GameControllerState(state, ref this);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
57
SMOptionals/SM.Game/Controls/GameControllerState.cs
Normal file
57
SMOptionals/SM.Game/Controls/GameControllerState.cs
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
using System;
|
||||
using OpenTK;
|
||||
using SharpDX.XInput;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameControllerState
|
||||
{
|
||||
public GameControllerStateThumbs Thumbs;
|
||||
public GameControllerStateTriggers Triggers;
|
||||
public GameControllerStateDPad DPad;
|
||||
public GameControllerStateButtons Buttons;
|
||||
|
||||
public bool FromConnected { get; }
|
||||
|
||||
internal GameControllerState(bool empty)
|
||||
{
|
||||
FromConnected = false;
|
||||
|
||||
Thumbs = GameControllerStateThumbs.Default;
|
||||
Triggers = GameControllerStateTriggers.Default;
|
||||
DPad = GameControllerStateDPad.Default;
|
||||
Buttons = GameControllerStateButtons.Default;
|
||||
}
|
||||
internal GameControllerState(Gamepad state, ref GameController controller)
|
||||
{
|
||||
FromConnected = true;
|
||||
|
||||
Thumbs = new GameControllerStateThumbs
|
||||
{
|
||||
Left = new Vector2(
|
||||
Math.Abs((float)state.LeftThumbX) < controller.Deadband ? 0 : (float)state.LeftThumbX / short.MaxValue,
|
||||
Math.Abs((float)state.LeftThumbY) < controller.Deadband ? 0 : (float)state.LeftThumbY / short.MaxValue),
|
||||
Right = new Vector2(
|
||||
Math.Abs((float)state.RightThumbX) < controller.Deadband ? 0 : (float)state.RightThumbX / short.MaxValue,
|
||||
Math.Abs((float)state.RightThumbY) < controller.Deadband ? 0 : (float)state.RightThumbY / short.MaxValue),
|
||||
|
||||
PressedLeft = state.Buttons.HasFlag(GamepadButtonFlags.LeftThumb),
|
||||
PressedRight = state.Buttons.HasFlag(GamepadButtonFlags.RightThumb)
|
||||
};
|
||||
|
||||
Triggers = new GameControllerStateTriggers()
|
||||
{
|
||||
Left = (float)state.LeftTrigger / byte.MaxValue,
|
||||
Right = (float)state.RightTrigger / byte.MaxValue
|
||||
};
|
||||
|
||||
DPad = new GameControllerStateDPad(state.Buttons);
|
||||
Buttons = new GameControllerStateButtons(state.Buttons);
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return !FromConnected ? "[From a disconnected controller]" : $"Thumbs: [{Thumbs}]; Trigger: [{Triggers}]; DPad: [{DPad}]; Buttons: [{Buttons}]";
|
||||
}
|
||||
}
|
||||
}
|
||||
45
SMOptionals/SM.Game/Controls/GameControllerStateButtons.cs
Normal file
45
SMOptionals/SM.Game/Controls/GameControllerStateButtons.cs
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
using SharpDX.XInput;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameControllerStateButtons
|
||||
{
|
||||
public static GameControllerStateButtons Default = new GameControllerStateButtons(GamepadButtonFlags.None);
|
||||
|
||||
private GamepadButtonFlags _buttonFlags;
|
||||
|
||||
public bool X;
|
||||
public bool Y;
|
||||
public bool A;
|
||||
public bool B;
|
||||
|
||||
public bool LB;
|
||||
public bool RB;
|
||||
|
||||
public bool LeftThumb;
|
||||
public bool RightThumb;
|
||||
|
||||
public bool this[GamepadButtonFlags flags] => _buttonFlags.HasFlag(flags);
|
||||
|
||||
internal GameControllerStateButtons(GamepadButtonFlags flags)
|
||||
{
|
||||
_buttonFlags = flags;
|
||||
|
||||
X = flags.HasFlag(GamepadButtonFlags.X);
|
||||
Y = flags.HasFlag(GamepadButtonFlags.Y);
|
||||
A = flags.HasFlag(GamepadButtonFlags.A);
|
||||
B = flags.HasFlag(GamepadButtonFlags.B);
|
||||
|
||||
LB = flags.HasFlag(GamepadButtonFlags.LeftShoulder);
|
||||
RB = flags.HasFlag(GamepadButtonFlags.RightShoulder);
|
||||
|
||||
LeftThumb = flags.HasFlag(GamepadButtonFlags.LeftThumb);
|
||||
RightThumb = flags.HasFlag(GamepadButtonFlags.RightThumb);
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return $"X: {(X ? "1" : "0")}; Y: {(Y ? "1" : "0")}; A: {(A ? "1" : "0")}; B: {(B ? "1" : "0")}; LB: {(LB ? "1" : "0")}; RB: {(RB ? "1" : "0")}; LT: {(LeftThumb ? "1" : "0")}; RT: {(RightThumb ? "1" : "0")}";
|
||||
}
|
||||
}
|
||||
}
|
||||
28
SMOptionals/SM.Game/Controls/GameControllerStateDPad.cs
Normal file
28
SMOptionals/SM.Game/Controls/GameControllerStateDPad.cs
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
using SharpDX.XInput;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameControllerStateDPad
|
||||
{
|
||||
public static GameControllerStateDPad Default = new GameControllerStateDPad(GamepadButtonFlags.None);
|
||||
|
||||
public bool Up;
|
||||
public bool Down;
|
||||
public bool Left;
|
||||
public bool Right;
|
||||
|
||||
internal GameControllerStateDPad(GamepadButtonFlags flags)
|
||||
{
|
||||
Up = flags.HasFlag(GamepadButtonFlags.DPadUp);
|
||||
Down = flags.HasFlag(GamepadButtonFlags.DPadDown);
|
||||
Left = flags.HasFlag(GamepadButtonFlags.DPadLeft);
|
||||
Right = flags.HasFlag(GamepadButtonFlags.DPadRight);
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return
|
||||
$"Up: {(Up ? "1" : "0")}; Down: {(Down ? "1" : "0")}; Left: {(Left ? "1" : "0")}; Right: {(Right ? "1" : "0")};";
|
||||
}
|
||||
}
|
||||
}
|
||||
21
SMOptionals/SM.Game/Controls/GameControllerStateThumbs.cs
Normal file
21
SMOptionals/SM.Game/Controls/GameControllerStateThumbs.cs
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
using OpenTK;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameControllerStateThumbs
|
||||
{
|
||||
public static GameControllerStateThumbs Default = new GameControllerStateThumbs()
|
||||
{Left = Vector2.Zero, Right = Vector2.Zero};
|
||||
|
||||
public Vector2 Left;
|
||||
public Vector2 Right;
|
||||
|
||||
public bool PressedLeft;
|
||||
public bool PressedRight;
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return $"Left: ({Left.X}; {Left.Y}){(PressedLeft ? " Pressed" : "")}; Right: ({Right.X}; {Right.Y}){(PressedRight ? " Pressed" : "")}";
|
||||
}
|
||||
}
|
||||
}
|
||||
14
SMOptionals/SM.Game/Controls/GameControllerStateTriggers.cs
Normal file
14
SMOptionals/SM.Game/Controls/GameControllerStateTriggers.cs
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameControllerStateTriggers
|
||||
{
|
||||
public static GameControllerStateTriggers Default = new GameControllerStateTriggers {Left = 0f, Right = 0f};
|
||||
|
||||
public float Left;
|
||||
public float Right;
|
||||
public override string ToString()
|
||||
{
|
||||
return $"Left: {Left}; Right: {Right}";
|
||||
}
|
||||
}
|
||||
}
|
||||
32
SMOptionals/SM.Game/Controls/GameKeybind.cs
Normal file
32
SMOptionals/SM.Game/Controls/GameKeybind.cs
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
using System;
|
||||
using OpenTK.Input;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public class GameKeybind
|
||||
{
|
||||
public Func<GameKeybindContext, object> Keyboard;
|
||||
public Func<GameKeybindContext, object> Controller;
|
||||
public Func<GameKeybindContext, object> AI;
|
||||
|
||||
public Func<GameKeybindContext, object> this[GameKeybindActorType type]
|
||||
{
|
||||
get
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case GameKeybindActorType.AI:
|
||||
return AI;
|
||||
case GameKeybindActorType.Keyboard:
|
||||
return Keyboard;
|
||||
break;
|
||||
case GameKeybindActorType.Controller:
|
||||
return Controller;
|
||||
break;
|
||||
default:
|
||||
throw new ArgumentOutOfRangeException(nameof(type), type, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
90
SMOptionals/SM.Game/Controls/GameKeybindActor.cs
Normal file
90
SMOptionals/SM.Game/Controls/GameKeybindActor.cs
Normal file
|
|
@ -0,0 +1,90 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using OpenTK.Input;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public enum GameKeybindActorType
|
||||
{
|
||||
AI,
|
||||
Keyboard,
|
||||
Controller
|
||||
}
|
||||
|
||||
public struct GameKeybindActor
|
||||
{
|
||||
private GameKeybindActorType _type;
|
||||
private GameController? _controller;
|
||||
|
||||
private GameKeybindHost _keybindHost;
|
||||
|
||||
public GameKeybindActorType Type => _type;
|
||||
public GameController? Controller => _controller;
|
||||
|
||||
public object[] Parameter;
|
||||
|
||||
private GameKeybindActor(GameKeybindActorType type, GameController? controller)
|
||||
{
|
||||
_type = type;
|
||||
_controller = controller;
|
||||
|
||||
_keybindHost = null;
|
||||
|
||||
Parameter = new object[0];
|
||||
}
|
||||
|
||||
public void ConnectHost(GameKeybindHost host)
|
||||
{
|
||||
_keybindHost = host;
|
||||
}
|
||||
|
||||
public ReturnType Get<ReturnType>(string name, params object[] param)
|
||||
{
|
||||
return (ReturnType) Get(name, param);
|
||||
}
|
||||
|
||||
public object Get(string name, params object[] objects)
|
||||
{
|
||||
if (_keybindHost == null) return null;
|
||||
if (!_keybindHost._actions.ContainsKey(name)) return null;
|
||||
|
||||
GameKeybind keybind = _keybindHost._actions[name];
|
||||
|
||||
GameKeybindContext context = new GameKeybindContext()
|
||||
{
|
||||
Actor = this,
|
||||
Host = _keybindHost,
|
||||
|
||||
ActorParameter = Parameter,
|
||||
InstanceParameter = objects,
|
||||
|
||||
KeyboardState = Keyboard.GetState(),
|
||||
MouseState = Mouse.GetState(),
|
||||
ControllerState = Controller?.GetState(),
|
||||
};
|
||||
|
||||
return keybind[Type].Invoke(context);
|
||||
}
|
||||
|
||||
public static GameKeybindActor CreateAIActor()
|
||||
{
|
||||
return new GameKeybindActor(GameKeybindActorType.AI, null);
|
||||
}
|
||||
|
||||
public static GameKeybindActor CreateKeyboardActor()
|
||||
{
|
||||
return new GameKeybindActor(GameKeybindActorType.Keyboard, null);
|
||||
}
|
||||
|
||||
public static GameKeybindActor CreateControllerActor(int id)
|
||||
{
|
||||
return CreateControllerActor(new GameController(id));
|
||||
}
|
||||
|
||||
public static GameKeybindActor CreateControllerActor(GameController controller)
|
||||
{
|
||||
return new GameKeybindActor(GameKeybindActorType.Controller, controller);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
17
SMOptionals/SM.Game/Controls/GameKeybindContext.cs
Normal file
17
SMOptionals/SM.Game/Controls/GameKeybindContext.cs
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
using OpenTK.Input;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public struct GameKeybindContext
|
||||
{
|
||||
public KeyboardState KeyboardState;
|
||||
public MouseState MouseState;
|
||||
public GameControllerState? ControllerState;
|
||||
|
||||
public GameKeybindActor Actor;
|
||||
public GameKeybindHost Host;
|
||||
|
||||
public object[] InstanceParameter;
|
||||
public object[] ActorParameter;
|
||||
}
|
||||
}
|
||||
40
SMOptionals/SM.Game/Controls/GameKeybindHost.cs
Normal file
40
SMOptionals/SM.Game/Controls/GameKeybindHost.cs
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using OpenTK.Input;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public class GameKeybindHost
|
||||
{
|
||||
internal Dictionary<string, GameKeybind> _actions = new Dictionary<string, GameKeybind>();
|
||||
|
||||
public GameKeybindHost()
|
||||
{ }
|
||||
|
||||
public GameKeybindHost(GameKeybindList setup)
|
||||
{
|
||||
for (int i = 0; i < setup.Count; i++)
|
||||
{
|
||||
_actions[setup[i].Key] = setup[i].Value;
|
||||
}
|
||||
}
|
||||
|
||||
public void Setup(string name, Func<GameKeybindContext, object> keyboard = null, Func<GameKeybindContext, object> gameController = null, Func<GameKeybindContext, object> ai = null)
|
||||
{
|
||||
GameKeybind bind;
|
||||
if (_actions.ContainsKey(name))
|
||||
{
|
||||
bind = _actions[name];
|
||||
}
|
||||
else
|
||||
{
|
||||
bind = new GameKeybind();
|
||||
_actions.Add(name, bind);
|
||||
}
|
||||
|
||||
bind.Keyboard = keyboard;
|
||||
bind.Controller = gameController;
|
||||
bind.AI = ai;
|
||||
}
|
||||
}
|
||||
}
|
||||
26
SMOptionals/SM.Game/Controls/GameKeybindList.cs
Normal file
26
SMOptionals/SM.Game/Controls/GameKeybindList.cs
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using OpenTK.Input;
|
||||
|
||||
namespace SM.Game.Controls
|
||||
{
|
||||
public class GameKeybindList : List<KeyValuePair<string, GameKeybind>>
|
||||
{
|
||||
public void Add(string name, GameKeybind keybind)
|
||||
{
|
||||
Add(new KeyValuePair<string, GameKeybind>(name, keybind));
|
||||
}
|
||||
|
||||
public void Add(string name, Func<GameKeybindContext, object> keyboard = null,
|
||||
Func<GameKeybindContext, object> controller = null)
|
||||
{
|
||||
Add(new KeyValuePair<string, GameKeybind>(name, new GameKeybind()
|
||||
{
|
||||
AI = null,
|
||||
Controller = controller,
|
||||
Keyboard = keyboard
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
||||
25
SMOptionals/SM.Game/OpenTK.dll.config
Normal file
25
SMOptionals/SM.Game/OpenTK.dll.config
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
<configuration>
|
||||
<dllmap os="linux" dll="opengl32.dll" target="libGL.so.1"/>
|
||||
<dllmap os="linux" dll="glu32.dll" target="libGLU.so.1"/>
|
||||
<dllmap os="linux" dll="openal32.dll" target="libopenal.so.1"/>
|
||||
<dllmap os="linux" dll="alut.dll" target="libalut.so.0"/>
|
||||
<dllmap os="linux" dll="opencl.dll" target="libOpenCL.so"/>
|
||||
<dllmap os="linux" dll="libX11" target="libX11.so.6"/>
|
||||
<dllmap os="linux" dll="libXi" target="libXi.so.6"/>
|
||||
<dllmap os="linux" dll="SDL2.dll" target="libSDL2-2.0.so.0"/>
|
||||
<dllmap os="osx" dll="opengl32.dll" target="/System/Library/Frameworks/OpenGL.framework/OpenGL"/>
|
||||
<dllmap os="osx" dll="openal32.dll" target="/System/Library/Frameworks/OpenAL.framework/OpenAL" />
|
||||
<dllmap os="osx" dll="alut.dll" target="/System/Library/Frameworks/OpenAL.framework/OpenAL" />
|
||||
<dllmap os="osx" dll="libGLES.dll" target="/System/Library/Frameworks/OpenGLES.framework/OpenGLES" />
|
||||
<dllmap os="osx" dll="libGLESv1_CM.dll" target="/System/Library/Frameworks/OpenGLES.framework/OpenGLES" />
|
||||
<dllmap os="osx" dll="libGLESv2.dll" target="/System/Library/Frameworks/OpenGLES.framework/OpenGLES" />
|
||||
<dllmap os="osx" dll="opencl.dll" target="/System/Library/Frameworks/OpenCL.framework/OpenCL"/>
|
||||
<dllmap os="osx" dll="SDL2.dll" target="libSDL2.dylib"/>
|
||||
<!-- XQuartz compatibility (X11 on Mac) -->
|
||||
<dllmap os="osx" dll="libGL.so.1" target="/usr/X11/lib/libGL.dylib"/>
|
||||
<dllmap os="osx" dll="libX11" target="/usr/X11/lib/libX11.dylib"/>
|
||||
<dllmap os="osx" dll="libXcursor.so.1" target="/usr/X11/lib/libXcursor.dylib"/>
|
||||
<dllmap os="osx" dll="libXi" target="/usr/X11/lib/libXi.dylib"/>
|
||||
<dllmap os="osx" dll="libXinerama" target="/usr/X11/lib/libXinerama.dylib"/>
|
||||
<dllmap os="osx" dll="libXrandr.so.2" target="/usr/X11/lib/libXrandr.dylib"/>
|
||||
</configuration>
|
||||
36
SMOptionals/SM.Game/Properties/AssemblyInfo.cs
Normal file
36
SMOptionals/SM.Game/Properties/AssemblyInfo.cs
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("SM.Game")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("SM.Game")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2021")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("079bab31-3dc4-40da-90c7-efaa8517c647")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
71
SMOptionals/SM.Game/SM.Game.csproj
Normal file
71
SMOptionals/SM.Game/SM.Game.csproj
Normal file
|
|
@ -0,0 +1,71 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{079BAB31-3DC4-40DA-90C7-EFAA8517C647}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>SM.Game</RootNamespace>
|
||||
<AssemblyName>SM.Game</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<Deterministic>true</Deterministic>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="OpenTK, Version=3.3.1.0, Culture=neutral, PublicKeyToken=bad199fe84eb3df4, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\OpenTK.3.3.1\lib\net20\OpenTK.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SharpDX, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b4dcf0f35e5521f1, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\SharpDX.4.2.0\lib\net45\SharpDX.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="SharpDX.XInput, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b4dcf0f35e5521f1, processorArchitecture=MSIL">
|
||||
<HintPath>..\..\packages\SharpDX.XInput.4.2.0\lib\net45\SharpDX.XInput.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Controls\GameController.cs" />
|
||||
<Compile Include="Controls\GameControllerState.cs" />
|
||||
<Compile Include="Controls\GameControllerStateButtons.cs" />
|
||||
<Compile Include="Controls\GameControllerStateDPad.cs" />
|
||||
<Compile Include="Controls\GameControllerStateThumbs.cs" />
|
||||
<Compile Include="Controls\GameControllerStateTriggers.cs" />
|
||||
<Compile Include="Controls\GameKeybind.cs" />
|
||||
<Compile Include="Controls\GameKeybindActor.cs" />
|
||||
<Compile Include="Controls\GameKeybindContext.cs" />
|
||||
<Compile Include="Controls\GameKeybindHost.cs" />
|
||||
<Compile Include="Controls\GameKeybindList.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="OpenTK.dll.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
||||
6
SMOptionals/SM.Game/packages.config
Normal file
6
SMOptionals/SM.Game/packages.config
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="OpenTK" version="3.3.1" targetFramework="net452" />
|
||||
<package id="SharpDX" version="4.2.0" targetFramework="net452" />
|
||||
<package id="SharpDX.XInput" version="4.2.0" targetFramework="net452" />
|
||||
</packages>
|
||||
Loading…
Add table
Add a link
Reference in a new issue