fix: thanks typos
This commit is contained in:
parent
c5c3ffc005
commit
46c048483c
@ -406,7 +406,7 @@ impl Entity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Sets a custom name for the entity, typically used with nametags
|
/// Sets a custom name for the entity, typically used with nametags
|
||||||
pub async fn set_custon_name(&self, name: TextComponent) {
|
pub async fn set_custom_name(&self, name: TextComponent) {
|
||||||
self.send_meta_data(&[Metadata::new(
|
self.send_meta_data(&[Metadata::new(
|
||||||
2,
|
2,
|
||||||
MetaDataType::OptionalTextComponent,
|
MetaDataType::OptionalTextComponent,
|
||||||
|
|||||||
@ -30,7 +30,7 @@ impl ItemBehaviour for NameTagItem {
|
|||||||
&& let Some(name) = item.get_data_component::<CustomNameImpl>()
|
&& let Some(name) = item.get_data_component::<CustomNameImpl>()
|
||||||
{
|
{
|
||||||
// TODO
|
// TODO
|
||||||
entity.set_custon_name(TextComponent::text(name.name)).await;
|
entity.set_custom_name(TextComponent::text(name.name)).await;
|
||||||
item.decrement_unless_creative(player.gamemode.load(), 1);
|
item.decrement_unless_creative(player.gamemode.load(), 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user