public QuatKey(BinaryReader reader, NiFile niFile, KeyType type) : base(reader, niFile) { if (type != (KeyType)4) { Time = reader.ReadSingle(); Value = (T)Activator.CreateInstance(typeof(T), reader, niFile); } if (type == (KeyType)3) { TBC = new NiTBC(reader, niFile); } }
public NiKey(BinaryReader reader, NiFile niFile, KeyType type) : base(reader, niFile) { Time = reader.ReadSingle(); Value = (T)Activator.CreateInstance(typeof(T), reader, niFile); if (type == (KeyType)2) { Forward = (T)Activator.CreateInstance(typeof(T), reader, niFile); Backwards = (T)Activator.CreateInstance(typeof(T), reader, niFile); } if (type == (KeyType)3) { TBC = new NiTBC(reader, niFile); } }