chunkedge_protocol/packets/play/cookie_response_c2s.rs
1use std::borrow::Cow;
2
3use chunkedge_binary::{Bounded, Decode, Encode};
4use chunkedge_ident::Ident;
5
6use crate::Packet;
7
8#[derive(Clone, Debug, Encode, Decode, Packet)]
9/// Sent by the client to the server to respond to a
10/// [`CookieRequestS2c`](crate::packets::play::CookieRequestS2c) packet.
11pub struct CookieResponseC2s<'a> {
12 pub key: Ident<Cow<'a, str>>,
13 pub payload: Option<Bounded<&'a [u8], 5120>>,
14}