1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
use enums::{FlagCode, PlaneType, PlayerStatus};
use types::{Player, Position, Rotation, Team, Upgrades};

/// Data for a newly-joined player.
#[derive(Clone, Debug)]
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
pub struct PlayerNew {
	pub id: Player,
	pub status: PlayerStatus,
	pub name: String,
	#[cfg_attr(feature = "serde", serde(rename = "type"))]
	pub ty: PlaneType,
	pub team: Team,
	pub pos: Position,
	pub rot: Rotation,
	pub flag: FlagCode,
	pub upgrades: Upgrades,
}