I have been stymied by this problem for a couple of months. Because I was just learning MakeCode for Minecraft, I first assumed that either I did not understand Chat arguments or that I had misused them. This problem was exacerbated by the fact it was intermittent, that it, sometimes it happened and sometimes it didn’t.
After much experimentation, I am convinced that the problem is with MakeCode for Minecraft itself, not my code. Yes, I know this sounds ridiculously arrogant, because most of time we coders think a bug is being caused by something outside our program, we are usually wrong.
Consider the two Chat Commands below: moveme and test. Each has two arguments. They differ only in the name of the Chat Command and the names of the arguments. Both programs say the values of the arguments to the Command window.
The Command window shows that test shows the correct values for the arguments, but Moveme shows the arguments as 0 0, not 3 5, which was specified on the on Chat line of code.
Interestingly, if the moveMe Chat Command name is changed, the runs correctly. Even more interestingly as shown in the video above, it the name is changed back to moveMe, the bug reappears.
Get the Code
The code is shared at https://makecode.com/_Kq6TbqFU1Vkh where it can be downloaded and run in MakeCode for Minecraft on Windows 10.