Terrain WriteVoxel ignores Air material voxels

My game has a major feature that allows players to terraform their settlement. This uses the WriteVoxel function in Terrains.

Starting 3/20/2023, users are reporting that “digging” no longer works. I traced it down to WriteVoxel calls with Material.Air voxels in the material array are no longer affecting the terrain. In other words, the voxels previously filled with some material (e.g. Ground) are no longer being emptied out, as was the case before.

No error is thrown by the function when it fails.

This happens only on published projects after about 2 minutes after starting the server. Before that time, the operations work as expected on a fresh server.

This does not happen in Studio, regardless of how much time is elapsed.

4 Likes

Hi @FriendlyStoneGolem. Sorry to see that your users are experiencing this problem. Which game is it?

@hyperhumanist

thanks for following up. the game is Dragon Blade

please let me know if there’s anything else I can help with to track down the issue

@FriendlyStoneGolem it seems as if this might be happening on servers that haven’t restarted recently, so they don’t have the latest flags set.
Are you sure about that thing where you say that this happens after 2 minutes on a fresh server? I have been running a server for a small test of this for some time, and this is consistent with flags being stale, and it shouldn’t be connected to the length of the session.
It may seem as if it is connected with length of session, since servers that have been running for a long time (since before yesterday) would have those old flags.

We’ve rolled back the offending flag now. You should not be seeing the issue anymore. If you do, please let me know.

1 Like

@hyperhumanist

I am still able to reproduce this issue on a fresh server on my test copy of the game. I have been making sure to “shut down all servers” before each test to make sure.

I have attached a video of what I’m seeing. Initially, it’s working as intended. If you skip to about 1:20 you can see it suddenly stop working, and it never recovers. This is what my users are reporting as well.
Video
(expires in 24 hours day)

I don’t think the time until failure is always consistent. Sometimes it breaks sooner, but it’s hard to know for sure. But it seems to always be under 2 minutes.

Are these flags you mention something I can control on my side?

@hyperhumanist yes! The config rollback seems to have fixed it. I’ve been in the test server for 10 minutes and it’s still working as intended :raised_hands:

Thank you for all your help you’re the :goat:

1 Like