ID:2639670
 
Resolved
Turfs in visual contents of objects did not properly mark when they were no longer in use (on the client) as a result of the obj or mob being deleted.
BYOND Version:513.1536
Operating System:Windows 10 Pro 64-bit
Web Browser:Chrome 87.0.4280.66
Applies to:Dream Seeker
Status: Resolved (513.1537)

This issue has been resolved.
Descriptive Problem Summary:
If an /atom/movable/O is using vis_contents on a /turf/B below (O is above B, and copying B) and O's removed and B is changed, B doesn't update on the client, resulting in an incorrect icon, name, etc and being unable to reference the turf through right click. This fixes can be updated through various ways, such as relogging, changing the z_flags of B, or sometimes moving Z levels.

Numbered Steps to Reproduce Problem:
1) Move player up Z level
2) Move elevator up Z level
3) Move player down Z level
4) Observe incorrect data and inability to reference the turfs in a right click verb

There is a DoTest() verb in the following:
https://cdn.discordapp.com/attachments/678826323728400394/ 783103080316796928/Vis_Issue.zip

Expected Results:
Client's turfs update correctly

Actual Results:
They don't

Does the problem occur:
Every time? Or how often? Yes
In other games? Yes, SS13 and test environment provided
In other user accounts? Idk
On other computers? Idk

When does the problem NOT occur?
If the turf below doesn't change.
Did the problem NOT occur in any earlier versions? If so, what was the last version that worked? (Visit http://www.byond.com/download/build to download old versions for testing.) Tried 513.1535 and 513.1520, didn't work

Workarounds:
You can fix it by updating the vis_flags of the turf to something else, reconnecting, or moving up 2? Z levels.
I'm looking at the demo but not entirely sure I follow what's happening here. All of the magic seems to happen inside this vis_copy object and I'm not 100% seeing how this all comes together.

I have a very strong feeling that something is amiss with the way your vis_copies list is handled and that's somehow related to the problem.

I'll have to run this through the debugger but boy is it gonna be a tough one to crack.
I think all the important code is in test.dm but I am a phone right now so I can't double check.
Lummox JR resolved issue with message:
Turfs in visual contents of objects did not properly mark when they were no longer in use (on the client) as a result of the obj or mob being deleted.