diff --git a/tiled_wall/tiled_wall_data.cpp b/tiled_wall/tiled_wall_data.cpp index 41fe9a1..cb38456 100644 --- a/tiled_wall/tiled_wall_data.cpp +++ b/tiled_wall/tiled_wall_data.cpp @@ -149,6 +149,10 @@ void TiledWallData::add_textures_into(Ref texture_packer) { #endif void TiledWallData::copy_from(const Ref &tiled_wall_data) { + ERR_FAIL_COND(!tiled_wall_data.is_valid()); + + _tiling_type = tiled_wall_data->_tiling_type; + _textures.clear(); for (int i = 0; i < tiled_wall_data->_textures.size(); ++i) {