[PR #6518] [MERGED] Native mods: post an announce event to the Discord bridge #6929

Closed
opened 2026-11-03 06:29:23 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/6518
Author: @xFedeT
Created: 11/1/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: feat/native-server-announce


📝 Commits (1)

  • b7e0192 Native mods: native_server_event posts an announce event the Discord bridge relays

📊 Changes

5 files changed (+44 additions, -3 deletions)

View changed files

📝 crates/horizon-client/src/game/native_server.rs (+12 -0)
📝 crates/horizon-server/src/discord.rs (+23 -1)
📝 docs/hosting.md (+1 -1)
📝 docs/native-mods.md (+2 -1)
➕ tools/native-hook-fragments/server_event.json (+6 -0)

📄 Description

🤖 Opened by xFedeT's AI agent (Claude Code, Sonnet 5.5), not by xFedeT personally.

Fixes #6206

  • native_server_event(name, uuid, message) (game/native_server.rs): records an announce event through dedicated::events::record on a dedicated server; false elsewhere and for an empty message.
  • horizon-server: announce is a Discord event kind (EVENTS), drawn in gold like a broadcast, § codes honoured, @ defused like chat. Off by default ([discord] events unchanged).
  • Docs (hosting.md, native-mods.md) and a hook fragment (server_event.json, helper only).

Tested: cargo test -p horizon-server discord (new test: gold runs, no @everyone, announce accepted in settings). The game helper has no test of its own: it is one guarded call to events::record, which already has one.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/6518 **Author:** [@xFedeT](https://github.com/xFedeT) **Created:** 11/1/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `feat/native-server-announce` --- ### 📝 Commits (1) - [`b7e0192`](https://github.com/horizon-rust/horizon/commit/b7e01926a2de54df09bd1e6e979bf12c29b77092) Native mods: native_server_event posts an announce event the Discord bridge relays ### 📊 Changes **5 files changed** (+44 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game/native_server.rs` (+12 -0) 📝 `crates/horizon-server/src/discord.rs` (+23 -1) 📝 `docs/hosting.md` (+1 -1) 📝 `docs/native-mods.md` (+2 -1) ➕ `tools/native-hook-fragments/server_event.json` (+6 -0) </details> ### 📄 Description > 🤖 Opened by xFedeT's AI agent (Claude Code, Sonnet 5.5), not by xFedeT personally. Fixes #6206 - `native_server_event(name, uuid, message)` (`game/native_server.rs`): records an `announce` event through `dedicated::events::record` on a dedicated server; false elsewhere and for an empty message. - horizon-server: `announce` is a Discord event kind (`EVENTS`), drawn in gold like a broadcast, `§` codes honoured, `@` defused like chat. Off by default (`[discord] events` unchanged). - Docs (`hosting.md`, `native-mods.md`) and a hook fragment (`server_event.json`, helper only). Tested: `cargo test -p horizon-server discord` (new test: gold runs, no `@everyone`, `announce` accepted in settings). The game helper has no test of its own: it is one guarded call to `events::record`, which already has one. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 06:29:23 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#6929
No description provided.