Reviewed October 6, 2026. This page covers the root, registered subcommands and documented internal actions.
Registration permissions
| Registration | Handler | Required status (local DB, Oct 6) | Implementation |
|---|---|---|---|
/castspell |
509 | 200 | Implemented |
Cast a spell ID or search spell names.
Implementation: Implemented.
Syntax
/castspell <spell_id> [tier] [self]
/castspell <spell_name>
Arguments
Position is zero-based in sep, after a registered database subcommand has been removed. Internal action tokens remain at position 0. Angle brackets are required; square brackets are optional. Alternative forms may change field meanings.
| Position | Argument | Accepted value / type | Meaning |
|---|---|---|---|
| 0 | spell |
integer or remaining text | Numeric ID casts; a nonnumeric name searches the database. |
| 1 | tier |
integer | Default 1. |
| 2 | self |
integer | 1 selects self; default 0. |
Behavior and restrictions
- A non-self cast requires an Entity target. This command does not bypass target-type requirements.
Current argument/client/target checks (exact source excerpts; branch-dependent):
if (sep && sep->arg[0] && sep->IsNumber(0))
if (sep->arg[1] && sep->IsNumber(1))
if (sep->arg[1] && sep->IsNumber(2))
if(self != 1 && !cmdTarget->IsEntity())
Handler failure/help feedback (sent to the player or logged; % fields are formatted at runtime):
Target is not an entity required to cast non-self spell.
Permissions
Local database snapshot, October 6, 2026: /castspell requires status 200 (handler 509). Other worlds may configure different values.
The dispatcher checks the resolved registration status before invoking the handler. In-handler guild, group, ownership, client-version and target checks still apply.
Examples
The syntax forms above are the source-based invocation examples. Replace identifiers with values valid for your world; client callback fields are supplied by the game client.
Source evidence
Dispatch: COMMAND_CASTSPELL (handler 509).
WorldServer/Commands/Commands.cpp:4275—COMMAND_CASTSPELL.
Reviewed local revision: 9efddf962ffee075d0db2059d3914c36b0acbdf3; working-tree file checksums identify the exact reviewed bytes. Reviewed dispatch/helper evidence · Reconciliation report.
Original upstream Markdown · Archived original. The original text is historical evidence; the corrected contract above takes precedence.