* Send an actual chat message. * @param buf The message to send. * @param type The type of destination. * @param dest The actual destination index. */
| 251 | * @param dest The actual destination index. |
| 252 | */ |
| 253 | static void SendChat(std::string_view buf, DestType type, int dest) |
| 254 | { |
| 255 | if (buf.empty()) return; |
| 256 | if (!_network_server) { |
| 257 | MyClient::SendChat((NetworkAction)(NETWORK_ACTION_CHAT + type), type, dest, buf, 0); |
| 258 | } else { |
| 259 | NetworkServerSendChat((NetworkAction)(NETWORK_ACTION_CHAT + type), type, dest, buf, CLIENT_ID_SERVER); |
| 260 | } |
| 261 | } |
| 262 | |
| 263 | class NetworkChatAutoCompletion final : public AutoCompletion { |
| 264 | public: |
no test coverage detected