I have seen many of these tweening codes on Scratch before, so I had some research from Google! This definitely helped and I balanced the parameters of X, Y, direction, and tween velocity!
I also made a sprite pack where it contains the code for the tweening animation! Hope this helped for your animations too!