Skip to main content

yog_event/player/
session.rs

1//! Players joining and leaving.
2
3use yog_data::Schema;
4
5/// Fired when a player joins the server.
6#[derive(Debug, Clone, Schema)]
7pub struct Join {
8    pub player_name: String,
9    /// Player UUID as a string, e.g. `069a79f4-44e9-4726-a5be-fca90e38aaf5`.
10    pub uuid: String,
11    pub dimension: String,
12}
13
14/// Fired when a player leaves the server.
15#[derive(Debug, Clone, Schema)]
16pub struct Leave {
17    pub player_name: String,
18    pub uuid: String,
19    pub dimension: String,
20}