Пример #1
0
 /// <summary>
 /// Called by Unity.
 /// Can be overriden but be sure to call base.OnDestroy() to ensure that the grid is successfully destroyed.
 /// </summary>
 public virtual void OnDestroy()
 {
     // Unregister this grid as it is about to be destroyed
     AStarGridManager.unregisterGrid(this);
 }
Пример #2
0
 // Methods
 /// <summary>
 /// Called by Unity.
 /// Can be overriden but be sure to call base.Awake() to ensure that the grid is correctly initialized.
 /// </summary>
 public virtual void Awake()
 {
     // Register this grid with the grid manager
     AStarGridManager.registerGrid(this);
 }