Changelog Overhaul (#13051)

* Changelog Overhaul

* SQL Update

* This is why I hate merge conflicts

* Comment Correction

* Farie Fixes + Tested with blank DB

* Colours + Titles

* Colour tweaks

* I fell victim to my own CI Chains!

* Cleans up the remains of the old changelogs

* Fixes formatting

* Kyet Changes

* Date
This commit is contained in:
AffectedArc07
2020-05-18 08:34:28 +01:00
committed by GitHub
parent b2b12c36e8
commit 7ea6f190c5
62 changed files with 15167 additions and 14542 deletions
@@ -79,7 +79,7 @@ GLOBAL_LIST_INIT(special_role_times, list( //minimum age (in days) for accounts
var/last_id
//game-preferences
var/lastchangelog = "" //Saved changlog filesize to detect if there was a change
var/lastchangelog = "1" //Saved changlog timestamp (unix epoch) to detect if there was a change. Dont set this to 0 unless you want the last changelog date to be 4x longer than the expected lifespan of the universe.
var/exp
var/ooccolor = "#b82e00"
var/list/be_special = list() //Special role selection
@@ -491,18 +491,3 @@
load_character(C,pick(saves))
return 1
/datum/preferences/proc/SetChangelog(client/C,hash)
lastchangelog=hash
var/datum/preferences/P = GLOB.preferences_datums[C.ckey]
if(P.toggles & UI_DARKMODE)
winset(C, "rpane.changelog", "background-color=#40628a;font-color=#ffffff;font-style=none")
else
winset(C, "rpane.changelog", "background-color=none;font-style=none")
var/DBQuery/query = GLOB.dbcon.NewQuery("UPDATE [format_table_name("player")] SET lastchangelog='[lastchangelog]' WHERE ckey='[C.ckey]'")
if(!query.Execute())
var/err = query.ErrorMsg()
log_game("SQL ERROR during lastchangelog updating. Error : \[[err]\]\n")
message_admins("SQL ERROR during lastchangelog updating. Error : \[[err]\]\n")
to_chat(C, "Couldn't update your last seen changelog, please try again later.")
return
return 1