Files
GS13NG/datum/tgs_chat_command.html
2025-02-05 06:19:18 +00:00

7 lines
4.8 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><base href="../"><link rel="stylesheet" href="dmdoc.css"><title>/datum/tgs_chat_command - /tg/ Station 13</title></head><body><header><a href="index.html">/tg/ Station 13</a> - <a href="index.html#modules">Modules</a> - <a href="index.html#types">Types</a><a href="datum/tgs_chat_command.html#var">Var Details</a> - <a href="datum/tgs_chat_command.html#proc">Proc Details</a></header><main><h1>tgs_chat_command <aside>/<a href="datum.html">datum</a>/<a href="datum/tgs_chat_command.html">tgs_chat_command</a></aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/__DEFINES/tgs.dm#L321"><img src="git.png" width="16" height="16" title="code/__DEFINES/tgs.dm 321"></a></h1><p>User definable chat command. This abstract version MUST be overridden to be used.</p><table class="summary" cellspacing="0"><tr><td colspan="2"><h2>Vars</h2></td></tr><tr><th><a href="datum/tgs_chat_command.html#var/admin_only">admin_only</a></th><td>If this command should be available to game administrators only.</td></tr><tr><th><a href="datum/tgs_chat_command.html#var/help_text">help_text</a></th><td>The help text displayed for this command.</td></tr><tr><th><a href="datum/tgs_chat_command.html#var/ignore_type">ignore_type</a></th><td>A subtype of <a href="datum/tgs_chat_command.html" title="/datum/tgs_chat_command">/datum/tgs_chat_command</a> that is ignored when enumerating available commands. Use this to create shared base /datums for commands.</td></tr><tr><th><a href="datum/tgs_chat_command.html#var/name">name</a></th><td>The string to trigger this command on a chat bot. e.g <code>@bot name ...</code> or <code>!tgs name ...</code>.</td></tr><tr><td colspan="2"><h2>Procs</h2></td></tr><tr><th><a href="datum/tgs_chat_command.html#proc/Run">Run</a></th><td>Process command activation. Should return a <a href="datum/tgs_message_content.html" title="/datum/tgs_message_content">/datum/tgs_message_content</a> to respond to the issuer with.
MUST be implemented</td></tr></table><h2 id="var">Var Details</h2><h3 id="var/admin_only"><aside class="declaration">var </aside>admin_only <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/__DEFINES/tgs.dm#L327"><img src="git.png" width="16" height="16" title="code/__DEFINES/tgs.dm 327"></a></h3><p>If this command should be available to game administrators only.</p><h3 id="var/help_text"><aside class="declaration">var </aside>help_text <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/__DEFINES/tgs.dm#L325"><img src="git.png" width="16" height="16" title="code/__DEFINES/tgs.dm 325"></a></h3><p>The help text displayed for this command.</p><h3 id="var/ignore_type"><aside class="declaration">var </aside>ignore_type <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/__DEFINES/tgs.dm#L331"><img src="git.png" width="16" height="16" title="code/__DEFINES/tgs.dm 331"></a></h3><p>A subtype of <a href="datum/tgs_chat_command.html" title="/datum/tgs_chat_command">/datum/tgs_chat_command</a> that is ignored when enumerating available commands. Use this to create shared base /datums for commands.</p><h3 id="var/name"><aside class="declaration">var </aside>name <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/__DEFINES/tgs.dm#L323"><img src="git.png" width="16" height="16" title="code/__DEFINES/tgs.dm 323"></a></h3><p>The string to trigger this command on a chat bot. e.g <code>@bot name ...</code> or <code>!tgs name ...</code>.</p><h2 id="proc">Proc Details</h2><h3 id="proc/Run"><aside class="declaration">proc </aside>Run<aside>(/<a href="datum.html">datum</a>/<a href="datum/tgs_chat_user.html">tgs_chat_user</a>/sender, params) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/__DEFINES/tgs.dm#L338"><img src="git.png" width="16" height="16" title="code/__DEFINES/tgs.dm 338"></a></aside></h3><p>Process command activation. Should return a <a href="datum/tgs_message_content.html" title="/datum/tgs_message_content">/datum/tgs_message_content</a> to respond to the issuer with.
MUST be implemented</p>
<ul>
<li>sender - The <a href="datum/tgs_chat_user.html" title="/datum/tgs_chat_user">/datum/tgs_chat_user</a> who issued the command.</li>
<li>params - The trimmed string following the command `/datum/tgs_chat_command/var/name].</li>
</ul></main><footer>tgstation.dme <a href="https://github.com/evilew/GS13-Citadel/tree/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e">e8e0068</a> (master) — <a href="https://github.com/SpaceManiac/SpacemanDMM/blob/master/crates/dmdoc/README.md">dmdoc 1.9.0</a></footer></body></html>