great news you managed it
I also got it working with a similar method a few hours ago but still had struggle to clean it up a little.
You could move your
- Clear saved object
- Set standard command
under the if/else and remove the else branch completely by the way because of redundancy
Will do also a video about it in a few weeks (after i did a lua crash course for the viewers).