2022-04-15 07:55:45 +10:00
|
|
|
#![forbid(unsafe_code)]
|
2022-04-29 17:48:41 +10:00
|
|
|
#![warn(
|
|
|
|
trivial_casts,
|
|
|
|
trivial_numeric_casts,
|
|
|
|
unused_lifetimes,
|
|
|
|
unused_import_braces,
|
2022-05-16 19:36:14 +10:00
|
|
|
// missing_docs
|
2022-04-29 17:48:41 +10:00
|
|
|
)]
|
2022-04-15 07:55:45 +10:00
|
|
|
|
2022-06-10 13:26:21 +10:00
|
|
|
pub mod biome;
|
2022-04-18 10:06:13 +10:00
|
|
|
pub mod block;
|
2022-04-15 07:55:45 +10:00
|
|
|
mod block_pos;
|
2022-06-13 19:34:03 +10:00
|
|
|
mod bvh;
|
2022-04-29 17:48:41 +10:00
|
|
|
pub mod chunk;
|
2022-06-28 10:52:23 +10:00
|
|
|
mod chunk_pos;
|
2022-04-29 17:48:41 +10:00
|
|
|
pub mod client;
|
2022-04-15 07:55:45 +10:00
|
|
|
pub mod config;
|
2022-06-10 13:26:21 +10:00
|
|
|
pub mod dimension;
|
2022-04-15 07:55:45 +10:00
|
|
|
pub mod entity;
|
2022-06-10 13:26:21 +10:00
|
|
|
pub mod ident;
|
2022-06-28 10:52:23 +10:00
|
|
|
mod player_list;
|
2022-06-30 04:09:00 +10:00
|
|
|
pub mod player_textures;
|
2022-07-01 04:53:57 +10:00
|
|
|
#[cfg(not(feature = "protocol"))]
|
2022-07-02 08:29:31 +10:00
|
|
|
#[allow(unused)]
|
2022-04-15 07:55:45 +10:00
|
|
|
mod protocol;
|
2022-07-01 04:53:57 +10:00
|
|
|
#[cfg(feature = "protocol")]
|
|
|
|
pub mod protocol;
|
2022-04-29 17:48:41 +10:00
|
|
|
pub mod server;
|
|
|
|
mod slotmap;
|
2022-07-01 04:53:57 +10:00
|
|
|
mod spatial_index;
|
2022-04-15 07:55:45 +10:00
|
|
|
pub mod text;
|
|
|
|
pub mod util;
|
2022-04-29 17:48:41 +10:00
|
|
|
pub mod world;
|
2022-04-15 07:55:45 +10:00
|
|
|
|
2022-04-30 22:06:20 +10:00
|
|
|
pub use async_trait::async_trait;
|
2022-07-07 11:27:59 +10:00
|
|
|
pub use server::start_server;
|
2022-06-30 04:09:00 +10:00
|
|
|
pub use spatial_index::SpatialIndex;
|
2022-05-16 21:09:51 +10:00
|
|
|
pub use {nbt, uuid, vek};
|
2022-04-15 07:55:45 +10:00
|
|
|
|
|
|
|
/// The Minecraft protocol version that this library targets.
|
2022-06-21 21:55:32 +10:00
|
|
|
pub const PROTOCOL_VERSION: i32 = 759;
|
2022-04-15 07:55:45 +10:00
|
|
|
/// The name of the Minecraft version that this library targets.
|
2022-06-21 21:55:32 +10:00
|
|
|
pub const VERSION_NAME: &str = "1.19";
|
2022-04-15 07:55:45 +10:00
|
|
|
|
|
|
|
/// The namespace for this library used internally for namespaced identifiers.
|
|
|
|
const LIBRARY_NAMESPACE: &str = "valence";
|
|
|
|
|
|
|
|
/// A discrete unit of time where 1 tick is the duration of a
|
|
|
|
/// single game update.
|
|
|
|
///
|
|
|
|
/// The duration of a game update depends on the current configuration, which
|
|
|
|
/// may or may not be the same as Minecraft's standard 20 ticks/second.
|
|
|
|
pub type Ticks = i64;
|