Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more..
    Dismiss Notice
  3. Dismiss Notice

Question 2021.3.11f1 and Visual Studio 2022 v17.3.4 aren't playing well together

Discussion in 'Editor & General Support' started by StuartJMcc, Oct 17, 2022.

  1. StuartJMcc

    StuartJMcc

    Joined:
    Aug 12, 2020
    Posts:
    14
    Firstly let me start with the apologies - I'm not the Unity guy around here!

    The basics - we have our apps running nicely on Windows 10, Unity 2020.3.19 and Studio 2019.
    I got a new laptop with Windows 11 so thought time for update to latest everything. I pulled the code from github, installed Studio 2022 and installed 2021.3.11f1 (in that order). Everything loaded and ran in the editors play mode after a few tweaks here and there - bargain, that was easy....

    ....except when I built a project and tried to run the executable on its own!!!

    MOST of the time (note: not all of the time - sometimes it works then stops as soon as you try copying it to any other location) I get the app hanging before it displays the canvas and the event viewer telling me "The program AutoTraining.exe version 2021.3.11.23713 stopped interacting with Windows and was closed". There is a WCF service involved and the app got as far as connecting to that and sending requests. I removed it any way and got the same issue - blank screen, busy indicator, click a few times black window turns to grey and it tells me it isn't responding, then reports to Microsoft and dies a death.
    So I hit the development build checkbox to start working out how to debug Unity apps - and everything works fine!!!!

    Could someone please point me in the direction of how to start debugging this scenario?

    Cheers
     
  2. StuartJMcc

    StuartJMcc

    Joined:
    Aug 12, 2020
    Posts:
    14
    UPDATE: We have taken a working Windows 10, Unity 2020.3.19 and Studio 2019 environment that works and upgraded to Studio 2022 and Unity 2021.3.11f1 - this successfully builds the same code and runs without issue in "release" mode.
    This implies my environment is not correct when built from a clean Windows 11 platform.

    Still - any pointers would be greatly appreciated!!!
     
  3. StuartJMcc

    StuartJMcc

    Joined:
    Aug 12, 2020
    Posts:
    14
    UPDATE AGAIN: We have isolated the component that is causing the problem - it seems to be the Particle System at fault.
    If I disable the component with the particle system attached everything is fine and it runs perfectly every time.

    I'm guessing there's an issue with installing 2021.3.11f1 on a clean machine. As stated above, if you upgrade from 2020 then there isn't a problem (on Windows 10, we haven't tried Windows 11 yet)

    We tried prefab'ing a new component on the upgraded 2021.3.11f1 system and taking it across to the clean machine and that didn't work. We also (quickly) tried recreating the particle system from scratch on the clean machine and that didn't work either.

    We have a support ticket in place #1378720 but as our license doesn't cover direct technical support God only knows when we'll get a response (if any).