mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-15 19:41:36 +08:00
Reset draw order in setSlotsToSetupPose.
This commit is contained in:
parent
6f2cc72aaf
commit
1e30ad1b72
@ -120,6 +120,7 @@ void Skeleton_setBonesToSetupPose (const Skeleton* self) {
|
||||
|
||||
void Skeleton_setSlotsToSetupPose (const Skeleton* self) {
|
||||
int i;
|
||||
memcpy(self->drawOrder, self->slots, self->slotCount * sizeof(int));
|
||||
for (i = 0; i < self->slotCount; ++i)
|
||||
Slot_setToSetupPose(self->slots[i]);
|
||||
}
|
||||
|
||||
@ -110,6 +110,8 @@ namespace Spine {
|
||||
|
||||
public void SetSlotsToSetupPose () {
|
||||
List<Slot> slots = this.slots;
|
||||
drawOrder.Clear();
|
||||
drawOrder.AddRange(slots);
|
||||
for (int i = 0, n = slots.Count; i < n; i++)
|
||||
slots[i].SetToSetupPose(i);
|
||||
}
|
||||
|
||||
@ -120,9 +120,8 @@ public class Skeleton {
|
||||
}
|
||||
|
||||
public void setSlotsToSetupPose () {
|
||||
drawOrder.clear();
|
||||
drawOrder.addAll(slots);
|
||||
Array<Slot> slots = this.slots;
|
||||
System.arraycopy(slots.items, 0, drawOrder.items, 0, slots.size);
|
||||
for (int i = 0, n = slots.size; i < n; i++)
|
||||
slots.get(i).setToSetupPose(i);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user