aboutsummaryrefslogtreecommitdiff
path: root/azalea/src/client_impl
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2026-05-06 18:38:23 -0545
committermat <git@matdoes.dev>2026-05-07 08:05:58 -1200
commitcabc8b60a729ba17f5b75f7a7956c6d1ddcc8919 (patch)
tree237fd12a9768fe7431ce42dfbdde60f4c7850e06 /azalea/src/client_impl
parent9ffd0e80bbb3feace231553d6539124585b03e3c (diff)
downloadazalea-drasl-cabc8b60a729ba17f5b75f7a7956c6d1ddcc8919.tar.xz
azalea-brigadier now allows commands to return a Result
Diffstat (limited to 'azalea/src/client_impl')
-rw-r--r--azalea/src/client_impl/mod.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/azalea/src/client_impl/mod.rs b/azalea/src/client_impl/mod.rs
index ba78fee4..e0718375 100644
--- a/azalea/src/client_impl/mod.rs
+++ b/azalea/src/client_impl/mod.rs
@@ -355,9 +355,10 @@ impl Client {
///
/// ```
/// # use azalea_core::position::ChunkPos;
- /// # fn example(client: &azalea::Client) {
- /// let world = client.partial_world();
+ /// # fn example(client: &azalea::Client) -> azalea::error::AzaleaResult<()> {
+ /// let world = client.partial_world()?;
/// let is_0_0_loaded = world.read().chunks.limited_get(&ChunkPos::new(0, 0)).is_some();
+ /// # Ok(())
/// # }
pub fn partial_world(&self) -> AzaleaResult<Arc<RwLock<PartialWorld>>> {
let world_holder = self.component::<WorldHolder>()?;