naia-bevy-server 0.9.0

Library to faciliate naia_server & Bevy interop
1
2
3
4
5
6
7
8
9
use bevy::ecs::entity::Entity;

use naia_server::{ProtocolType, User, UserKey};

pub struct AuthorizationEvent<P: ProtocolType>(pub UserKey, pub P);
pub struct ConnectionEvent(pub UserKey);
pub struct DisconnectionEvent(pub UserKey, pub User);
pub struct MessageEvent<P: ProtocolType>(pub UserKey, pub P);
pub struct CommandEvent<P: ProtocolType>(pub UserKey, pub Entity, pub P);