Esempio n. 1
0
 public void ForEachCalculatedFrustum(Action <FrustumPointsPositions> action)
 {
     foreach (var obstacleInteractiveObject in nearSquareObstacles)
     {
         foreach (var obstacleFrustumPositions in ObstacleOcclusionCalculationManagerV2.GetCalculatedOcclusionFrustums(this, obstacleInteractiveObject))
         {
             action(obstacleFrustumPositions);
         }
     }
 }
Esempio n. 2
0
        public void GizmoTick()
        {
            ObstacleOcclusionCalculationManagerV2 ObstacleOcclusionCalculationManagerV2 = ObstacleOcclusionCalculationManagerV2.Get();

            foreach (var obstacleListener in this.obstacleListeners)
            {
                ObstacleOcclusionCalculationManagerV2.TryGetCalculatedOcclusionFrustumsForObstacleListener(obstacleListener, out Dictionary <int, List <FrustumPointsPositions> > allCalculatedFrustumPositions);
                if (allCalculatedFrustumPositions != null)
                {
                    foreach (var calculatedFrustumPositions in allCalculatedFrustumPositions.Values)
                    {
                        foreach (var calculatedFrustumPosition in calculatedFrustumPositions)
                        {
                            calculatedFrustumPosition.DrawInScene(MyColors.GetColorOnIndex(obstacleListener.ObstacleListenerUniqueID));
                        }
                    }
                }
            }
        }
Esempio n. 3
0
 public override void Destroy()
 {
     ObstacleOcclusionCalculationManagerV2.Get().OnObstacleInteractiveObjectDestroyed(this);
     ObstacleInteractiveObjectManager.Get().OnSquareObstacleSystemDestroyed(this);
     base.Destroy();
 }