// Magica Cloth 2. // Copyright (c) 2023 MagicaSoft. // https://magicasoft.jp using System.Collections.Generic; using UnityEngine; namespace MagicaCloth2 { /// /// Serialize data (2) /// Parts that cannot be exported externally. /// [System.Serializable] public class ClothSerializeData2 : IDataValidate, IValid, ITransform { /// /// 頂点ペイントデータ /// vertex paint data. /// [SerializeField] public SelectionData selectionData = new SelectionData(); /// /// Transformと頂点属性辞書データ /// 実行時でのBoneCloth/BoneSpring作成時にはこの辞書にTransformと頂点属性のペアを格納することで頂点ペイントデータの代わりにすることができます。 /// Transform and vertex attribute dictionary data. /// When creating BoneCloth/BoneSpring at runtime, you can store Transform and vertex attribute pairs in this dictionary and use it instead of vertex paint data. /// public Dictionary boneAttributeDict = new Dictionary(); /// /// PreBuild Data. /// public PreBuildSerializeData preBuildData = new PreBuildSerializeData(); //========================================================================================= public ClothSerializeData2() { } /// /// クロスを構築するための最低限の情報が揃っているかチェックする /// Check if you have the minimum information to construct the cloth. /// /// public bool IsValid() { return true; } public void DataValidate() { } /// /// エディタメッシュの更新を判定するためのハッシュコード /// Hashcode for determining editor mesh updates. /// /// public override int GetHashCode() { int hash = 0; return hash; } public void GetUsedTransform(HashSet transformSet) { preBuildData.GetUsedTransform(transformSet); } public void ReplaceTransform(Dictionary replaceDict) { preBuildData.ReplaceTransform(replaceDict); } } }