#[non_exhaustive]pub struct Vehicle {
pub entity_id: i32,
pub pos: Vec3,
pub yaw: f32,
pub pitch: f32,
pub on_ground: bool,
pub controlled: bool,
}Expand description
The vehicle the player rides (crate::TickContext::vehicle).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.entity_id: i32Its entity id.
pos: Vec3Position after this tick (the client’s, for a vehicle it controls).
yaw: f32Yaw.
pitch: f32Pitch.
on_ground: boolOn the ground.
controlled: boolThe client moves it (a boat) rather than the server (a minecart).
Trait Implementations§
impl Copy for Vehicle
impl StructuralPartialEq for Vehicle
Auto Trait Implementations§
impl Forget for Vehicle
impl Freeze for Vehicle
impl Move for Vehicle
impl RefUnwindSafe for Vehicle
impl Send for Vehicle
impl Sync for Vehicle
impl Unpin for Vehicle
impl UnsafeUnpin for Vehicle
impl UnwindSafe for Vehicle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more