/// <summary> /// This object is no longer going to be placed, destroy it. /// </summary> protected void Deselect() { // Notifiy the manager that a new placeable object can be spawned in place of this one, as we are about to destroy it placeableMgrScript.CanSpawn = true; /* Decrement the count of placeable gameObject types in the scene. i.e. If we have a placeable gameObject named 'House', * this would decrement the count of Houses in the scene. */ placeableMgrScript.DecrementObjCount(gameObject); GameObject.Destroy(gameObject); }