is it possible to get the touch coordinate of two bodies?
I assume you mean collide (not touch; touch implies user input via screen touches).
I think your question is, given two bodies A and B that have collided, can you determine the world coordinates where that collision occurred?
Anyways, I believe the answer is, âYesâ.
- Go the API docs page. Solar2D Documentation â API Reference
- Use your browserâs search function and search for collision.
- You will find a âcollisionâ entry under the events column. Solar2D Documentation â API Reference | Events | collision
- On this page youâll see mention of event.x and event.y. Click either and youâll go this page with an example listener: Solar2D Documentation â API Reference | Events | collision | x
1 Like
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.