InitializeForPath() public method

public InitializeForPath ( Path p ) : void
p Path
return void
コード例 #1
0
ファイル: Path.cs プロジェクト: yellowshq/myGameFramework
        /** Prepares low level path variables for calculation.
         * Called before a path search will take place.
         * Always called before the Prepare, Initialize and CalculateStep functions
         */
        protected void PrepareBase(PathHandler pathHandler)
        {
            //Path IDs have overflowed 65K, cleanup is needed
            //Since pathIDs are handed out sequentially, we can do this
            if (pathHandler.PathID > pathID)
            {
                pathHandler.ClearPathIDs();
            }

            //Make sure the path has a reference to the pathHandler
            this.pathHandler = pathHandler;
            //Assign relevant path data to the pathHandler
            pathHandler.InitializeForPath(this);

            // Make sure that internalTagPenalties is an array which has the length 32
            if (internalTagPenalties == null || internalTagPenalties.Length != 32)
            {
                internalTagPenalties = ZeroTagPenalties;
            }

            try {
                ErrorCheck();
            } catch (System.Exception e) {
                ForceLogError("Exception in path " + pathID + "\n" + e);
            }
        }
コード例 #2
0
ファイル: Path.cs プロジェクト: blockspacer/Assembily-CSharp
 // Token: 0x06000265 RID: 613 RVA: 0x00014624 File Offset: 0x00012A24
 public void PrepareBase(PathHandler pathHandler)
 {
     if (pathHandler.PathID > this.pathID)
     {
         pathHandler.ClearPathIDs();
     }
     this.pathHandler = pathHandler;
     pathHandler.InitializeForPath(this);
     if (this.internalTagPenalties == null || this.internalTagPenalties.Length != 32)
     {
         this.internalTagPenalties = Path.ZeroTagPenalties;
     }
     try
     {
         this.ErrorCheck();
     }
     catch (Exception ex)
     {
         this.ForceLogError(string.Concat(new object[]
         {
             "Exception in path ",
             this.pathID,
             "\n",
             ex.ToString()
         }));
     }
 }
コード例 #3
0
ファイル: Path.cs プロジェクト: ComunidadesVirtuais/Project
        /** Prepares low level path variables for calculation.
         * Called before a path search will take place.
         * Always called before the Prepare, Initialize and CalculateStep functions
         */
        public void PrepareBase(PathHandler pathHandler)
        {
            //Path IDs have overflowed 65K, cleanup is needed
            //Since pathIDs are handed out sequentially, we can do this
            if (pathHandler.PathID > pathID)
            {
                pathHandler.ClearPathIDs();
            }

            //Make sure the path has a reference to the pathHandler
            this.pathHandler = pathHandler;
            //Assign relevant path data to the pathHandler
            pathHandler.InitializeForPath(this);

            try {
                ErrorCheck();
            } catch (System.Exception e) {
                ForceLogError("Exception in path " + pathID + "\n" + e.ToString());
            }
        }
コード例 #4
0
 // Token: 0x060023B0 RID: 9136 RVA: 0x001957A0 File Offset: 0x001939A0
 protected void PrepareBase(PathHandler pathHandler)
 {
     if (pathHandler.PathID > this.pathID)
     {
         pathHandler.ClearPathIDs();
     }
     this.pathHandler = pathHandler;
     pathHandler.InitializeForPath(this);
     if (this.internalTagPenalties == null || this.internalTagPenalties.Length != 32)
     {
         this.internalTagPenalties = Path.ZeroTagPenalties;
     }
     try
     {
         this.ErrorCheck();
     }
     catch (Exception ex)
     {
         this.FailWithError(ex.Message);
     }
 }
コード例 #5
0
ファイル: Path.cs プロジェクト: JtheSpaceC/Breaking-The-Rules
		/** Prepares low level path variables for calculation.
		  * Called before a path search will take place.
		  * Always called before the Prepare, Initialize and CalculateStep functions
		  */
		public void PrepareBase (PathHandler pathHandler) {

			//Path IDs have overflowed 65K, cleanup is needed
			//Since pathIDs are handed out sequentially, we can do this
			if (pathHandler.PathID > pathID) {
				pathHandler.ClearPathIDs ();
			}

			//Make sure the path has a reference to the pathHandler
			this.pathHandler = pathHandler;
			//Assign relevant path data to the pathHandler
			pathHandler.InitializeForPath (this);

			// Make sure that internalTagPenalties is an array which has the length 32
			if (internalTagPenalties == null || internalTagPenalties.Length != 32)
				internalTagPenalties = ZeroTagPenalties;

			try {
				ErrorCheck ();
			} catch (System.Exception e) {
				ForceLogError ("Exception in path "+pathID+"\n"+e);
			}
		}
コード例 #6
0
ファイル: Path.cs プロジェクト: GameDiffs/TheForest
 public void PrepareBase(PathHandler pathHandler)
 {
     if (pathHandler.PathID > this.pathID)
     {
         pathHandler.ClearPathIDs();
     }
     this.pathHandler = pathHandler;
     pathHandler.InitializeForPath(this);
     if (this.internalTagPenalties == null || this.internalTagPenalties.Length != 32)
     {
         this.internalTagPenalties = Path.ZeroTagPenalties;
     }
     try
     {
         this.ErrorCheck();
     }
     catch (Exception ex)
     {
         this.ForceLogError(string.Concat(new object[]
         {
             "Exception in path ",
             this.pathID,
             "\n",
             ex
         }));
     }
 }
コード例 #7
0
ファイル: Path.cs プロジェクト: JackHR/WaveIncoming
		/** Prepares low level path variables for calculation.
		  * Called before a path search will take place.
		  * Always called before the Prepare, Initialize and CalculateStep functions
		  */
		public void PrepareBase (PathHandler pathHandler) {
			
			//Path IDs have overflowed 65K, cleanup is needed
			//Since pathIDs are handed out sequentially, we can do this
			if (pathHandler.PathID > pathID) {
				pathHandler.ClearPathIDs ();
			}
			
			//Make sure the path has a reference to the pathHandler
			this.pathHandler = pathHandler;
			//Assign relevant path data to the pathHandler
			pathHandler.InitializeForPath (this);

			try {
				ErrorCheck ();
			} catch (System.Exception e) {
				ForceLogError ("Exception in path "+pathID+"\n"+e.ToString());
			}
		}