Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | Vercte |
Hello! I’m fairly new to the engine.
I’m trying to get which sides an Area2d is overlapped by, so I can push the player back if they’re walking into a wall.
Is there a specific way I can do this?
This ?
https://forum.godotengine.org/115197/what-is-overlaps_area-argument-for-all-area2d-nodes?show=115234
ramazan | 2022-03-25 08:58
I’m trying to get which sides it overlaps (e.g. left, right, bottom, top), not what it overlaps. Thank you for looking around a bit, though!
Vercte | 2022-03-25 20:58
I guess Area2d has no collision points
Getting the global_position of the object entering the Area
Of course, there are other solutions as well.
ramazan | 2022-03-26 09:30