Advertisement
Guest User

Untitled

a guest
Feb 9th, 2016
2,223
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. function RotationAnimation ()
  2. {
  3. var anim: Animator = outTwo.transform.gameObject.GetComponent(Animator);
  4.  
  5. if (rotCount == 1)
  6. {
  7. anim.SetBool("rotate360", false);
  8. anim.SetBool("rotate90", true);
  9. }
  10. else if (rotCount == 2)
  11. {
  12. anim.SetBool("rotate180", true);
  13. anim.SetBool("rotate90", false);
  14. }
  15. else if (rotCount == 3)
  16. {
  17. anim.SetBool("rotate270", true);
  18. anim.SetBool("rotate180", false);
  19. }
  20. else if (rotCount == 4)
  21. {
  22. anim.SetBool("rotate360", true);
  23. anim.SetBool("rotate270", false);
  24. rotCount = 0;
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement