mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2025-12-19 15:58:39 +00:00
SteamUserPermissions revolution
This is needed for defining multiple operators and/or masters, as well as eventual further enhancements
This commit is contained in:
@@ -30,6 +30,7 @@ using System.Drawing.Design;
|
||||
using System.IO;
|
||||
using ConfigGenerator.JSON;
|
||||
using Newtonsoft.Json;
|
||||
using Wexman.Design;
|
||||
|
||||
namespace ConfigGenerator {
|
||||
[SuppressMessage("ReSharper", "AutoPropertyCanBeMadeGetOnly.Global")]
|
||||
@@ -112,14 +113,6 @@ namespace ConfigGenerator {
|
||||
[JsonProperty(Required = Required.DisallowNull)]
|
||||
public ulong SteamMasterClanID { get; set; } = 0;
|
||||
|
||||
[LocalizedCategory("Access")]
|
||||
[JsonProperty(Required = Required.DisallowNull)]
|
||||
public ulong SteamMasterID { get; set; } = 0;
|
||||
|
||||
[LocalizedCategory("Access")]
|
||||
[JsonProperty(Required = Required.DisallowNull)]
|
||||
public ulong SteamOperatorID { get; set; } = 0;
|
||||
|
||||
[LocalizedCategory("Access")]
|
||||
[JsonProperty]
|
||||
public string SteamParentalPIN { get; set; } = "0";
|
||||
@@ -133,6 +126,11 @@ namespace ConfigGenerator {
|
||||
[JsonProperty]
|
||||
public string SteamTradeToken { get; set; } = null;
|
||||
|
||||
[LocalizedCategory("Access")]
|
||||
[Editor(typeof(GenericDictionaryEditor<ulong, EPermission>), typeof(UITypeEditor))]
|
||||
[JsonProperty(Required = Required.DisallowNull)]
|
||||
public Dictionary<ulong, EPermission> SteamUserPermissions { get; set; } = new Dictionary<ulong, EPermission>();
|
||||
|
||||
[LocalizedCategory("Advanced")]
|
||||
[Editor(typeof(FlagEnumUiEditor), typeof(UITypeEditor))]
|
||||
[JsonProperty(Required = Required.DisallowNull)]
|
||||
@@ -195,6 +193,13 @@ namespace ConfigGenerator {
|
||||
NamesDescending
|
||||
}
|
||||
|
||||
internal enum EPermission : byte {
|
||||
None,
|
||||
FamilySharing,
|
||||
Operator,
|
||||
Master
|
||||
}
|
||||
|
||||
[Flags]
|
||||
internal enum ERedeemingPreferences : byte {
|
||||
None = 0,
|
||||
|
||||
Reference in New Issue
Block a user