From 3e75923ab7088c0f07e3933d5caad800972a7845 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D1=80=D0=BA?= <80326524+SmiLeYre@users.noreply.github.com> Date: Sat, 2 Mar 2024 15:24:18 +0500 Subject: [PATCH] E621-Merge (#770) * Update flavor_text.dm Modern, better * Update preferences.dm * Automatic changelog generation for PR #1093 [ci skip] * Automatic changelog compile [ci skip] --------- Co-authored-by: xhianil Co-authored-by: BongaTheProto <93835010+BongaTheProto@users.noreply.github.com> Co-authored-by: SPLURT Bot <97993072+SPLURT-Station-Bot@users.noreply.github.com> Co-authored-by: Changelogs --- code/datums/elements/flavor_text.dm | 4 ++-- code/modules/client/preferences.dm | 4 ++-- html/changelogs/archive/2024-03.yml | 3 +++ 3 files changed, 7 insertions(+), 4 deletions(-) create mode 100644 html/changelogs/archive/2024-03.yml diff --git a/code/datums/elements/flavor_text.dm b/code/datums/elements/flavor_text.dm index 0647c6283f65..b095bca021d4 100644 --- a/code/datums/elements/flavor_text.dm +++ b/code/datums/elements/flavor_text.dm @@ -177,11 +177,11 @@ GLOBAL_LIST_EMPTY(mobs_with_editable_flavor_text) //et tu, hacky code return // Validate the headshot URL - var/static/link_regex = regex("https://i\\.gyazo\\.com|https://media\\.discordapp\\.net|https://cdn\\.discordapp\\.com|https://media\\.discordapp\\.net$") + var/static/link_regex = regex("https://i\\.gyazo\\.com|https://media\\.discordapp\\.net|https://cdn\\.discordapp\\.com|https://media\\.discordapp\\.net$|https://static1\\.e621\\.net") var/static/end_regex = regex("\\.jpg|\\.png|\\.jpeg$") if(!findtext(new_headshot, link_regex)) - to_chat(src, span_warning("The link needs to be an unshortened Gyazo or Discordapp link!")) + to_chat(src, span_warning("The link needs to be an unshortened Gyazo, E621, or Discordapp link!")) return if(!findtext(new_headshot, end_regex)) to_chat(src, span_warning("You need either \".png\", \".jpg\", or \".jpeg\" in the link!")) diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm index f388d884d2b3..805b68aab8f6 100644 --- a/code/modules/client/preferences.dm +++ b/code/modules/client/preferences.dm @@ -4164,11 +4164,11 @@ GLOBAL_LIST_EMPTY(preferences_datums) features["headshot_link"] = null return - var/static/link_regex = regex("https://i.gyazo.com|https://media.discordapp.net|https://cdn.discordapp.com|https://media.discordapp.net$") //Do not touch the damn duplicates. + var/static/link_regex = regex("https://i.gyazo.com|https://media.discordapp.net|https://cdn.discordapp.com|https://media.discordapp.net$|https://static1.e621.net") //Do not touch the damn duplicates. var/static/end_regex = regex(".jpg|.jpg|.png|.jpeg|.jpeg") //Regex is terrible, don't touch the duplicate extensions if(!findtext(usr_input, link_regex, 1, 29)) - to_chat(usr, span_warning("The link needs to be an unshortened Gyazo or Discordapp link!")) + to_chat(usr, span_warning("The link needs to be an unshortened Gyazo, E621, or Discordapp link!")) return if(!findtext(usr_input, end_regex)) to_chat(usr, span_warning("You need either \".png\", \".jpg\", or \".jpeg\" in the link!")) diff --git a/html/changelogs/archive/2024-03.yml b/html/changelogs/archive/2024-03.yml new file mode 100644 index 000000000000..1f58392f7953 --- /dev/null +++ b/html/changelogs/archive/2024-03.yml @@ -0,0 +1,3 @@ +2024-03-02: + xhianil: + - rscadd: Use of E621 for headshots, because literally why not?