aboutsummaryrefslogtreecommitdiff
path: root/azalea-chat/src
diff options
context:
space:
mode:
authormat <27899617+mat-1@users.noreply.github.com>2025-09-30 10:56:34 -0500
committerGitHub <noreply@github.com>2025-09-30 10:56:34 -0500
commit643fcb98c0e6cdc63218dd39960d9053b209d9a6 (patch)
tree6bddb7fe39b8fcc3ab3fb2665574533bb227898a /azalea-chat/src
parenta80d8d1b242430c4a251876fa67bfd26af7a0de9 (diff)
downloadazalea-drasl-643fcb98c0e6cdc63218dd39960d9053b209d9a6.tar.xz
1.21.9 (#235)
* start updating to 25w33a * 1.21.9-pre2 * clippy * cleanup, and fix c_explode and c_player_rotation * mc update should be in Changed section in the changelog * 1.21.9
Diffstat (limited to 'azalea-chat/src')
-rw-r--r--azalea-chat/src/component.rs17
1 files changed, 10 insertions, 7 deletions
diff --git a/azalea-chat/src/component.rs b/azalea-chat/src/component.rs
index c7a69390..338c1def 100644
--- a/azalea-chat/src/component.rs
+++ b/azalea-chat/src/component.rs
@@ -356,6 +356,10 @@ impl<'de> Deserialize<'de> for FormattedText {
return Err(de::Error::custom(
"keybind text components aren't yet supported",
));
+ } else if json.get("object").is_some() {
+ return Err(de::Error::custom(
+ "object text components aren't yet supported",
+ ));
} else {
let Some(_nbt) = json.get("nbt") else {
return Err(de::Error::custom(
@@ -551,21 +555,20 @@ impl FormattedText {
FormattedText::Translatable(TranslatableComponent::new(translate, Vec::new()));
}
} else if let Some(score) = compound.compound("score") {
- // object = GsonHelper.getAsJsonObject(jsonObject, "score");
if score.get("name").is_none() || score.get("objective").is_none() {
- // A score component needs at least a name and an objective
trace!("A score component needs at least a name and an objective");
return None;
}
- // TODO, score text components aren't yet supported
+ // TODO: implement these
return None;
} else if compound.get("selector").is_some() {
- // selector text components aren't yet supported
- trace!("selector text components aren't yet supported");
+ trace!("selector text components aren't supported");
return None;
} else if compound.get("keybind").is_some() {
- // keybind text components aren't yet supported
- trace!("keybind text components aren't yet supported");
+ trace!("keybind text components aren't supported");
+ return None;
+ } else if compound.get("object").is_some() {
+ trace!("object text components aren't supported");
return None;
} else if let Some(tag) = compound.get("") {
return FormattedText::from_nbt_tag(tag);