Nate написавTo see if an attachment is hidden for a slot, you get the slot (Skeleton findSlot
) and check if the attachment is null (Slot attachment
). Note each attachment can be in multiple slots at runtime, so you are actually checking the slot.
Thank you! It works like charm.
For the future reference, I will post my code snippet here.
public static class CustomSpineExtension
{
public static bool IsAttachmentHided(this Skeleton skeleton, string slotName)
{
return skeleton.FindSlot(slotName).Attachment == null;
}
public static bool IsAttachmentHided(this Slot slot)
{
return slot.Attachment == null;
}
}