Facepunch / sbox-issues

176 stars 12 forks source link

Trying to close s&box with unsaved scenes forces you to "Save as" #4770

Closed Retroeer closed 7 months ago

Retroeer commented 8 months ago

Describe the bug

If you attempt to close without saving you get a "save?" Popup, clicking yes will force you to "save as" rather than just saving the existing file. If you close out of this window nothing saves.

To Reproduce

  1. Have an unsaved scene
  2. Try to close the game like a good little boy
  3. Born to Save, forced to Save As

Expected behavior

Ideally this should just save the existing scenes as Ctrl+s would do. And if the scene doesn't currently exist, then you can save as. If the user does happen to "Save As" do not close the game if they close the save window, a "are you sure?" Screen should appear instead, preventing accidental lose should the user want to go back to their scene for whatever reason.

Media/Files

No response

Additional context

No response

DevulTj commented 8 months ago

I'm not sure I understand. When you close the editor, and hit save, it does this already.. can you record a video?

Retroeer commented 8 months ago

I swear I'm not shitposting but this seemingly is gone now? Everytime I saved this way in the past I'd always get this pop-up, and trying to reproduce it doesn't get me that result anymore. Closing until I actually figure out what hyper specific things im doing is getting this window to show

Retroeer commented 8 months ago

I'm not shitposting after all, I finally realized what was causing it. When hitting Play Scene, S&Box recognizes this as a "Scene", and apparently something within the scene changes? Thus, causing an "Unsaved Change" image Upon trying to close the Scene you're forced to Save As, since this scene, obviously, does not permanently exist.

sbox-dev_nDQ4j5vajy

DevulTj commented 7 months ago

I'll sort that out

DevulTj commented 7 months ago

Should be good now