is_sneaking filter returns 0.0 (false) when player is sneaking & has item in main_hand
To recreate: (allay runtime)
"on_interact": { "filters": { // is a player sneaking? working 1.19.63, broken 1.19.70 "all_of": [ {"test":"is_family", "subject":"other", "operator":"equals", "value":"player"}, {"test":"is_sneaking", "subject":"other", "operator":"equals", "value":true} ] }, "event": "demo:sneak_mode", "target": "self" }, "swing": true, "interact_text": "give", "give":true
expected result and (pre- 1.19.70 update) result: demo:sneak_mode event fires, interactive text appears for game controllers "give"
current result: demo:sneak_mode only fires if player is empty handed. After rigorous testing today, I found out the MOLANG query.is_sneaking is returning a value of 0.0 when player is sneaking, but has item in hand. query.is_sneaking returns 1.0 ONLY if player sneaking AND main_hand is empty.
Only main_hand was checked in my testing. is_sneaking Filters in other components were not examined by me. Again, this was using an allay runtime on an entitly
Linked Issues
is duplicated by2
Created Issue:
MOLANG query.is_sneaking returns 0.0 (false) when player is sneaking & has item in main_hand
To recreate: (allay runtime)
"on_interact": { "filters": { // is a player sneaking? working 1.19.63, broken 1.19.70 "all_of": [ {"test":"is_family", "subject":"other", "operator":"equals", "value":"player"}, {"test":"is_sneaking", "subject":"other", "operator":"equals", "value":true} ] }, "event": "demo:sneak_mode", "target": "self" }, "swing": true, "interact_text": "give", "give":trueexpected result and (pre- 1.19.70 update) result: demo:sneak_mode event fires, interactive text appears for game controllers "player is sneaking"
current result: demo:sneak_mode only fires if player is empty handed. After rigorous testing today, I found out the MOLANG query.is_sneaking is returning a value of 0.0 when player is sneaking, but has item in hand. query.is_sneaking returns 1.0 ONLY if player sneaking AND main_hand is empty.
Only main_hand was checked in my testing. is_sneaking Filters in other components were not examined by me. Again, this was using an allay runtime on an entitly
- Unresolved
- Open
- Unconfirmed
- Windows
- Windows 10
- 1.19.70
To recreate: (allay runtime)
"on_interact": { "filters": { // is a player sneaking? working 1.19.63, broken 1.19.70 "all_of": [ {"test":"is_family", "subject":"other", "operator":"equals", "value":"player"}, {"test":"is_sneaking", "subject":"other", "operator":"equals", "value":true} ] }, "event": "demo:sneak_mode", "target": "self" }, "swing": true, "interact_text": "give", "give":trueexpected result and (pre- 1.19.70 update) result: demo:sneak_mode event fires, interactive text appears for game controllers "
player is sneaking"current result: demo:sneak_mode only fires if player is empty handed. After rigorous testing today, I found out the MOLANG query.is_sneaking is returning a value of 0.0 when player is sneaking, but has item in hand. query.is_sneaking returns 1.0 ONLY if player sneaking AND main_hand is empty.
Only main_hand was checked in my testing. is_sneaking Filters in other components were not examined by me. Again, this was using an allay runtime on an entitly
To recreate: (allay runtime)
"on_interact": { "filters": { // is a player sneaking? working 1.19.63, broken 1.19.70 "all_of": [ {"test":"is_family", "subject":"other", "operator":"equals", "value":"player"}, {"test":"is_sneaking", "subject":"other", "operator":"equals", "value":true} ] }, "event": "demo:sneak_mode", "target": "self" }, "swing": true, "interact_text": "give", "give":trueexpected result and (pre- 1.19.70 update) result: demo:sneak_mode event fires, interactive text appears for game controllers "give"
current result: demo:sneak_mode only fires if player is empty handed. After rigorous testing today, I found out the MOLANG query.is_sneaking is returning a value of 0.0 when player is sneaking, but has item in hand. query.is_sneaking returns 1.0 ONLY if player sneaking AND main_hand is empty.
Only main_hand was checked in my testing. is_sneaking Filters in other components were not examined by me. Again, this was using an allay runtime on an entitly
MOLANG query.is_sneaking returns 0.0 (false) when player is sneaking & has item in main_handis_sneaking filter returns 0.0 (false) when player is sneaking & has item in main_hand
is duplicated by
relates to
is duplicated by
relates to
Duplicate of MCPE-168449
Thank you for your report!
We're tracking this issue in MCPE-168449, so this ticket is being resolved and linked as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
– I am a bot. This action was performed automatically! The ticket was resolved by one of our moderators, and I left this message to give more information to you.
Possibly caused by MCPE-168449.
Thank you for your report!
We're tracking this issue in MCPE-168449, so this ticket is being resolved and linked as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
– I am a bot. This action was performed automatically! The ticket was resolved by one of our moderators, and I left this message to give more information to you.
I've put another 12 hours into this... as a developer, I understand it could just be me or my code. It isn't. It's not the allay runtime either. after removing the runtime in testing, the problem of not being able to detect when a player is_sneaking with filters or queries if holding an item is a bug.
update: it absolutely could be the allay runtime... I've observed the allay is now showing an open dialog when targeting it and sneaking in an empty experimental world. Issue still exists in 1.19.71
1.19.63 did not show this behavior.
It appeared immediately after 1.19.70 was released. I know many are having issues with sneaking and targeting but I'm confident whatever hotfix comes out will address this issue. I'm sure the developers working on the issue are aware this update was a bit premature and not fully baked. I feel your pain folks.
Thank you for your report!
However, this issue has been temporarily closed as Awaiting Response.
Could you please attach an addon where this issue can be observed?
This ticket will automatically reopen when you reply.
Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📓 Project Summary – 📧 Suggestions – 📖 Minecraft Wiki
Please reopen. Problem still exists in 1.19.71. Perhaps that in experimental, when you spawn an allay give them an item and target them while sneaking, you get "open" inventory tip when a controller is connected to PC? This behavior did not exist in 1.19.63. As far as sending you my plug-in, I have moved on, and recoded my add-on to not use is_sneaking. But the bug is legitimate and has been refiled as the allay show inventory "open" dialog. Thank you for your consideration.
The issue cannot be retested without an example addon that shows the incorrect behavior. If possible, please create and attach a simple example addon that can be used to test the issue.
This ticket will automatically reopen when you reply.
understood. but I don't have the bandwidth (time) to create use cases at this point. I've made a simpler example of the allay "open while sneaking" behavior and refiled it here -> MCPE-168748
Have a great day friend.
Use Sneak filter test pack.mcpack
to test. This pack changes sheep shearing to require that the player is sneaking instead of holding shears. Shearing via interaction while sneaking works when the player is empty-handed, but not when the player is holding an item.
test_crouch.mcaddon
I've tested this thoroughly.
The player can no longer interact with an entity while crouching.
The addon I've attached shows that the game is detecting the player crouching and or holding shears. However when interacting with a sheep that requires the player to be crouched in order to shear it, nothing happens.
This has broken several of my most popular packs including marketplace content!
Could you cite specific Marketplace packs/worlds that are broken by this bug?
Nice to see two of my favorite youtubers (FNT and GH) are on this... So If I had a guess, it's an incompatible default behavior combination, in the "minecraft: inventory" component on entities with inventories. MOJANG: Check to see if the flags have been set like this in your runtimes by mistake:
if this is the default setting in MOJANG's code, you'd block interactions because "open" overrides everything, but the inventory is private so nothing can be done by the owner. That's where I'd start to eliminate that component as one of the causes.
Just ran some testing and all crouching interactions to the allay runtime have been removed by devs changing this:
to this:
So technically, I suppose, it's fixed? Just remove all `is_sneaking` interactions... is, well, an interesting tactic. I would have looked for a way to actually fix it, but I guess hiding it so no one can use that interaction on this runtime could be considered a repair. If the door doesn't work, just duct tape it shut. See? fixed.
Anyway, take care. Sincerely. It's a thankless job. I'll see you on discord.gg/Minecraft
I don't think they will fix this bug if it isn't effecting any marketplaces maps.
Unfortunately this affects maps currently on the marketplace by reducing interactivity of items that use interactions while shifting and holding items. They're not always crucial mechanics but they do exist