2023-08-01 15:11:52 -04:00
|
|
|
|
namespace BattleBitAPI.Server
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
public class ServerSettings<TPlayer> where TPlayer : Player<TPlayer>
|
2023-08-01 15:11:52 -04:00
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
private GameServer<TPlayer>.Internal mResources;
|
|
|
|
|
public ServerSettings(GameServer<TPlayer>.Internal resources)
|
2023-08-01 15:11:52 -04:00
|
|
|
|
{
|
|
|
|
|
mResources = resources;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public float DamageMultiplier
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.DamageMultiplier;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.DamageMultiplier = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool BleedingEnabled
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.BleedingEnabled;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.BleedingEnabled = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool StamineEnabled
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.StamineEnabled;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.StamineEnabled = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool FriendlyFireEnabled
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.FriendlyFireEnabled;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.FriendlyFireEnabled = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool OnlyWinnerTeamCanVote
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.OnlyWinnerTeamCanVote;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.OnlyWinnerTeamCanVote = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool HitMarkersEnabled
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.HitMarkersEnabled;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.HitMarkersEnabled = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool PointLogEnabled
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.PointLogEnabled;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.PointLogEnabled = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public bool SpectatorEnabled
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
get => mResources._Settings.SpectatorEnabled;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
set
|
|
|
|
|
{
|
2023-08-11 04:04:47 -04:00
|
|
|
|
mResources._Settings.SpectatorEnabled = value;
|
2023-08-01 15:11:52 -04:00
|
|
|
|
mResources.IsDirtySettings = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
2023-08-10 18:38:29 -04:00
|
|
|
|
|
2023-08-11 04:04:47 -04:00
|
|
|
|
public void Reset()
|
|
|
|
|
{
|
2023-08-10 18:38:29 -04:00
|
|
|
|
|
2023-08-11 04:04:47 -04:00
|
|
|
|
}
|
2023-08-01 15:11:52 -04:00
|
|
|
|
}
|
|
|
|
|
}
|