SQL Saving - Rewrite + Implenetation (#350)

Rewrite's Mahzel's SQL character and preference saving.
Introduces easy config switching between the new and old system, with no troubles at all.

Also introduces better logging for DBQuery/proc/parseArguments(), should something go wrong. And classes SQL query errors as full on error snow, as opposed to debug data.
This commit is contained in:
skull132
2016-05-30 23:39:07 +03:00
parent 6881213b75
commit 7dacaa28dd
21 changed files with 1333 additions and 1339 deletions
+5 -1
View File
@@ -155,7 +155,8 @@ var/list/gamemode_cache = list()
var/admin_legacy_system = 0 //Defines whether the server uses the legacy admin system with admins.txt or the SQL system. Config option in config.txt
var/ban_legacy_system = 0 //Defines whether the server uses the legacy banning system with the files in /data or the SQL system. Config option in config.txt
var/use_age_restriction_for_jobs = 0 //Do jobs use account age restrictions? --requires database
var/sql_whitelists = 0 //Defined whether the server uses an SQL based whitelist system, or the legacy one with two .txts. Config option in config.txt
var/sql_whitelists = 0 //Defined whether the server uses an SQL based whitelist system, or the legacy one with two .txts. Config option in config.txt
var/sql_saves = 0 //Defines whether the server uses an SQL based character and preference saving system. Config option in config.txt
var/simultaneous_pm_warning_timeout = 100
@@ -684,6 +685,9 @@ var/list/gamemode_cache = list()
if("webint_url")
config.webint_url = value
if("sql_saves")
config.sql_saves = 1
else
log_misc("Unknown setting in configuration: '[name]'")