BindCollectionclass
A collection of action binds. BindCollection - Action: attack1 - Slot0: mouse1 - Action: selectall - Slot0: ctrl + a The bind collection can be saved and loaded from disk via the BindSaveConfig class. The bind collection can have a base collection which it will fall back to if it contains the same binds. This allows us to have a "common" collection which can be shared between all games, but can also let the games + users to override those binds if they choose.
Constructors1
Showing 1 constructors
public BindCollection(string name)
Creates a collection and tries to load it from disk.
| Parameter | Type | Description |
|---|---|---|
| name | string | — |
No results match this filter.
Methods4
Showing 4 methods
public string Get(string actionName, int slot)
Get the bind value at this slot
| Parameter | Type | Description |
|---|---|---|
| actionName | string | — |
| slot | int | — |
string—public Sandbox.Engine.BindCollection.ActionBind GetBind(string actionName, bool create = True)
Get the bind, create if it doesn't exist
| Parameter | Type | Description |
|---|---|---|
| actionName | string | — |
| create = True | bool | — |
public void SaveToDisk()
Save the collection to disk
void—public Sandbox.Engine.BindCollection.ActionBind Set(string actionName, int slot, string buttonName)
Set the bind value for this action. This will overwrite what's in this slot.
| Parameter | Type | Description |
|---|---|---|
| actionName | string | — |
| slot | int | — |
| buttonName | string | — |
No results match this filter.
Properties3
Showing 3 properties
public Sandbox.Engine.BindCollection Sandbox.Engine.BindCollection.Base { get; set; }
The base collection. Game binds have this set to the common binds.
public string Sandbox.Engine.BindCollection.CollectionName { get; set; }
Will be either "common" or the ident of the current game.
string—public string Sandbox.Engine.BindCollection.ConfigPath { get; set; }
The location of the config file to load from in EngineFileSystem.Config
string—No results match this filter.