few updates

This commit is contained in:
2025-03-17 11:54:45 +01:00
parent 2eaa843016
commit 73653723ea
4 changed files with 44 additions and 9 deletions
+10 -2
View File
@@ -4,7 +4,11 @@ pub type Result<T = Response> = std::result::Result<T, Error>;
pub enum Response {
Pong,
Success,
Player { cloak: String, uuid: String },
Player {
cloak: String,
uuid: String,
cloaks: Vec<String>,
},
}
impl std::fmt::Display for Response {
@@ -12,7 +16,11 @@ impl std::fmt::Display for Response {
match self {
Response::Pong => write!(f, "Pong"),
Response::Success => write!(f, "Success"),
Response::Player { cloak, uuid } => write!(f, "@cloak={cloak}@uuid={uuid}"),
Response::Player {
cloak,
uuid,
cloaks,
} => write!(f, "@cloak={cloak}@uuid={uuid}@cloaks={}", cloaks.join("$")),
}
}
}