public override void Read(AssetStream stream) { base.Read(stream); if (IsReadMode(stream.Version)) { Mode = (ParticleSystemTrailMode)stream.ReadInt32(); } Ratio = stream.ReadSingle(); Lifetime.Read(stream); MinVertexDistance = stream.ReadSingle(); TextureMode = stream.ReadInt32(); if (IsReadRibbonCount(stream.Version)) { RibbonCount = stream.ReadInt32(); } WorldSpace = stream.ReadBoolean(); DieWithParticles = stream.ReadBoolean(); SizeAffectsWidth = stream.ReadBoolean(); SizeAffectsLifetime = stream.ReadBoolean(); InheritParticleColor = stream.ReadBoolean(); if (IsReadGenerateLightingData(stream.Version)) { GenerateLightingData = stream.ReadBoolean(); } if (IsReadSplitSubEmitterRibbons(stream.Version)) { SplitSubEmitterRibbons = stream.ReadBoolean(); } stream.AlignStream(AlignType.Align4); ColorOverLifetime.Read(stream); WidthOverTrail.Read(stream); ColorOverTrail.Read(stream); }
public override void Read(AssetReader reader) { base.Read(reader); if (HasMode(reader.Version)) { Mode = (ParticleSystemTrailMode)reader.ReadInt32(); } Ratio = reader.ReadSingle(); Lifetime.Read(reader); MinVertexDistance = reader.ReadSingle(); TextureMode = (ParticleSystemTrailTextureMode)reader.ReadInt32(); if (HasRibbonCount(reader.Version)) { RibbonCount = reader.ReadInt32(); } if (HasShadowBias(reader.Version)) { ShadowBias = reader.ReadSingle(); } WorldSpace = reader.ReadBoolean(); DieWithParticles = reader.ReadBoolean(); SizeAffectsWidth = reader.ReadBoolean(); SizeAffectsLifetime = reader.ReadBoolean(); InheritParticleColor = reader.ReadBoolean(); if (HasGenerateLightingData(reader.Version)) { GenerateLightingData = reader.ReadBoolean(); } if (HasSplitSubEmitterRibbons(reader.Version)) { SplitSubEmitterRibbons = reader.ReadBoolean(); } if (HasAttachRibbonsToTransform(reader.Version)) { AttachRibbonsToTransform = reader.ReadBoolean(); } reader.AlignStream(); ColorOverLifetime.Read(reader); WidthOverTrail.Read(reader); ColorOverTrail.Read(reader); }