diff options
author | boruok <burutarunootoko@gmail.com> | 2021-09-30 22:30:05 +0900 |
---|---|---|
committer | boruok <burutarunootoko@gmail.com> | 2021-09-30 22:30:05 +0900 |
commit | 213612b44a2dcc07156bec8f8919f4d0173a4de2 (patch) | |
tree | 75cceeff8fb1ae5b3ac61105eb9dd16f4ce48f43 | |
parent | 5d6a98f04ef09176cc10e27d788965d76d7ddf09 (diff) |
Fix AtlasTexture get_data() crash
-rw-r--r-- | scene/resources/texture.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/resources/texture.cpp b/scene/resources/texture.cpp index 80cab99373..1b3a7a5f2a 100644 --- a/scene/resources/texture.cpp +++ b/scene/resources/texture.cpp @@ -1249,7 +1249,7 @@ bool AtlasTexture::is_pixel_opaque(int p_x, int p_y) const { } Ref<Image> AtlasTexture::get_image() const { - if (!atlas.is_valid()) { + if (!atlas.is_valid() || !atlas->get_image().is_valid()) { return Ref<Image>(); } |