Continuing with my jigsaw game, I want to test if a piece is near a consecutive piece, and then align them and pin them.
In Visual Basic, I would select CurrentPiece and Piece(Piece(CurrentPiece.LogicalX,LogicalY+1) and then, if they are "close" according to a given tolerance, I would align them and pin them.
But I don't know how to do this in Construct. If I do a "Select All" and then look for the left piece with a condition (Compare Instance Variable LogicalY=StoredLogicalY, Compare Instance Variable LogicalX=StoredLogicalX-1), I lost the focus on the original piece. How can I recover the focus so I can pin the first (lost focus) piece with the new one?
I can't cast a "Piece pin to Piece"
Maybe I should add an invisible object, pin it to the first and then pin it to the other one?