I need an object to touch another object in an if statement. Thanks
How to check if an object is touching another object
- Edited
Shows some code/pseudo code or at least try and paint us a picture in words of just what you are trying to use this for. Whats the actual problem you are trying to solve here?
So we could try and give you the best answer we can.
- Edited
The documentation has examples of how to do collision detection in 2 and 3D, are these not helpful ?
- Edited
- Best Answerset by Barrett
Assuming there's area2D's for both(actually just an area 2D for water should be enough) the player and the 'water' it should be easy via area entered/exited signal. For the sake of your if statement, if signal is not enough you can toggle a boolean variable via the signals and use the boolean state in that if statement.