From fd1f54697c47f9475d4e6aab5ae63134dca9f676 Mon Sep 17 00:00:00 2001 From: devZoGok Date: Sun, 6 Jul 2025 12:06:01 +0300 Subject: [PATCH] only deleting with initialized textures --- texture.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/texture.cpp b/texture.cpp index 37e29bd..3c072b1 100755 --- a/texture.cpp +++ b/texture.cpp @@ -61,7 +61,7 @@ namespace vb01{ } void Texture::loadImageData(ImageAsset *asset, int i){ - glDeleteTextures(1, &texture[i]); + if(texture) glDeleteTextures(1, &texture[i]); width = asset->width; height = asset->height;