Yellow-Dog-Man / Resonite-Issues

Issue repository for Resonite.
https://resonite.com
141 stars 2 forks source link

Force-closing Resonite when the cloud home is not fully loaded can 'scramble' textures in the cloud home (World Materials Seemingly Missing and Scrambled) #280

Open Nytra opened 1 year ago

Nytra commented 1 year ago

Describe the bug?

When you close Resonite using the red X in the top right of the window in desktop mode (Or right click the icon in taskbar and press close window), it will try to save homes before closing.

If you try to close Resonite while the cloud home is still loading, it will start a save for the world before it is done loading.

I think that this causes the unloaded textures/materials to be optimized in a bad way which results in the materials being ruined in the world.

To Reproduce

(Backup your cloud home before attempting!)

1) Start Resonite 1) Wait until the cloud home begins loading 2) Press X in the top window bar on desktop before the loading is finished (this will not kill the Resonite process, but it will begin syncing to the cloud in the usual empty environment) 3) Some textures may be 'scrambled' the next time you visit the cloud home

Expected behavior

Triggering a save for a world which has not finished loading, either on purpose or on accident, should not corrupt the assets of the world.

Screenshots

In these screenshots, these objects did not have the strange wood-like texture before the corruption was triggered.

(These screenshots were taken in Resonite)

2023-10-18 14 42 29 2023-10-18 14 42 45 2023-10-18 14 42 56

Resonite Version Number

2023.10.18.449

What Platforms does this occur on?

Windows

What headset if any do you use?

Valve Index

Log Files

DESKTOP-H976HO2 - 2023.10.18.449 - 2023-10-18 15_37_57.log

Additional Context

N/a

Reporters

Nytra (Discord: nytra)

Enverex commented 1 year ago

This is an old Neos issue that has destroyed at least 3 of my worlds over the years.

See https://github.com/Neos-Metaverse/NeosPublic/issues/659

The issue happens if the world is saved before it's completely finished loading. There doesn't appear to be any way to undo the destruction.

epicEaston197 commented 1 year ago

Yeah I can attest to this my Sun Control Tool and my bow both completely lost their textures

i've since fixed the Sun Control Tool image

Nytra commented 1 week ago

This is still happening in Beta 2024.11.12.1329

I just corrupted my cloud home accidentally again

shiftyscales commented 1 week ago

@Frooxius - I'm curious if this issue would be resolved by #2737? I don't know with certainty where the issue lies- but the consistent / underlying replication step is to save a world while assets are not finished loading.

My guess is that because of this, the system sees materials that functionally look identical because the texture assets are "identical" (unloaded), and it wrongly de-duplicates their materials, causing the "scrambling" observed.