Hello!
I’ve created a ‘rope system’ which creates a visualization of a rope physics through Sprite Shape by using small 2d boxes as the points which conform the Spline of the Sprite Shape.
The problem is that sometimes the Sprite Shape only shows up after switching to the Scene View, then when you switch back to the Game View the Sprite Shape gets drawn correctly.
However, this problem only occurs when a sprite shape is created with certain angle offset between the attached bodies.
I’ve thought about it being about the distance of the points, but currently I’m using a method which assures a minimum distance is kept between all spline’s points.
The code used to create the spline can be seen over here.
If someone knows how could I replicate the switch to the Scene View with code in order to force fix this issue, I’d appreciate it very much.
Edit: This problem is currently happening, without any kind of debug error/warning, on Unity 2020.3.18f1, using the latest SpriteShape version available. Tried to check if this problem persists with Unity 2021, and on this version the SpriteShape doesn’t get drawn even if a switch to the Scene View is made.