You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

README.md 2.7KB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  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. 1. Put the src folder into your assets folder.
  10. 2. Then attach the Actor.cs script to the object you want.
  11. 3. See the ActorSampleActions.cs class, if you need examples.
  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 capable to work both in 3D (use Vector3) and 2D (use Vector2) scenes.
  15. Base actions
  16. - [x] Sequence
  17. - [x] Parallel
  18. - [x] Repeat and Loop *implemented in one action*
  19. *Every reversable action has a reverse() method. So, no plans for Reverse action right now.*
  20. Interval actions
  21. - [x] Delay and RandomDelay *implemented in one action*
  22. - [x] MoveTo
  23. - [x] MoveBy
  24. - [x] RotateTo
  25. - [x] RotateBy
  26. - [x] ScaleTo
  27. - [x] ScaleBy
  28. - [x] BezierAbs
  29. - [x] BezierRel
  30. - [x] JumpTo *uses Bezier action to move the object*
  31. - [x] JumpBy *uses Bezier action to move the object*
  32. - [x] Blink
  33. *if you want to manipulate alpha with the following actions, your material should support transparency (i.e. use Transparent shader)*
  34. - [x] TintBy
  35. - [x] TintTo
  36. - [x] FadeOut
  37. - [x] FadeIn
  38. - [x] FadeTo
  39. - [x] FadeBy
  40. Instant actions
  41. - [x] Place *renamed to SetPlace*
  42. - [x] CallFunc *renamed to SendMessage*
  43. - [x] Hide
  44. - [x] Show
  45. - [x] ToggleVisibility
  46. There's no plans for 3DGrid actions. You can use the 3D actions instead.
  47. ### Some additional actions
  48. Base actions
  49. - [x] Random - randomly choises and does one action from the given list.
  50. Interval actions
  51. *These two actions requires the using of MeshActor script instead of Actor.*
  52. - [x] SkewBy - skews the mesh by given values.
  53. - [ ] SkewTo - skews the mesh to the given values.
  54. Instant actions
  55. - [x] SetRotation - instantly rotates the object to the given euler angles.
  56. - [x] SetTint - instantly tints the object to the given color.
  57. ### Future plans
  58. After completing these actions, i'm going to add some more to the list.
  59. ## License
  60. Just like Cocos2D, this code licensed under the [MIT License](http://en.wikipedia.org/wiki/MIT_License)
  61. ## Help and donations
  62. 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).
  63. 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.