What you see is the inside of our character, the weird lines should have been clothes.
I can't really figure out why it doesnt work :)
public void Align(Transform newParent, Transform asset)
{
for(int i = 0; i < newParent.childCount; i++)
{
foreach(Transform bone in asset)
{
if(bone.gameObject.name == newParent.GetChild(i).name)
{
Debug.Log("Found a pair!");
bone.SetParent(newParent.GetChild(i), true);
bone.transform.position = newParent.GetChild(i).transform.position;
bone.transform.rotation = newParent.GetChild(i).transform.rotation;
bone.transform.localScale = new Vector3(1.5f, 1.5f, 1.5f);
Align(newParent.GetChild(i), bone);
}
}
}
}
AlignClothMesh align = GetComponent<AlignClothMesh>();
align.Align(player.transform, top.transform);
align.Align(player.transform, pant.transform);

