Ejemplo n.º 1
0
        public WadAnimation Clone()
        {
            var animation = (WadAnimation)MemberwiseClone();

            animation.KeyFrames = KeyFrames.ConvertAll(keyFrame => keyFrame.Clone());

            animation.AnimCommands = new List <WadAnimCommand>();
            foreach (var ac in AnimCommands)
            {
                animation.AnimCommands.Add(ac.Clone());
            }

            animation.StateChanges = new List <WadStateChange>();
            foreach (var sc in StateChanges)
            {
                animation.StateChanges.Add(sc.Clone());
            }

            return(animation);
        }