]> git.smokeofanarchy.ru Git - space-station-14.git/commit
Station news Discord webhook (#36807)
authorssdaniel24 <107036969+ssdaniel24@users.noreply.github.com>
Sat, 10 May 2025 18:21:02 +0000 (21:21 +0300)
committerGitHub <noreply@github.com>
Sat, 10 May 2025 18:21:02 +0000 (11:21 -0700)
commit988152869284706900e6aa5e7f1e5928e5142e16
treeb741d9b49971d82ebc4e969ee746bc3cfc0475fa
parent5c3b613507a14c67549aef5512d53b99cb191108
Station news Discord webhook (#36807)

* Add news article Discord webhook

* Send all station articles on round end

* Changed event subscrice to RoundEndMessageEvent

* Review remarks fix

* Added new cvar discord.news_webhook_embed_color

Default color taken from news manager console sprite.

* Using EntityQueryEnumerator instead of GetStationInMap with TryComp

* Extra review remarks fixing

* Sorted imports

* Added article publication time in embed

* Removed markup from article content

* Added sorting for articles iteration

* Discord hook embed color cvar is string now

* Added comment about limits

* Added new cvar for posting articles during round

* Shitty discord rate limit handling

* Fixing copypaste accident

Co-authored-by: pathetic meowmeow <uhhadd@gmail.com>
* Null initialization of webhook id

* SendArticleToDiscordWebhook is non-void now

---------

Co-authored-by: Morb0 <14136326+Morb0@users.noreply.github.com>
Co-authored-by: pathetic meowmeow <uhhadd@gmail.com>
Content.Server/MassMedia/Systems/NewsSystem.cs
Content.Shared/CCVar/CCVars.Discord.cs
Resources/Locale/en-US/mass-media/news-discord.ftl [new file with mode: 0644]