Fixed potential crash when touchscreenbutton has no texture assigned
This commit is contained in:
parent
b1e03d536f
commit
568be61b09
@ -170,7 +170,8 @@ void TouchScreenButton::_input(const InputEvent& p_event) {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
touched=Rect2(Point2(),texture->get_size()).has_point(coord);
|
if (texture.is_valid())
|
||||||
|
touched=Rect2(Point2(),texture->get_size()).has_point(coord);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user