@casleziro Not related to the question's answer, but have you considered having invisible hitbox actives at 0,0, moving the first object in relation to the second* and checking against that instead? I started wondering of other workarounds when you have listed yours. I have not tested this yet, but in theory it should work.
* By "Moving the first object in relation to the second" I mean:
then... in another event:- Condition preparing for collision check
-> Set Position X of (FirstObject) to X("FirstObject") - X("SecondObject")
-> Set Position Y of (FirstObject) to Y("FirstObject") - Y("SecondObject")
lastly...- Is "FirstObject" overlapping "Second Object's Collision Mask"
-> Your actions
This makes use of the fact that collision masks don't move, therefore, you move the first object in relation to how the collision would actually happen.- Condition after collision check
- > Setting FirstObject's position back to original here
In another similar solution, you could save the position at start of event loop, then when you want to overlap, you move the first object negative of what the second object moved with this expression:
Same for Y. This solution has the advantage of not using an additional object as the collision mask.X("FirstObject") + OldX("SecondObject") - X("SecondObject")
I do not want to derail this thread that is about 2.5+. So perhaps a new thread should be opened up if this is going to be discussed further.