internal static W3dEmitterRotationHeader Parse(BinaryReader reader) { var result = new W3dEmitterRotationHeader { KeyframeCount = reader.ReadUInt32(), Random = reader.ReadSingle(), OrientationRandom = reader.ReadSingle() }; reader.ReadBytes(sizeof(uint)); // Pad return(result); }
internal static W3dEmitterRotationKeyframes Parse(BinaryReader reader) { var result = new W3dEmitterRotationKeyframes { Header = W3dEmitterRotationHeader.Parse(reader) }; result.Keyframes = new W3dEmitterRotationKeyframe[result.Header.KeyframeCount + 1]; for (var i = 0; i < result.Keyframes.Length; i++) { result.Keyframes[i] = W3dEmitterRotationKeyframe.Parse(reader); } return(result); }
internal static W3dEmitterRotationKeyframes Parse(BinaryReader reader, W3dParseContext context) { return(ParseChunk(reader, context, header => { var result = new W3dEmitterRotationKeyframes { Header = W3dEmitterRotationHeader.Parse(reader) }; result.Keyframes = new W3dEmitterRotationKeyframe[result.Header.KeyframeCount + 1]; for (var i = 0; i < result.Keyframes.Length; i++) { result.Keyframes[i] = W3dEmitterRotationKeyframe.Parse(reader); } return result; })); }