Pathfinding.NavmeshCut.GetAll C# (CSharp) Method

GetAll() public static method

public static GetAll ( ) : List
return List
		public static List<NavmeshCut> GetAll () {
			return allCuts;
		}
		

Usage Example

Ejemplo n.º 1
0
        // Token: 0x06000730 RID: 1840 RVA: 0x000465B0 File Offset: 0x000449B0
        public void ForceUpdate()
        {
            if (this.handler == null)
            {
                throw new Exception("Cannot update graphs. No TileHandler. Do not call this method in Awake.");
            }
            this.lastUpdateTime = Time.realtimeSinceStartup;
            List <NavmeshCut> all = NavmeshCut.GetAll();

            if (this.forcedReloadBounds.Count == 0)
            {
                int num = 0;
                for (int i = 0; i < all.Count; i++)
                {
                    if (all[i].RequiresUpdate())
                    {
                        num++;
                        break;
                    }
                }
                if (num == 0)
                {
                    return;
                }
            }
            bool flag = this.handler.StartBatchLoad();

            for (int j = 0; j < this.forcedReloadBounds.Count; j++)
            {
                this.handler.ReloadInBounds(this.forcedReloadBounds[j]);
            }
            this.forcedReloadBounds.Clear();
            for (int k = 0; k < all.Count; k++)
            {
                if (all[k].enabled)
                {
                    if (all[k].RequiresUpdate())
                    {
                        this.handler.ReloadInBounds(all[k].LastBounds);
                        this.handler.ReloadInBounds(all[k].GetBounds());
                    }
                }
                else if (all[k].RequiresUpdate())
                {
                    this.handler.ReloadInBounds(all[k].LastBounds);
                }
            }
            for (int l = 0; l < all.Count; l++)
            {
                if (all[l].RequiresUpdate())
                {
                    all[l].NotifyUpdated();
                }
            }
            if (flag)
            {
                this.handler.EndBatchLoad();
            }
        }
All Usage Examples Of Pathfinding.NavmeshCut::GetAll