Fix sectors being rotated on tidally locked bodies (#870)

## Bug fixes

- Fixed sectors being rotated on tidally locked bodies
This commit is contained in:
xen-42 2024-06-03 22:50:04 -04:00 committed by GitHub
commit 803a6c2404
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -11,8 +11,8 @@ namespace NewHorizons.Builder.General
{
var sectorGO = new GameObject("Sector");
sectorGO.SetActive(false);
sectorGO.transform.parent = planetBody.transform;
sectorGO.transform.localPosition = Vector3.zero;
// Have to use set parent method without keeping world position to Fix sectors being rotated on tidally locked bodies #870
sectorGO.transform.SetParent(planetBody.transform, false);
var SS = sectorGO.AddComponent<SphereShape>();
SS.SetCollisionMode(Shape.CollisionMode.Volume);