public override void WriteDataXML(XElement ele, ElderScrollsPlugin master) { XElement subEle; if (EditorID != null) { ele.TryPathTo("EditorID", true, out subEle); EditorID.WriteXML(subEle, master); } if (ObjectBounds != null) { ele.TryPathTo("ObjectBounds", true, out subEle); ObjectBounds.WriteXML(subEle, master); } if (Name != null) { ele.TryPathTo("Name", true, out subEle); Name.WriteXML(subEle, master); } if (Script != null) { ele.TryPathTo("Script", true, out subEle); Script.WriteXML(subEle, master); } if (ObjectEffect != null) { ele.TryPathTo("ObjectEffect", true, out subEle); ObjectEffect.WriteXML(subEle, master); } if (BipedData != null) { ele.TryPathTo("BipedData", true, out subEle); BipedData.WriteXML(subEle, master); } if (MaleBipedModelFileName != null) { ele.TryPathTo("Models/Biped/Male/FileName", true, out subEle); MaleBipedModelFileName.WriteXML(subEle, master); } if (MaleBipedModelTextureHashes != null) { ele.TryPathTo("Models/Biped/Male/TextureHashes", true, out subEle); MaleBipedModelTextureHashes.WriteXML(subEle, master); } if (MaleBipedModelAlternateTextures != null) { ele.TryPathTo("Models/Biped/Male/AlternateTextures", true, out subEle); MaleBipedModelAlternateTextures.WriteXML(subEle, master); } if (MaleBipedModelFaceGenModelFlags != null) { ele.TryPathTo("Models/Biped/Male/FaceGenModelFlags", true, out subEle); MaleBipedModelFaceGenModelFlags.WriteXML(subEle, master); } if (MaleWorldModelFileName != null) { ele.TryPathTo("Models/World/Male/FileName", true, out subEle); MaleWorldModelFileName.WriteXML(subEle, master); } if (MaleWorldModelTextureHashes != null) { ele.TryPathTo("Models/World/Male/TextureHashes", true, out subEle); MaleWorldModelTextureHashes.WriteXML(subEle, master); } if (MaleWorldModelAlternateTextures != null) { ele.TryPathTo("Models/World/Male/AlternateTextures", true, out subEle); MaleWorldModelAlternateTextures.WriteXML(subEle, master); } if (MaleInventoryIcon != null) { ele.TryPathTo("Icon/Inventory/Male", true, out subEle); MaleInventoryIcon.WriteXML(subEle, master); } if (MaleMessageIcon != null) { ele.TryPathTo("Icon/Message/Male", true, out subEle); MaleMessageIcon.WriteXML(subEle, master); } if (FemaleBipedModelFileName != null) { ele.TryPathTo("Models/Biped/Female/FileName", true, out subEle); FemaleBipedModelFileName.WriteXML(subEle, master); } if (FemaleBipedModelTextureHashes != null) { ele.TryPathTo("Models/Biped/Female/TextureHashes", true, out subEle); FemaleBipedModelTextureHashes.WriteXML(subEle, master); } if (FemaleBipedModelAlternateTextures != null) { ele.TryPathTo("Models/Biped/Female/AlternateTextures", true, out subEle); FemaleBipedModelAlternateTextures.WriteXML(subEle, master); } if (FemaleBipedModelFaceGenModelFlags != null) { ele.TryPathTo("Models/Biped/Female/FaceGenModelFlags", true, out subEle); FemaleBipedModelFaceGenModelFlags.WriteXML(subEle, master); } if (FemaleWorldModelFileName != null) { ele.TryPathTo("Models/World/Female/FileName", true, out subEle); FemaleWorldModelFileName.WriteXML(subEle, master); } if (FemaleWorldModelTextureHashes != null) { ele.TryPathTo("Models/World/Female/TextureHashes", true, out subEle); FemaleWorldModelTextureHashes.WriteXML(subEle, master); } if (FemaleWorldModelAlternateTextures != null) { ele.TryPathTo("Models/World/Female/AlternateTextures", true, out subEle); FemaleWorldModelAlternateTextures.WriteXML(subEle, master); } if (FemaleInventoryIcon != null) { ele.TryPathTo("Icon/Inventory/Female", true, out subEle); FemaleInventoryIcon.WriteXML(subEle, master); } if (FemaleMessageIcon != null) { ele.TryPathTo("Icon/Message/Female", true, out subEle); FemaleMessageIcon.WriteXML(subEle, master); } if (RagdollConstraintTemplate != null) { ele.TryPathTo("RagdollConstraintTemplate", true, out subEle); RagdollConstraintTemplate.WriteXML(subEle, master); } if (RepairList != null) { ele.TryPathTo("RepairList", true, out subEle); RepairList.WriteXML(subEle, master); } if (BipedModelList != null) { ele.TryPathTo("BipedModelList", true, out subEle); BipedModelList.WriteXML(subEle, master); } if (EquipmentType != null) { ele.TryPathTo("EquipmentType", true, out subEle); EquipmentType.WriteXML(subEle, master); } if (PickupSound != null) { ele.TryPathTo("PickupSound", true, out subEle); PickupSound.WriteXML(subEle, master); } if (DropSound != null) { ele.TryPathTo("DropSound", true, out subEle); DropSound.WriteXML(subEle, master); } if (Data != null) { ele.TryPathTo("Data", true, out subEle); Data.WriteXML(subEle, master); } if (ExtraData != null) { ele.TryPathTo("ExtraData", true, out subEle); ExtraData.WriteXML(subEle, master); } if (OverridesAnimationSounds != null) { ele.TryPathTo("OverridesAnimationSounds", true, out subEle); OverridesAnimationSounds.WriteXML(subEle, master); } if (AnimationSounds != null) { ele.TryPathTo("AnimationSounds", true, out subEle); List <string> xmlNames = new List <string> { "Sound" }; int i = 0; foreach (var entry in AnimationSounds) { i = i % xmlNames.Count(); XElement newEle = new XElement(xmlNames[i]); entry.WriteXML(newEle, master); subEle.Add(newEle); i++; } } if (AnimationSoundsTemplate != null) { ele.TryPathTo("AnimationSoundsTemplate", true, out subEle); AnimationSoundsTemplate.WriteXML(subEle, master); } }
public override void WriteDataXML(XElement ele, ElderScrollsPlugin master) { XElement subEle; if (EditorID != null) { ele.TryPathTo("EditorID", true, out subEle); EditorID.WriteXML(subEle, master); } if (ObjectBounds != null) { ele.TryPathTo("ObjectBounds", true, out subEle); ObjectBounds.WriteXML(subEle, master); } if (Name != null) { ele.TryPathTo("Name", true, out subEle); Name.WriteXML(subEle, master); } if (BipedData != null) { ele.TryPathTo("BipedData", true, out subEle); BipedData.WriteXML(subEle, master); } if (MaleBipedModelFileName != null) { ele.TryPathTo("Models/Biped/Male/FileName", true, out subEle); MaleBipedModelFileName.WriteXML(subEle, master); } if (MaleBipedModelTextureHashes != null) { ele.TryPathTo("Models/Biped/Male/TextureHashes", true, out subEle); MaleBipedModelTextureHashes.WriteXML(subEle, master); } if (MaleBipedModelAlternateTextures != null) { ele.TryPathTo("Models/Biped/Male/AlternateTextures", true, out subEle); MaleBipedModelAlternateTextures.WriteXML(subEle, master); } if (MaleBipedModelFaceGenModelFlags != null) { ele.TryPathTo("Models/Biped/Male/FaceGenModelFlags", true, out subEle); MaleBipedModelFaceGenModelFlags.WriteXML(subEle, master); } if (MaleWorldModelFileName != null) { ele.TryPathTo("Models/World/Male/FileName", true, out subEle); MaleWorldModelFileName.WriteXML(subEle, master); } if (MaleWorldModelTextureHashes != null) { ele.TryPathTo("Models/World/Male/TextureHashes", true, out subEle); MaleWorldModelTextureHashes.WriteXML(subEle, master); } if (MaleWorldModelAlternateTextures != null) { ele.TryPathTo("Models/World/Male/AlternateTextures", true, out subEle); MaleWorldModelAlternateTextures.WriteXML(subEle, master); } if (MaleInventoryIcon != null) { ele.TryPathTo("Icon/Inventory/Male", true, out subEle); MaleInventoryIcon.WriteXML(subEle, master); } if (MaleMessageIcon != null) { ele.TryPathTo("Icon/Message/Male", true, out subEle); MaleMessageIcon.WriteXML(subEle, master); } if (FemaleBipedModelFileName != null) { ele.TryPathTo("Models/Biped/Female/FileName", true, out subEle); FemaleBipedModelFileName.WriteXML(subEle, master); } if (FemaleBipedModelTextureHashes != null) { ele.TryPathTo("Models/Biped/Female/TextureHashes", true, out subEle); FemaleBipedModelTextureHashes.WriteXML(subEle, master); } if (FemaleBipedModelAlternateTextures != null) { ele.TryPathTo("Models/Biped/Female/AlternateTextures", true, out subEle); FemaleBipedModelAlternateTextures.WriteXML(subEle, master); } if (FemaleBipedModelFaceGenModelFlags != null) { ele.TryPathTo("Models/Biped/Female/FaceGenModelFlags", true, out subEle); FemaleBipedModelFaceGenModelFlags.WriteXML(subEle, master); } if (FemaleWorldModelFileName != null) { ele.TryPathTo("Models/World/Female/FileName", true, out subEle); FemaleWorldModelFileName.WriteXML(subEle, master); } if (FemaleWorldModelTextureHashes != null) { ele.TryPathTo("Models/World/Female/TextureHashes", true, out subEle); FemaleWorldModelTextureHashes.WriteXML(subEle, master); } if (FemaleWorldModelAlternateTextures != null) { ele.TryPathTo("Models/World/Female/AlternateTextures", true, out subEle); FemaleWorldModelAlternateTextures.WriteXML(subEle, master); } if (FemaleInventoryIcon != null) { ele.TryPathTo("Icon/Inventory/Female", true, out subEle); FemaleInventoryIcon.WriteXML(subEle, master); } if (FemaleMessageIcon != null) { ele.TryPathTo("Icon/Message/Female", true, out subEle); FemaleMessageIcon.WriteXML(subEle, master); } if (EquipmentType != null) { ele.TryPathTo("EquipmentType", true, out subEle); EquipmentType.WriteXML(subEle, master); } if (Data != null) { ele.TryPathTo("Data", true, out subEle); Data.WriteXML(subEle, master); } if (ExtraData != null) { ele.TryPathTo("ExtraData", true, out subEle); ExtraData.WriteXML(subEle, master); } }