Hello,
Is it possible to draw animated sprite using script? Something like GUI.DrawTexture.
Hello,
Is it possible to draw animated sprite using script? Something like GUI.DrawTexture.
Hello,
In theory you can create and write any texture you want. I don’t know what you exaclty want to do, but i guess you should use a spriteSheet.
http://unity3d.com/learn/tutorials/modules/beginner/2d/sprite-editor
It’s not what I’m looking for.
I created sprite that is animated when I place it by draging it to the scene. What i want to do is to draw this sprite by code. So I can place it whenever I want and let’s say when I press button then an sprite wil be shown.
just as a thought, throwing my 2pence worth in :), have you had a look at using the state machine in mechanim to handle sprite animations?
ive used it in my last 2D project for sprite animation, and its fully controllable by code. ive got different animations playing for walking when button pressed, dying, falling etc…
Solved!
THANK YOU!