Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: Nekoyoubi on April 07, 2011, 08:07:28 AM
-
I know I must be missing something simple here, but what would be the suggested way to modify a property on a GameObject's component using PlayMaker?
An easy example of what I mean would be adjusting an EllipsoidParticleEmitter.LocalVelocity property to (poorly) apply some force to a flame while a certain state of an FSM is active.
So many actions are so obvious to me that I'm sure I must just be missing the obvious somewhere. Is there an action to do this, or does a custom script need to be applied for any change to components that you want to do?
Any help would be greatly appreciated. Thanks much in advance!
-
Right now you have to write a custom action. The custom action is a simple interface to the component. See https://hutonggames.fogbugz.com/default.asp?W540 for an example.
I do want to make particle emitter actions for the next update.
Might also make some kind of custom action wizard for this kind of trivial component access...
-
I was thinking of creating a custom particle system using FSMs that would have a lot of features Unity's particle system doesn't have. Getting actions that give you access to the current particle system would be great too, I'm just sharing a thought.
What I think would be awesome is if you build a fairly complex FSM, like the one I mentioned, and have a wizard in Playmaker that builds a compounded "Super" action that exposes only the parameters that I choose. That way I could use my custom particle system in one neat "Super action" in a state wherever I please.
I think the idea of "Super actions" would be great, where you build a bunch of states/actions together and then Playmaker allows you to bundle this up into an action with only the parameters you choose to be exposed. You could re-use it easily. I guess I could always store it in a gameobject and have it called upon whenever I wanted but to adjust the parameters would be a bit trickier.
-
Yes, "super actions" would help tremendously, especially for reusability. Virtools has something like that, you group some states together and make one entoty visually. Very handy.
Bye,
Jean