* Send a chat message. * @param action The action associated with the message. * @param desttype The destination type. * @param client_id The origin of the chat message. * @param msg The actual message. * @param data Arbitrary extra data. */
| 441 | * @param data Arbitrary extra data. |
| 442 | */ |
| 443 | NetworkRecvStatus ServerNetworkAdminSocketHandler::SendChat(NetworkAction action, DestType desttype, ClientID client_id, std::string_view msg, int64_t data) |
| 444 | { |
| 445 | auto p = std::make_unique<Packet>(this, ADMIN_PACKET_SERVER_CHAT); |
| 446 | |
| 447 | p->Send_uint8 (action); |
| 448 | p->Send_uint8 (desttype); |
| 449 | p->Send_uint32(client_id); |
| 450 | p->Send_string(msg); |
| 451 | p->Send_uint64(data); |
| 452 | |
| 453 | this->SendPacket(std::move(p)); |
| 454 | return NETWORK_RECV_STATUS_OKAY; |
| 455 | } |
| 456 | |
| 457 | /** |
| 458 | * Send a notification indicating the rcon command has completed. |
no test coverage detected