[BDS-18223] is_sneaking == true can no longer be combined with has_equipement in Behavior Packs Created: 22/Mar/23  Updated: 22/Mar/23  Resolved: 22/Mar/23

Status: Resolved
Project: Bedrock Dedicated Server
Affects Version/s: 1.19.71
Fix Version/s: None

Type: Bug
Reporter: Mykroft Assignee: Unassigned
Resolution: Invalid Votes: 0
Labels: None

Confirmation Status: Unconfirmed

 Description   

Attempting to combine a check for is_sneaking true can no longer be combined with a has_equipement check. 

 

A simple repro is to create a new behavior pack with the default snow_golem entity from the 1.19.70.2 samples pack. Change the "interactions" all_of check to:

                  { "test": "has_equipment", "subject": "other", "domain": "hand", "value": "shears"},
                  { "test": "is_family", "subject": "other", "value": "player"},
                  { "test": "is_sneaking", "subject": "other", "value": true },
                  { "test": "has_component", "operator": "!=", "value": "minecraft:is_sheared"}

The expected result here is that the Snow Golem can only be sheared when crouching. The observed result is that the Snow Golem cannot be sheared at all. This also reproduces if the has_equipment domain is changed to "any."

If the conditions are changed to remove has_equipment and keep is_sneaking == true, then the Snow Golem can be sheared when crouching as expected. 



 Comments   
Comment by [MCQA] Kinga Izdebska [ 22/Mar/23 ]

No problem, I'll just resolve this one as Invalid.

Comment by Mykroft [ 22/Mar/23 ]

My apologies - this was accidently opened against BDS when it should be against vanilla Bedrock. This is a duplicate of https://bugs.mojang.com/browse/MCPE-168797, which is in the correct project.

Generated at Sat Jan 11 08:21:01 UTC 2025 using Jira 9.12.2#9120002-sha1:301bf498dd45d800842af0b84230f1bb58606c13.