action
Synopsis
/ctcp <target> action <action-description>
Description
CTCP action carries an action description, as used by describe and me. Prefer those commands for ordinary use: they provide action-specific local display and the on send_action hook. Sending /ctcp <target> action ... directly sends the protocol message but does not invoke on send_action or provide that action-specific local echo.
<target> is the destination accepted by ctcp, normally a nickname or channel. * selects the current channel, not the current query. The remaining text is the action description; there are no action-specific options. Use a nonempty description: the incoming built-in handler silently ignores an empty one.
In ordinary use, EPIC sends a CTCP-delimited action payload inside an IRC privmsg. The generic ctcp command instead uses notice when invoked while processing a private-message event and rejects invocation from a notice event with You may not use the CTCP command from a NOTICE!. A live connection, valid target, and any required channel permissions are needed for delivery; server policy determines rejection or filtering. Long outgoing payloads are truncated to the sender's available IRC message space.
Receiving actions
The built-in handler is enabled by default and handles both request and reply forms without sending an automatic response. A received nonempty action invokes on action with the sender, destination, and description. If that hook permits normal display, EPIC prints:
* sender descriptionfor the current channel.* sender:channel descriptionfor another channel.*> sender descriptionfor a non-channel destination.
Action output uses the action message level. Script CTCP handlers or hooks can replace or suppress the normal behavior. The general CTCP parser can also discard payloads before this handler runs, including messages with more than eight CTCP delimiter characters and messages to a # channel the client has not joined.
Examples
/me waves
/describe #example waves
/ctcp #example action waves
The first sends an action to the current window's target. The second sends one to #example with the command's action echo and hook. The third sends the CTCP directly through the generic command.
Source references
source/ctcp.c:init_ctcp,do_atmosphere,do_ctcp, andsend_ctcpimplement registration, receiving, parser limits, encoding, framing, and sending.source/commands.c:ctcpcmd,describe, andmecmdimplement destination selection and distinguish generic CTCP sending from action-specific hooks and echoes.