From 421d8ce2c837e3140d8f866e63032c277b31a413 Mon Sep 17 00:00:00 2001 From: mat <27899617+mat-1@users.noreply.github.com> Date: Mon, 4 Dec 2023 23:42:49 -0600 Subject: Replace Bevy's FixedUpdate with Azalea's GameTick (#119) * replace bevy FixedUpdate with azalea GameTick * Update to Bevy 0.12.1 --- azalea/examples/nearest_entity.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'azalea/examples') diff --git a/azalea/examples/nearest_entity.rs b/azalea/examples/nearest_entity.rs index 2105d29e..d50e6c46 100644 --- a/azalea/examples/nearest_entity.rs +++ b/azalea/examples/nearest_entity.rs @@ -2,9 +2,10 @@ use azalea::nearest_entity::EntityFinder; use azalea::ClientBuilder; use azalea::{Bot, LookAtEvent}; use azalea_client::Account; +use azalea_core::tick::GameTick; use azalea_entity::metadata::{ItemItem, Player}; use azalea_entity::{EyeHeight, LocalEntity, Position}; -use bevy_app::{FixedUpdate, Plugin}; +use bevy_app::Plugin; use bevy_ecs::{ prelude::{Entity, EventWriter}, query::With, @@ -25,7 +26,7 @@ async fn main() { pub struct LookAtStuffPlugin; impl Plugin for LookAtStuffPlugin { fn build(&self, app: &mut bevy_app::App) { - app.add_systems(FixedUpdate, (look_at_everything, log_nearby_item_drops)); + app.add_systems(GameTick, (look_at_everything, log_nearby_item_drops)); } } -- cgit v1.2.3