aboutsummaryrefslogtreecommitdiff
path: root/azalea/src
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2025-08-12 11:00:11 -1000
committermat <git@matdoes.dev>2025-08-12 11:00:11 -1000
commit7f4e3c583dd669561e8502822952fc9afe26e005 (patch)
tree831fbcb717493858c31ad58796e01494da276d76 /azalea/src
parentc36c3c0ed02b3727ba61b45a6a7febf1a008a7dc (diff)
downloadazalea-drasl-7f4e3c583dd669561e8502822952fc9afe26e005.tar.xz
add nearest_entity_by and improve some docs
Diffstat (limited to 'azalea/src')
-rw-r--r--azalea/src/container.rs4
-rw-r--r--azalea/src/pathfinder/goto_event.rs5
2 files changed, 7 insertions, 2 deletions
diff --git a/azalea/src/container.rs b/azalea/src/container.rs
index ee618df2..a7b496ea 100644
--- a/azalea/src/container.rs
+++ b/azalea/src/container.rs
@@ -174,7 +174,7 @@ impl ContainerHandleRef {
///
/// Note that any modifications you make to the `Menu` you're given will not
/// actually cause any packets to be sent. If you're trying to modify your
- /// inventory, use [`ContainerHandle::click`] instead
+ /// inventory, use [`Self::click`] instead
pub fn menu(&self) -> Option<Menu> {
let ecs = self.client.ecs.lock();
let inventory = ecs
@@ -224,6 +224,8 @@ impl ContainerHandleRef {
});
}
+ /// Simulate a click in the container and send the packet to perform the
+ /// action.
pub fn click(&self, operation: impl Into<ClickOperation>) {
let operation = operation.into();
self.client.ecs.lock().send_event(ContainerClickEvent {
diff --git a/azalea/src/pathfinder/goto_event.rs b/azalea/src/pathfinder/goto_event.rs
index dfd89122..d87d1586 100644
--- a/azalea/src/pathfinder/goto_event.rs
+++ b/azalea/src/pathfinder/goto_event.rs
@@ -12,7 +12,10 @@ use crate::pathfinder::{
///
/// Also see [`PathfinderClientExt::goto`].
///
-/// This event is read by [`goto_listener`].
+/// This event is read by [`goto_listener`]
+///
+/// [`goto_listener`]: crate::pathfinder::goto_listener
+/// [`PathfinderClientExt::goto`]: crate::pathfinder::PathfinderClientExt::goto
#[derive(Event)]
#[non_exhaustive]
pub struct GotoEvent {