Class PlayerHistorySettings
- Namespace
- McServerLauncher.Models
- Assembly
- McServerLauncher.dll
What the player history keeps, and for how long. App-wide.
public sealed class PlayerHistorySettings
- Inheritance
-
PlayerHistorySettings
- Inherited Members
Remarks
On by default, with limits that keep it small: at most MaxEventsPerPlayer events per player and nothing older than RetentionDays. That is about 50 KB per player at worst, and far less for most.
There is deliberately no setting for IP addresses, because they are never kept. The server writes one in every login line, and that line is not recorded.
Fields
DefaultDays
public const int DefaultDays = 90
Field Value
DefaultEvents
public const int DefaultEvents = 500
Field Value
MaxDays
public const int MaxDays = 3650
Field Value
MaxEvents
public const int MaxEvents = 5000
Field Value
MinDays
public const int MinDays = 7
Field Value
MinEvents
public const int MinEvents = 50
Field Value
Properties
Enabled
Whether anything is recorded at all.
public bool Enabled { get; set; }
Property Value
MaxEventsPerPlayer
The newest events kept per player; older ones are dropped.
public int MaxEventsPerPlayer { get; set; }
Property Value
RecordChat
Whether what players say in chat is recorded. Joins, leaves and deaths are either way.
public bool RecordChat { get; set; }
Property Value
RetentionDays
Events older than this are dropped, and so are players not seen for this long.
public int RetentionDays { get; set; }
Property Value
Methods
Clamped()
The same settings with every number inside its allowed range.
public PlayerHistorySettings Clamped()
Returns
Remarks
settings.json is a file people can edit; a zero or a negative must not mean "keep nothing".