Search Unity

Unity Crashing on opening a specific scene .

Discussion in 'Editor & General Support' started by ghazanfarali1277, Sep 10, 2021.

  1. ghazanfarali1277

    ghazanfarali1277

    Joined:
    Oct 17, 2016
    Posts:
    3
    I have a project, been working on it since last 8 month, on unity 2019.4.1f1. One day due to electricity faliure system shut down directly and the next day when i try to open this project unity is crashing on opening gameplay scene which i was working on the day before. i tried changing versions, i tried direclty opening that scene, tried deleting library files packages file but still unity is crashing on opening gameplay scene. menu and weapon selection scene are working fine
     

    Attached Files:

  2. Kurt-Dekker

    Kurt-Dekker

    Joined:
    Mar 16, 2013
    Posts:
    38,689
    I'm sorry you've had this issue. You are most likely going to need to go to a backup of that scene file and restart from there. You might be able to open the scene in a text editor and chop off or cut out blocks of YAML that look bad, but that is NOT supported, NOT recommended, and would require you to revisit the entire scene anyway to look for damage and repair it.

    I suggest you immediately consider setting up and using proper industrial-grade source control in order to guard and protect your hard-earned work. This is 2021 after all, and such random loss of data is well understood and can easily be guarded against.

    Personally I use git (completely outside of Unity) because it is free and there are tons of tutorials out there to help you set it up as well as free places to host your repo (BitBucket, Github, Gitlab, etc.).

    As far as configuring Unity to play nice with git, keep this in mind:

    https://forum.unity.com/threads/prefab-links-keep-getting-dumped-on-git-pull.646600/#post-7142306

    Here's how I use git in one of my games, Jetpack Kurt:

    https://forum.unity.com/threads/2-steps-backwards.965048/#post-6282497

    Using fine-grained source control as you work to refine your engineering:

    https://forum.unity.com/threads/whe...grammer-example-in-text.1048739/#post-6783740

    Share/Sharing source code between projects:

    https://forum.unity.com/threads/your-techniques-to-share-code-between-projects.575959/#post-3835837

    Setting up an appropriate .gitignore file for Unity3D:

    https://forum.unity.com/threads/removing-il2cpp_cache-from-project.1084607/#post-6997067

    Generally setting Unity up (includes above .gitignore concepts):

    https://thoughtbot.com/blog/how-to-git-with-unity

    It is only simple economics that you must expend as much effort into backing it up as you feel the work is worth in the first place.

    "Use source control or you will be really sad sooner or later." - StarManta on the Unity3D forum boards
     
  3. ghazanfarali1277

    ghazanfarali1277

    Joined:
    Oct 17, 2016
    Posts:
    3
    Thanks a lot for the detailed response, i have found the issue because of this. half of the data is missing/corrupt according to text file. and not recoverable . and scene is still crashing but anyways . at least i wont waste my time anymore and move on .
    thanks again.
     
    Kurt-Dekker likes this.