mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-21 04:57:57 +01:00
Adds logging of the station manifest to the DB (#90993)
This adds a `manifest` table to the database, basically a databasified version of the `manifest.txt` log. This is less of a game feature and more of an admin & Statbus tool. We currently do not have a good way to see who played which character in a given round. This aims to fix that. ~~Drafted because I'm not sure on some of the typecasting for the `special` and `latejoin` columns, I would like someone to give that a once-over.~~ We good.
This commit is contained in:
@@ -427,3 +427,34 @@ Versioning
|
||||
if(query_report_citation)
|
||||
query_report_citation.Execute(async = TRUE)
|
||||
qdel(query_report_citation)
|
||||
|
||||
/datum/controller/subsystem/blackbox/proc/ReportManifest(ckey, character, job, special, latejoin)
|
||||
var/datum/db_query/query_report_manifest = SSdbcore.NewQuery({"INSERT INTO [format_table_name("manifest")]
|
||||
(server_ip,
|
||||
server_port,
|
||||
round_id,
|
||||
ckey,
|
||||
character,
|
||||
job,
|
||||
special,
|
||||
latejoin) VALUES (
|
||||
INET_ATON(:server_ip,
|
||||
:port,
|
||||
:round_id,
|
||||
:ckey,
|
||||
:character,
|
||||
:job,
|
||||
:special,
|
||||
:latejoin)
|
||||
"}, list(
|
||||
"server_ip" = world.internet_address || "0",
|
||||
"port" = "[world.port]",
|
||||
"round_id" = GLOB.round_id,
|
||||
"ckey" = ckey,
|
||||
"job" = job,
|
||||
"special" = special,
|
||||
"latejoin" = latejoin
|
||||
))
|
||||
if(query_report_manifest)
|
||||
query_report_manifest.Execute(async = TRUE)
|
||||
qdel(query_report_manifest)
|
||||
|
||||
Reference in New Issue
Block a user