/// <summary> /// Executes a command, placing it on the stack. This empties the Redo stack, losing those commands permanently. This function does not check if a command /// can be done, so all code using the CommandStack should call CanBeDone() on the command before passing it to the CommandStack. /// </summary> /// <param name="command"></param> public void ExecuteCommand(MapEditorCommand command) { command.Do(); done.Push(command); undone.Clear(); }