mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-20 17:26:01 +08:00
use the states provided
This allows animations to be scaled/moved easily
This commit is contained in:
parent
695db31d71
commit
f77459983f
@ -23,7 +23,8 @@ void Skeleton::draw (RenderTarget& target, RenderStates states) const {
|
|||||||
const_cast<Skeleton*>(this)->vertexArray.clear();
|
const_cast<Skeleton*>(this)->vertexArray.clear();
|
||||||
for (int i = 0, n = slots.size(); i < n; i++)
|
for (int i = 0, n = slots.size(); i < n; i++)
|
||||||
if (slots[i]->attachment) slots[i]->attachment->draw(slots[i]);
|
if (slots[i]->attachment) slots[i]->attachment->draw(slots[i]);
|
||||||
target.draw(vertexArray, texture);
|
states.texture = texture;
|
||||||
|
target.draw(vertexArray, states);
|
||||||
}
|
}
|
||||||
|
|
||||||
} /* namespace spine */
|
} /* namespace spine */
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user