mirror of
https://github.com/Facepunch/sbox-public.git
synced 2026-01-06 21:38:32 -05:00
This commit imports the C# engine code and game files, excluding C++ source code. [Source-Commit: ceb3d758046e50faa6258bc3b658a30c97743268]
27 lines
587 B
C#
27 lines
587 B
C#
namespace Sandbox;
|
|
|
|
/// <summary>
|
|
/// A class that holds all configured input settings for a game.
|
|
/// This is serialized as a config and shared from the server to the client.
|
|
/// </summary>
|
|
[Expose]
|
|
public class InputSettings : ConfigData
|
|
{
|
|
public InputSettings()
|
|
{
|
|
Actions = new List<InputAction>();
|
|
InitDefault();
|
|
}
|
|
|
|
public void InitDefault()
|
|
{
|
|
Actions.Clear();
|
|
Actions.AddRange( Engine.Input.CommonInputs.Select( x => new InputAction( x ) ) );
|
|
}
|
|
|
|
/// <summary>
|
|
/// A list of actions used by the game.
|
|
/// </summary>
|
|
public List<InputAction> Actions { get; set; }
|
|
}
|