### Godot version

3.5.2 RC2

### System information

Windows 10

### Issue description

If a gridmap is hidden in the editor and `get_tree().reload_current_scene()` is used, the gridmap will reappear on reset. Using `hide()` or `visible = false` in `_ready()` will not work:
![image](https://github.com/godotengine/godot/assets/16231628/1843f94c-1106-4f6a-ba97-4063174d8714)

The only fix is to use:
![image](https://github.com/godotengine/godot/assets/16231628/e2392aa2-3e79-4d43-bc92-0457319a4b60)


```swift
func _ready():
    show()
    hide()
```

### Steps to reproduce

- Add a gridmap node
- Set visibility in editor to false
- Use `get_tree().reload_current_scene()`

### Minimal reproduction project

[brokenhideshow.zip](https://github.com/godotengine/godot/files/12441673/brokenhideshow.zip)

if (!mesh_library.is_null()) {
		mesh_library->disconnect_changed(callable_mp(this, &GridMap::_recreate_octant_data));
	}
	mesh_library = p_mesh_library;
	if (!mesh_library.is_null()) {
		mesh_library->connect_changed(callable_mp(this, &GridMap::_recreate_octant_data));
	}
	_recreate_octant_data();
}
Ref<MeshLibrary> GridMap::get_mesh_library() const {
	return mesh_library;
}
void GridMap::set_cell_size(const Vector3 &p_size) {
	ERR_FAIL_COND(p_size.x < 0.001 || p_size.y < 0.001 || p_size.z < 0.001);
	cell_size = p_size;
	_recreate_octant_data();
	emit_signal(SNAME("cell_size_changed"), cell_size);
}
Vector3 GridMap::get_cell_size() const {
	return cell_size;
}
void GridMap::set_octant_size(int p_size) {
	ERR_FAIL_COND(p_size == 0);
	octant_size = p_size;
	_recreate_octant_data();
}
int GridMap::get_octant_size() const {