mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 08:37:43 +01:00
[MIRROR] Fixes the "Saw this admin message" button not working [MDB IGNORE] (#26107)
* Fixes the "Saw this admin message" button not working (#80908) ## About The Pull Request Wrong fuckin name brother (also topic doesn't automake textnums into nums) ## Why It's Good For The Game Closes #80020 ## Changelog 🆑 admin: Confirming that you have read an admin message now uh, works. it's been 2 years bros /🆑 * Fixes the "Saw this admin message" button not working --------- Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
This commit is contained in:
co-authored by
LemonInTheDark
parent
a0a4f2d900
commit
47f8ddd4b9
@@ -108,6 +108,18 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
|
||||
if (href_list["player_ticket_panel"])
|
||||
view_latest_ticket()
|
||||
return
|
||||
// Admin message
|
||||
if(href_list["messageread"])
|
||||
var/message_id = round(text2num(href_list["messageread"]), 1)
|
||||
if(!isnum(message_id))
|
||||
return
|
||||
var/datum/db_query/query_message_read = SSdbcore.NewQuery(
|
||||
"UPDATE [format_table_name("messages")] SET type = 'message sent' WHERE targetckey = :player_key AND id = :id",
|
||||
list("id" = message_id, "player_key" = usr.ckey)
|
||||
)
|
||||
query_message_read.warn_execute()
|
||||
return
|
||||
|
||||
// TGUIless adminhelp
|
||||
if(href_list["tguiless_adminhelp"])
|
||||
no_tgui_adminhelp(input(src, "Enter your ahelp", "Ahelp") as null|message)
|
||||
@@ -441,9 +453,7 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
|
||||
|
||||
if(holder)
|
||||
add_admin_verbs()
|
||||
var/memo_message = get_message_output("memo")
|
||||
if(memo_message)
|
||||
to_chat(src, memo_message)
|
||||
display_admin_memos(src)
|
||||
adminGreet()
|
||||
if (mob && reconnecting)
|
||||
var/stealth_admin = mob.client?.holder?.fakekey
|
||||
@@ -460,9 +470,7 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
|
||||
if(query_last_connected.warn_execute() && length(query_last_connected.rows))
|
||||
query_last_connected.NextRow()
|
||||
var/time_stamp = query_last_connected.item[1]
|
||||
var/unread_notes = get_message_output("note", ckey, FALSE, time_stamp)
|
||||
if(unread_notes)
|
||||
to_chat(src, unread_notes)
|
||||
display_unread_notes(src, time_stamp)
|
||||
qdel(query_last_connected)
|
||||
|
||||
var/cached_player_age = set_client_age_from_db(tdata) //we have to cache this because other shit may change it and we need it's current value now down below.
|
||||
@@ -491,7 +499,7 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
|
||||
"new_byond_user",
|
||||
"[key_name(src)] (IP: [address], ID: [computer_id]) is a new BYOND account [account_age] day[(account_age == 1?"":"s")] old, created on [account_join_date].[new_player_alert_role ? " <@&[new_player_alert_role]>" : ""]"
|
||||
)
|
||||
get_message_output("watchlist entry", ckey)
|
||||
scream_about_watchlists(src)
|
||||
check_ip_intel()
|
||||
validate_key_in_db()
|
||||
// If we aren't already generating a ban cache, fire off a build request
|
||||
@@ -517,9 +525,7 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
|
||||
|
||||
if(CONFIG_GET(flag/autoconvert_notes))
|
||||
convert_notes_sql(ckey)
|
||||
var/user_messages = get_message_output("message", ckey)
|
||||
if(user_messages)
|
||||
to_chat(src, user_messages)
|
||||
display_admin_messages(src)
|
||||
if(!winexists(src, "asset_cache_browser")) // The client is using a custom skin, tell them.
|
||||
to_chat(src, span_warning("Unable to access asset cache browser, if you are using a custom skin file, please allow DS to download the updated version, if you are not, then make a bug report. This is not a critical issue but can cause issues with resource downloading, as it is impossible to know when extra resources arrived to you."))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user