public CardRememberAction(CardLocReference start, CardLocReference end, Transcript script) { startLocation = start; endLocation = end; this.script = script; if (endLocation.cardList.type != CCType.MEMORY) { throw new InvalidOperationException(); } }
public CardForgetAction(CardLocReference end) { if (end.cardList.type == CCType.MEMORY) { endLocation = end; } else { Debug.WriteLine(end.name); throw new InvalidOperationException(); } }
public CardLocReference ShallowCopy() { var loc = new CardLocReference() { cardList = cardList.ShallowCopy(), locIdentifier = String.Copy(locIdentifier), name = String.Copy(name) + " - Copy", actual = actual, }; return(loc); }
public CardMoveAction(CardLocReference start, CardLocReference end, Transcript script) { if (start.cardList.type == CCType.MEMORY && !start.actual) { Debug.WriteLine("start is mem loc: " + start.name + ", " + end.name); throw new NotSupportedException(); } else if (end.cardList.type == CCType.VIRTUAL) { Debug.WriteLine("end is not physical"); throw new NotSupportedException(); } else if (end.cardList.type == CCType.MEMORY) { Debug.WriteLine("end is mem loc"); throw new NotSupportedException(); } startLocation = start; endLocation = end; this.script = script; }
public ShuffleAction(CardLocReference locations, Transcript script) { this.locations = locations; unshuffled = new CardCollection(CCType.VIRTUAL); this.script = script; }