public void AddList(InstructionList list) { KeyframeSave keyframe = new KeyframeSave(); foreach (Instruction instruction in list) { if (instruction is GenericInstruction) { GenericInstruction asGenericInstruction = instruction as GenericInstruction; InstructionSave instructionSave = InstructionSave.FromInstruction(asGenericInstruction); keyframe.InstructionSaves.Add(instructionSave); } else { throw new NotImplementedException("This list contains a type of instruction that cannot be saved."); } } keyframe.Name = list.Name; SceneKeyframes.Add(keyframe); }
public void AddList(InstructionList list) { KeyframeSave keyframe = new KeyframeSave(); foreach (Instruction instruction in list) { if (instruction is GenericInstruction) { GenericInstruction asGenericInstruction = instruction as GenericInstruction; InstructionSave instructionSave = InstructionSave.FromInstruction(asGenericInstruction); keyframe.InstructionSaves.Add(instructionSave); } else { throw new NotImplementedException("This list contains a type of instruction that cannot be saved."); } } keyframe.Name = list.Name; SceneKeyframes.Add(keyframe); }