/// <summary> /// Initializes a new instance of the <see cref="StateSwitcher"/> class. /// </summary> /// <param name="target">The target <see cref="IStateHost"/> to switch the state.</param> /// <param name="state">The <see cref="UndoRedoState"/> to set on the <paramref name="target"/>.</param> /// <exception cref="ArgumentNullException"><paramref name="target"/> is a <see langword="null"/> reference.</exception> public StateSwitcher(IStateHost target, Diskordia.UndoRedo.State.UndoRedoState state) { if (target == null) { throw new ArgumentNullException("target"); } this.owner = target; this.backup = this.owner.State; this.owner.State = state; }
public void _SetHostPlayer(IStateHost player) { mHostPlayer = player; }
public void _SetHostNpc(IStateHost npc) { mHostNpc = npc; }