Pharan đã viết
Oh, that' great. Changing draw order for overlapping things is a really common task, i suppose it could be usefull not only for me. Thank you.
21 Mar 2016, 13:13
udp: I find extension method is more safe on the place, because I update spine-libs pretty oft.
public static void SetDrawOrderToSetupPose(this Skeleton skeleton) {
ExposedList<Slot> slots = skeleton.slots;
skeleton.drawOrder.Clear();
for (int i = 0, n = slots.Count; i < n; i++) {
skeleton.drawOrder.Add(slots.Items[i]);
}
}