public void QueueGraphUpdates() { if (!this.graphUpdatesWorkItemAdded) { this.graphUpdatesWorkItemAdded = true; AstarWorkItem workItem = this.graphUpdates.GetWorkItem(); this.AddWorkItem(new AstarWorkItem(delegate { this.graphUpdatesWorkItemAdded = false; this.lastGraphUpdate = Time.realtimeSinceStartup; workItem.init(); }, workItem.update)); } }