mirror of
https://github.com/godotengine/godot.git
synced 2024-11-22 12:12:28 +00:00
Merge pull request #47678 from madmiraal/fix-47436.1
Check for empty ConcavePolygonShape2D before checking for intersection
This commit is contained in:
commit
68b28c6cd4
@ -693,6 +693,10 @@ bool ConcavePolygonShape2DSW::contains_point(const Vector2 &p_point) const {
|
||||
}
|
||||
|
||||
bool ConcavePolygonShape2DSW::intersect_segment(const Vector2 &p_begin, const Vector2 &p_end, Vector2 &r_point, Vector2 &r_normal) const {
|
||||
if (segments.size() == 0 || points.size() == 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
uint32_t *stack = (uint32_t *)alloca(sizeof(int) * bvh_depth);
|
||||
|
||||
enum {
|
||||
|
Loading…
Reference in New Issue
Block a user