darth sure. For trigger use an app, so the mouse will spawn in that app, or use blank trigger (in macrodroid option i think).
For action use shell script (in macrodroid options i think) And put the command jumptoheaven posted (you can skip --user 0, click root.
It works. If you use blank trigger, use button mapper shortcut option to toggle it