-- Squash:
- In progress implementation of services model.
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using Barotrauma.Networking;
|
||||
|
||||
namespace Barotrauma.LuaCs.Configuration;
|
||||
|
||||
public partial interface IConfigBase : IVarId
|
||||
{
|
||||
bool IsInitialized { get; }
|
||||
string GetValue();
|
||||
bool TrySetValue(string value);
|
||||
bool IsAssignable(string value);
|
||||
Type GetValueType();
|
||||
void Initialize(IVarId id, string defaultValue);
|
||||
}
|
||||
|
||||
public interface IVarId
|
||||
{
|
||||
Guid InstanceId { get; }
|
||||
string InternalName { get; }
|
||||
ContentPackage OwnerPackage { get; }
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
using Barotrauma.LuaCs.Networking;
|
||||
|
||||
namespace Barotrauma.LuaCs.Configuration;
|
||||
|
||||
public interface IConfigEntry<T> : IConfigBase, INetVar where T : IConvertible, IEquatable<T>
|
||||
{
|
||||
T Value { get; }
|
||||
bool TrySetValue(T value);
|
||||
bool IsAssignable(T value);
|
||||
void Initialize(IVarId id, T defaultValue);
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
using Barotrauma.LuaCs.Networking;
|
||||
|
||||
namespace Barotrauma.LuaCs.Configuration;
|
||||
|
||||
public interface IConfigList : IConfigBase, INetVar
|
||||
{
|
||||
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
|
||||
namespace Barotrauma.LuaCs.Configuration;
|
||||
|
||||
public interface IConfigRangeEntry<T> : IConfigEntry<T> where T : IConvertible, IEquatable<T>
|
||||
{
|
||||
T MinValue { get; }
|
||||
T MaxValue { get; }
|
||||
|
||||
int GetStepCount();
|
||||
float GetRangeMin();
|
||||
float GetRangeMax();
|
||||
}
|
||||
Reference in New Issue
Block a user