Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

README.md 2.6KB

10 år sedan
10 år sedan
10 år sedan
10 år sedan
10 år sedan
10 år sedan
10 år sedan
10 år sedan
10 år sedan
10 år sedan
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. coa4u
  2. =====
  3. ## Cocos2d-like Actions for Unity3d
  4. Unity3d is a very good game engine. It's almost perfect for quick prototyping.
  5. After switching from Cocos2D to Unity3d, i'm still missing just one cocos's feature - actions.
  6. It's a great combination of simplicity and flexibility, and i haven't found the suitable replacement for it.
  7. Since actions are quite simple, i implemented them myself.
  8. ### How to use
  9. Just put the src folder into your assets folder.
  10. Then attach the Actor.cs script to the object you want.
  11. See the examples folder, there's a sample script there.
  12. You can also subclass the Actor and add all the actions you want to the Start() method.
  13. ### Included actions (ready and WIP)
  14. All actions are designed to word in 3D scene (i.e. using Vector3 for movement, rotation and scaling).
  15. You can use it in 2D with apropriate vectors, but i'm going to add support for 2D actions soon.
  16. Base actions
  17. - [x] Sequence
  18. - [x] Parallel
  19. - [x] Repeat and Loop *implemented in one action*
  20. - [ ] Reverse *not yet, but every reversable action has working reverse() method*
  21. Interval actions
  22. - [x] Delay and RandomDelay *implemented in one action*
  23. - [x] MoveTo
  24. - [x] MoveBy
  25. - [x] RotateTo
  26. - [x] RotateBy
  27. - [x] ScaleTo
  28. - [x] ScaleBy
  29. - [x] TintBy *if you want to manipulate alpha, your material must support transparency*
  30. - [x] TintTo *if you want to manipulate alpha, your material must support transparency*
  31. - [ ] FadeOut *if you want to manipulate alpha, your material must support transparency*
  32. - [ ] FadeIn *if you want to manipulate alpha, your material must support transparency*
  33. - [ ] FadeTo *if you want to manipulate alpha, your material must support transparency*
  34. - [x] FadeBy *if you want to manipulate alpha, your material must support transparency*
  35. - [ ] JumpTo
  36. - [ ] JumpBy
  37. - [ ] Bezier
  38. - [ ] Blink
  39. Instant actions
  40. - [x] Place *renamed to SetPlace*
  41. - [x] CallFunc *renamed to SendMessage*
  42. - [x] Hide
  43. - [x] Show
  44. - [x] ToggleVisibility
  45. ### Some additional actions
  46. Interval actions
  47. - [ ] SkewBy
  48. - [ ] SkewTo
  49. Instant actions
  50. - [x] SetRotation
  51. - [x] SetTint
  52. ### Future plans
  53. After completing these actions, i'm going to add some more to the list.
  54. ## License
  55. Just like Cocos2D, this code licensed under the [MIT License](http://en.wikipedia.org/wiki/MIT_License)
  56. ## Help and donations
  57. I'm not doing it to make profit, but if you want, [you can send me a couple of bucks via PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=Z64675TKXFRFU).
  58. Also, if you'll write some action based on mine, feel free to send it to me, if you want me to add it to the library. I'll put your name on this page.