Drag and drop game

Good afternoon everyone, I’m new to playcanvas and I don’t know how to solve this. I need to make a game where there are cards on the 2D screen that must be placed in a certain order on a position marker, once the cards are arranged the button to send results must be enabled and if check that they are in the correct position, according to the position the screen shows a correct or incorrect image, if it is incorrect a retry button should appear (in the same place where the button that sends the results is) and pressing it should return the cards to their initial position.

Use the scripts in this example to drag and drop the cards

Here is the link to my project

Thank you!

At the moment, the only way I can think of is to get the position of the elements, scale them by the screen’s resolution width and height and do a rectangle to rectangle check with the element that is being dragged using the width and height of the element.