playMaker

Author Topic: Spin  (Read 2464 times)

wheretheidivides

  • Sr. Member
  • ****
  • Posts: 496
Spin
« on: January 14, 2015, 06:58:54 PM »
I'd like to see a spin action.  So you have a tank that you spawn.  Currently under rotate (or itween rotate), you can set it to rotate to or from.  So it just rotates to that position.  it always goes in the same direction until it is met.  However, what if you want it to spin in the opposite direction 3 times before stopping?

What I'd like to see is a spin.  You can set the from and to, then set the direction (clock or counterclockwise), time to do, number of spins.  Would be nice to use with animation curve to allow a faster spin to start and a slower one to end.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Spin
« Reply #1 on: January 15, 2015, 02:27:20 AM »
Hi,

 I know hotween does this, have you tried that? you can define how many time to loop a tween. Also hotween lets you build chains of tweens and so I think your case is something that hotween will clearly shine and makes you very happy! also makye sure you study how to create all this with just hotween, in playmaker you should only trigger this chain of tween that you defined with hotween interface.

 Bye,

 Jean

wheretheidivides

  • Sr. Member
  • ****
  • Posts: 496
Re: Spin
« Reply #2 on: January 15, 2015, 10:13:41 PM »
I got playmaker so I wouldn't have to use 3rd party programs like hottween.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Spin
« Reply #3 on: January 16, 2015, 03:34:40 AM »
Hi,

 PlayMaker is not an absolute replacement for everything. Its important to realize this. There is not a single project done in Unity ( from indie to AAA titles) that is not a combination of several distinct libraries, like in a wood workshop, there isn't just one tool. I don't see my diy toolbox with just a hammer or a single screwDriver. PlayMaker is a toolbox with many many tools already there, but it can not by definition do everything.

 Even Unity doesn't, the easy escalation for this kind of request would be: Well, then why Unity isn't providing an api for this simple spin you want to do, it should be built in the transform component?

It's critical to embrace the asset store and what it has to offer to boost productivity and workflow. It requires trial and errors, and time yes, but you'll find gems and tools that will change your vision for ever and give your project massive creation license, aside productivity.

 yes, you can write your own custom action to do this spin behavior, you can also simply create an fsm and implement the logic of the spin as is. But everything is already there in very powerful forms to do any kind of crazy spin behaviors: Tweening Engines, they are the perfect tool for this. And in your case, hotween is your best bet.

Please give it a try before dismissing it as a valid solution, I was blown away by its power, even if yes I can do it all myself, I don't ( at least not when I need to be productive). If you have trouble, let me know.

Bye,

 Jean