Hey NAY98!
Here's one way of doing it.
https://www.dropbox.com/s/i2eg7tz0k05a3 ... .capx?dl=1
It's not perfect yet, but it may help you find a solution that suits you...
Hope this helps. Cheers!
my sprite has animations. is there any way to check like the box's -x, +x position collision and move it accordinly like that?