summaryrefslogtreecommitdiff
path: root/include/users.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/users.h')
-rw-r--r--include/users.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/users.h b/include/users.h
index 6a61b2bc1..c699ebab7 100644
--- a/include/users.h
+++ b/include/users.h
@@ -501,10 +501,16 @@ class CoreExport User : public Extensible
*/
void WriteServ(const char* text, ...) CUSTOM_PRINTF(2, 3);
+ /** Sends a command to this user.
+ * @param command The command to be sent.
+ * @param text The message to send.
+ */
+ void WriteCommand(const char* command, const std::string& text);
+
/** Sends a server notice to this user.
* @param text The contents of the message to send.
*/
- void WriteNotice(const std::string& text);
+ void WriteNotice(const std::string& text) { this->WriteCommand("NOTICE", ":" + text); }
void WriteNumeric(unsigned int numeric, const char* text, ...) CUSTOM_PRINTF(3, 4);