From 8bc4e8bf3b7b2a3b2c8148a0eb8c2164f843a422 Mon Sep 17 00:00:00 2001 From: mat Date: Sat, 25 Jun 2022 19:38:27 -0500 Subject: [PATCH] Put physics module in azalea-entity --- azalea-entity/README.md | 3 +++ azalea-entity/src/lib.rs | 1 + azalea-entity/src/physics/mod.rs | 14 ++++++++++++++ 3 files changed, 18 insertions(+) create mode 100644 azalea-entity/README.md create mode 100644 azalea-entity/src/physics/mod.rs diff --git a/azalea-entity/README.md b/azalea-entity/README.md new file mode 100644 index 00000000..f805c0d2 --- /dev/null +++ b/azalea-entity/README.md @@ -0,0 +1,3 @@ +# Azalea Entity + +An implementation of Minecraft entities and entity physics. diff --git a/azalea-entity/src/lib.rs b/azalea-entity/src/lib.rs index 9436d753..18bb8b2e 100644 --- a/azalea-entity/src/lib.rs +++ b/azalea-entity/src/lib.rs @@ -1,4 +1,5 @@ mod data; +mod physics; use azalea_core::{EntityPos, PositionDelta}; pub use data::*; diff --git a/azalea-entity/src/physics/mod.rs b/azalea-entity/src/physics/mod.rs new file mode 100644 index 00000000..473adbae --- /dev/null +++ b/azalea-entity/src/physics/mod.rs @@ -0,0 +1,14 @@ +use crate::Entity; +use azalea_core::PositionDelta; + +pub enum MoverType { + Own, + Player, + Piston, + ShulkerBox, + Shulker, +} + +impl Entity { + pub fn move_entity(&mut self, mover_type: &MoverType, movement: &PositionDelta) {} +}