1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-07-02 16:38:41 +00:00

Separate anticheat settings (#15040)

This commit is contained in:
Zemtzov7 2024-10-11 15:01:22 +05:00 committed by GitHub
parent d2b4c27f21
commit 1b2d24791a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 47 additions and 8 deletions

View file

@ -2,6 +2,7 @@
// SPDX-License-Identifier: LGPL-2.1-or-later
#include "settings.h"
#include "server.h"
void migrate_settings()
{
@ -19,4 +20,12 @@ void migrate_settings()
g_settings->setBool("touch_gui", value);
g_settings->remove("enable_touch");
}
// Disables anticheat
if (g_settings->existsLocal("disable_anticheat")) {
if (g_settings->getBool("disable_anticheat")) {
g_settings->setFlagStr("anticheat_flags", 0, flagdesc_anticheat);
}
g_settings->remove("disable_anticheat");
}
}