Search Issue Tracker

Fixed in 2019.1

Votes

0

Found in

2018.1.6f1

Issue ID

1056115

Regression

No

Crash on Scripting::ScriptingWrapperFor when destroying component with GameObject.DestroyImmediate after re-adding it

Scripting

-

How to reproduce:
1. Open the "crash_on_change.zip" project
2. Open the "SampleScene.unity" scene
3. Select "Directional Light" and "Cube" game objects via Hierarchy
4. In the Inspector open the "Network Identity" component context menu
5. Press "Selection to PhotonView"
6. Select the same game objects again
7. Remove "Photon View" component
8. Add "Network Identity" component
9. Repeat step 4-5

Actual result: Unity crashes. (gif attached)

Reproducible with: 2017.1.4p2, 2017.2.3p2, 2017.4.7f1, 2018.1.9f1, 2018.2.0f2, 2018.3.0a5.

Notes:
Assertion failed: Assertion failed on expression: 'm_InstanceID != InstanceID_None' appears after first execution of the script.
The crash is caused by line: GameObject.DestroyImmediate(networkView); SelectiontoPhoton.cs: 45

---------------------------------------------------
Fixed in 2019.1.0a11.

Comments (5)

  1. Daaa1d2c8df63ba34eccb460bb0087dd?d=mm

    beriberis

    Jun 02, 2020 12:53

    Thanks for your post. I’ve been thinking about writing a very comparable post over the last couple of weeks, I’ll probably keep it short and sweet and link to this instead if thats cool. Thanks.
    schutzmaske https://www.hewecon.de/

  2. Daaa1d2c8df63ba34eccb460bb0087dd?d=mm

    beriberis

    May 20, 2020 15:22

    I admit, I have not been on this web page in a long time... however it was another joy to see It is such an important topic and ignored by so many, even professionals. professionals. I thank you to help making people more aware of possible issues.
    sms cyprus https://www.steilesms.com/en/

  3. Daaa1d2c8df63ba34eccb460bb0087dd?d=mm

    beriberis

    May 17, 2020 22:26

    No doubt this is an excellent post I got a lot of knowledge after reading good luck. Theme of blog is excellent there is almost everything to read, Brilliant post.
    information security https://esowatch.org/

  4. Daaa1d2c8df63ba34eccb460bb0087dd?d=mm

    beriberis

    May 04, 2020 17:27

    This was really an interesting topic and I kinda agree with what you have mentioned here!
    Microsoft Dynamics 365 Finance and Operations Credit Card Processing https://isolutionspayments.com/cre...e-and-operations

  5. Daaa1d2c8df63ba34eccb460bb0087dd?d=mm

    beriberis

    Apr 28, 2020 20:39

    This blog is so nice to me. I will keep on coming here again and again. Visit my link as well..
    Microsoft Dynamics 365 Credit Card Processing https://isolutionspayments.com/cre...e-and-operations

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.