When creating a javascript script with the Beta API, the bool function "isOp" will always return true whether or not the player it is being run on is an operator.
Steps to reproduce:
Create a new behavior pack with a js scripting module
In that module, create a function to output whether or not the player has Op
deop and op yourself in game and see
Attachments
Comments 3
Thank you for your report!
However, this issue has been temporarily closed as Awaiting Response.
Could you please attach an example behavior pack that uses the attached JS file and showcases the issue?
This ticket will automatically reopen when you reply.
Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📓 Project Summary – 📧 Suggestions – 📖 Minecraft Wiki
Cleaning up old tickets: This ticket had been set to 'Awaiting Response', but has not received a response from the reporter (~3 months+) so is being closed as Incomplete. If you feel this is still a valid issue then please comment, or create a new ticket following the Issue Guidelines which includes steps to reproduce the problem.
Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📧 Suggestions – 📖 Minecraft Wiki
I have not worked with the Beta API, but i have worked with javascript before, so if i am wrong please forgive me but
In your code on line 4 console.warn("Player is op:", event.sender.isOp)
You are not running the method, but you are getting the value, this means either the example code or your Title and description are wrong