aboutsummaryrefslogtreecommitdiff
path: root/azalea/examples/todo
diff options
context:
space:
mode:
authormat <27899617+mat-1@users.noreply.github.com>2025-12-28 21:54:12 -0600
committerGitHub <noreply@github.com>2025-12-28 21:54:12 -0600
commit39488a6585ce969af93f43ece1ffb1174dc95e1d (patch)
tree49b63b2321b974a7c6425e53b8602a0b4500f092 /azalea/examples/todo
parent25e441944412038da2be4e64854e59169d58305b (diff)
downloadazalea-drasl-39488a6585ce969af93f43ece1ffb1174dc95e1d.tar.xz
Implement `EntityRef` (#299)
* start implementing EntityRef struct * use EntityRef and impl more functions for it * fix doctests * typo * slightly reword some docs * update changelog
Diffstat (limited to 'azalea/examples/todo')
-rw-r--r--azalea/examples/todo/README.md2
-rw-r--r--azalea/examples/todo/pvp.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/azalea/examples/todo/README.md b/azalea/examples/todo/README.md
index ab31cf22..9655617e 100644
--- a/azalea/examples/todo/README.md
+++ b/azalea/examples/todo/README.md
@@ -1 +1 @@
-These examples don't work yet and were only written to help design APIs. They will work in the future (probably with minor changes).
+These examples don't work yet and were only written to help design APIs. They will work in the future (with some changes).
diff --git a/azalea/examples/todo/pvp.rs b/azalea/examples/todo/pvp.rs
index 3c86778f..8da55f3a 100644
--- a/azalea/examples/todo/pvp.rs
+++ b/azalea/examples/todo/pvp.rs
@@ -47,7 +47,7 @@ async fn swarm_handle(swarm: Swarm, event: SwarmEvent, state: SwarmState) -> any
for (bot, bot_state) in swarm {
bot.tick_goto_goal(pathfinder::Goals::Reach(target_bounding_box));
// if target.bounding_box.distance(bot.eyes) < bot.reach_distance() {
- if azalea::entities::can_reach(bot.entity(), target_bounding_box) {
+ if bot.can_reach(target_bounding_box) {
bot.swing();
}
if !bot.using_held_item() && bot.hunger() <= 17 {