Search Issue Tracker

Fixed in Unity 2018.2

Votes

1

Found in

2018.1.0b12

Issue ID

1017868

Regression

Yes

Using Transform.LookAt() right after instantiating causes a crash in b2BroadPhase::UpdatePairs<b2ContactManager>

Physics2D

-

-

Priority: 2Necessary for shipping a final release

-

Severity: 1Crash, freeze, data loss, work stops

Reproduction steps:
1. Open the attached project "SpaceMonsters.zip";
2. Open the SampleScene;
3. Enter a play mode;
4. Click several times on the Game View and try to move the character with arrow keys (usually it takes 3 to 10 clicks).

Actual results: editor crashes.

Reproduced on: 2018.1.0a1, 2018.1.0b13, 2018.2.0a6.
Not reproduced: 2017.1.3p2, 2017.2.2.p2, 2017.3.2f1.

The workaround is to comment out the line which has Transform.LookAt() class.

Fixed in: 2018.2.0b1.

Comments (3)

  1. 5543e67336a123dd633d437a6454ffb8?d=mm

    Darkan_Kana

    Apr 12, 2018 13:42

    I also got brought onto this page due to a b2BroadPhase::UpdatePairs<b2ContactManager> crash, however in my case it was not due to the use of transform.LookAt(...), but the result of a GameObject with a Collider2D being destroyed specifically when it has a parent. This has been happening as well on version 2018.1.0b13.

    The crash does not happen when the GameObject is not parented, or when I remove the Collider2D from the prefab used to instantiate the object in question. Also of note, the crash also happens when calling gameObject.SetActive( false ) instead of Destroy( gameObject ).

  2. 8f6aa0cc0f1d81a44e0b88916157e615?d=mm

    GeekyMonkey

    Apr 07, 2018 13:05

    Actually, I was led here by mistake. When the editor crashed, it indicated this was a know bug. But I've disabled all lookAt calls and I still get the crash. I tracked it down to setting enabled=false on a collider2d.

  3. 8f6aa0cc0f1d81a44e0b88916157e615?d=mm

    GeekyMonkey

    Apr 07, 2018 11:36

    Any workaround that still allows full functionality?

All about bugs

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