feat(rust): NPC profile and placement routes, the event picker, triggers and titles (runicnpc stage 4)

Admin: /admin/rust/npcs for profiles (create, change, delete, restore a
replaced one, push now) and each server's placements (list, add from a map
point, change, remove, rename, respawn). Public: the profiles a leaderboard
ranks by, one profile's ranking counted as the profile says (D247, D250), and
one player's kills by profile (D252). Player: your own kills by profile.

The Place NPCs step offers the site's profiles first, then Rust's own
(D243). rust.npc.died and rust.npc.health are triggers a phase can wait on.
A title rule can rank a profile's kills. Swagger fragment, engagement and
route manifests regenerated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01E14m6SuuY6i1vASFeGDBeY
This commit is contained in:
2026-09-30 04:34:43 -05:00
parent 564a234890
commit fa16f0ad2e
20 changed files with 3224 additions and 24 deletions

View File

@@ -527,6 +527,198 @@
}
]
},
{
"id": "rust.npc.died",
"label": "A RunicNPC NPC died",
"description": "One of RunicNPC's NPCs was killed. A phase can wait for a number of them: \"8 guards died\".",
"kind": "event",
"subjectKey": "profile",
"audience": "staff",
"ceiling": "staff",
"version": 1,
"variables": [
{
"name": "serverId",
"type": "string",
"required": true,
"example": "main",
"description": "The server the event happened on, as configured in Admin -> Rust. Also the cooldown subject for broadcasts."
},
{
"name": "server",
"type": "string",
"required": true,
"example": "Runic Gateway | Main",
"description": "The server's display name."
},
{
"name": "serverUrl",
"type": "url",
"required": false,
"example": "/rust/servers/main",
"description": "Site-relative path to the server's page."
},
{
"name": "title",
"type": "string",
"required": false,
"example": "Main is back online",
"description": "A one-line headline naming what happened and where. Core generic bodies use it as the title."
},
{
"name": "intro",
"type": "string",
"required": false,
"example": "Main is back up and taking players.",
"description": "One sentence of detail. Core generic bodies use it as the body."
},
{
"name": "profile",
"type": "string",
"required": true,
"example": "guard",
"description": "The RunicNPC profile the NPC was made from. The cooldown subject, and what a phase gate usually names."
},
{
"name": "npc",
"type": "string",
"required": false,
"example": "Gate Guard",
"description": "The NPC's own name, as the victim's death screen shows it."
},
{
"name": "byEvent",
"type": "boolean",
"required": true,
"example": true,
"description": "Whether an event placed it (rather than an admin's placement or another plugin)."
},
{
"name": "runId",
"type": "string",
"required": false,
"example": "42",
"description": "The event run that placed it, when one did."
},
{
"name": "placement",
"type": "string",
"required": false,
"example": "guard-3",
"description": "The placement it came from, when it came from one."
},
{
"name": "killer",
"type": "string",
"required": false,
"example": "Marisol",
"description": "The player who landed the killing blow. Absent when no player did."
},
{
"name": "killerSteamId",
"type": "string",
"required": false,
"example": "76561198000000002",
"description": "Their Steam id."
},
{
"name": "contributors",
"type": "int",
"required": true,
"example": 3,
"description": "How many players took health from it, the killer included."
}
]
},
{
"id": "rust.npc.health",
"label": "A RunicNPC NPC fell to a health threshold",
"description": "One of RunicNPC's NPCs fell to a fraction of its health its profile names. A phase can wait for \"the boss below 50%\".",
"kind": "event",
"subjectKey": "profile",
"audience": "staff",
"ceiling": "staff",
"version": 1,
"variables": [
{
"name": "serverId",
"type": "string",
"required": true,
"example": "main",
"description": "The server the event happened on, as configured in Admin -> Rust. Also the cooldown subject for broadcasts."
},
{
"name": "server",
"type": "string",
"required": true,
"example": "Runic Gateway | Main",
"description": "The server's display name."
},
{
"name": "serverUrl",
"type": "url",
"required": false,
"example": "/rust/servers/main",
"description": "Site-relative path to the server's page."
},
{
"name": "title",
"type": "string",
"required": false,
"example": "Main is back online",
"description": "A one-line headline naming what happened and where. Core generic bodies use it as the title."
},
{
"name": "intro",
"type": "string",
"required": false,
"example": "Main is back up and taking players.",
"description": "One sentence of detail. Core generic bodies use it as the body."
},
{
"name": "profile",
"type": "string",
"required": true,
"example": "guard",
"description": "The RunicNPC profile the NPC was made from. The cooldown subject, and what a phase gate usually names."
},
{
"name": "npc",
"type": "string",
"required": false,
"example": "Gate Guard",
"description": "The NPC's own name, as the victim's death screen shows it."
},
{
"name": "byEvent",
"type": "boolean",
"required": true,
"example": true,
"description": "Whether an event placed it (rather than an admin's placement or another plugin)."
},
{
"name": "runId",
"type": "string",
"required": false,
"example": "42",
"description": "The event run that placed it, when one did."
},
{
"name": "placement",
"type": "string",
"required": false,
"example": "guard-3",
"description": "The placement it came from, when it came from one."
},
{
"name": "percent",
"type": "int",
"required": true,
"example": 50,
"description": "The threshold it fell to, as a percentage of its health: 50 for half."
}
]
},
{
"id": "rust.player.banned",
"label": "A player was banned",