@initiator in npc dialogs only works in /execute when used in the first subcommand. In the second, third, etc. subcommand it won't work. This only applies to @initiator and not @s, @a, etc.
Example:
/execute as @initiator run say hi This command works because @initiator is used in the first subcommand of /execute.
/execute align x as @initiator run say hiThis command doesn't work because @initiator isn't in the first subcommand, so the command won't run as the initiator.
Expected behaviour: @initiator should be valid in every execute subcommand
You can see this behaviour in the world attached. Try out the different buttons in the npc dialog.
Linked issues
Attachments
Comments 2
Thank you for your report!
We're tracking this issue in MCPE-165065, 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.
[^@initiator _execute test-1.mcworld]