mirror of
https://github.com/Xevion/Boids.git
synced 2025-12-10 10:06:39 -06:00
remove TimeScale, fix DisableFocusing concerning LineRenderer array
This commit is contained in:
@@ -230,9 +230,11 @@ public class Boid : MonoBehaviour {
|
|||||||
|
|
||||||
|
|
||||||
// Destroy Line Renderers (and child GameObjects)
|
// Destroy Line Renderers (and child GameObjects)
|
||||||
foreach (Transform child in transform)
|
for (int i = 0; i < _lineRenderers.Length; i++) {
|
||||||
DestroyImmediate(child.gameObject);
|
_lineRenderers[i].positionCount = 0;
|
||||||
Array.Clear(_lineRenderers, 0, _lineRenderers.Length);
|
DestroyImmediate(_lineRenderers[i].gameObject);
|
||||||
|
_lineRenderers[i] = null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -102,8 +102,6 @@ public class BoidController : MonoBehaviour {
|
|||||||
ShapeDraw.CircleVertexCount = circleVertexCount;
|
ShapeDraw.CircleVertexCount = circleVertexCount;
|
||||||
// ShapeDraw.ArcVertexCount = arcVertexCount;
|
// ShapeDraw.ArcVertexCount = arcVertexCount;
|
||||||
|
|
||||||
Time.timeScale = 0.3f;
|
|
||||||
|
|
||||||
AddBoids(boidCount);
|
AddBoids(boidCount);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user