Add multiplayer dos protection config toggle

This commit is contained in:
NG (Graham) committed 2026-01-12 17:04:41 -05:00
1 parent e76c1a6f3f
commit d421cfa264
4 files changed
+11 -1

No files matched your search

+7
View File
@@ -98,6 +98,8 @@ pub struct ServerSettings {
pub wiki_url: String,
#[serde(default = "default_game_version")]
pub min_version: u32,
#[serde(default = "default_true")]
pub dos_protection: bool,
}
#[derive(Serialize, Deserialize, Clone, Debug, Default)]
@@ -124,6 +126,7 @@ fn default_server_conf() -> ServerSettings {
support_url: default_support_url(),
wiki_url: default_wiki_url(),
min_version: default_game_version(),
dos_protection: default_true(),
}
}
@@ -154,3 +157,7 @@ fn default_wiki_url() -> String {
fn default_game_version() -> u32 {
2855
}
fn default_true() -> bool {
true
}