public override bool Equals(object obj)
        {
            NavMeshTemplateCreation otherTemplate = (NavMeshTemplateCreation)obj;

            if (otherTemplate == null)
            {
                return(false);
            }

            return(Match(otherTemplate.gridPosition, otherTemplate.properties));
        }
        //this stage executed in whatever thread. nothing here are really managed

        //it is all awesome pipeline that generate navmesh
        public static void ThreadWorker(object obj)
        {
            NavMeshTemplateCreation template = (NavMeshTemplateCreation)obj;

            if (template == null)
            {
                Debug.LogError("invalid argument while using thread worker");
            }

            try {
                template.GenerateGraph();
            }
            catch (Exception e) {
                if (template.profiler != null)
                {
                    template.profiler.DebugLog(ProfilderLogMode.warning);
                }
                Debug.LogError(e);
                throw;
            }
        }
 public ColliderCollector(NavMeshTemplateCreation template)
 {
     this.template = template;
     chunkBounds   = template.chunkOffsetedBounds;
 }