static func load_texture_from_path(path: String) -> Texture2D: var img = Image.new() var texture = ImageTexture.new() if img.load(path) != OK: print_debug("Cannot load image at path: ", path) return null texture.create_from_image(img) return texture static func deserialize_texture(path: String) -> Texture2D: var file := File.new() if file.open(path, File.READ) != OK: return null var img: Image = file.get_var(true) file.close() var img_tex = ImageTexture.new() img_tex.create_from_image(img) return img_tex