playMaker

Author Topic: Execute Script Action  (Read 8105 times)

aliessmael

  • Playmaker Newbie
  • *
  • Posts: 26
Execute Script Action
« on: February 17, 2012, 06:34:05 AM »
some time when i work in some FSM , i find it is easier to do it in scripting.
like working in array and looping .

it will be amazing if you support this action,
and make my FSM variable accessible from this script.

I know the idea of playMaker is to kick scripting. but this action give me all ability to do any thing, and make playMaker my Favorite tool.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Execute Script Action
« Reply #1 on: February 17, 2012, 02:32:11 PM »
Hi,

 Actually, I don't think it's totally the idea to wipe out scripting, Each actions is scripted. What playmaker gives you is the power to work with events and states, but each actions remains standard script, totally open for you do create new actions, doing all the crazy things you want. no limitation there ( and if there is... make sure you mention it in this forum).

 as for array, give arrayMaker a go, it might offer you a good starting point for working with array within playmaker.

https://hutonggames.fogbugz.com/?W715

as for looping, Alex introduced few weeks ago a very nice action showing off how to loop beautifully in playmaker.

http://hutonggames.com/playmakerforum/index.php?topic=1088.msg4553;topicseen#msg4553

If you are ok with scripting, you will likely find the right balance between scripting outside playmaker and actually create the actions you need to stay within playmaker environment. Personnally, I very much enjoy creating actions to still benefit from the HUGE benefit of working with events and states.  For some process like inverse kinematics and highly mathematical/trigonometric stuff involving numerous variables and complex equations,  yes scripting has the edge over playmaker in terms of clarity.

Bye,

 Jean

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 4000
  • Official Playmaker Support
    • LinkedIn
Re: Execute Script Action
« Reply #2 on: February 17, 2012, 03:05:43 PM »
There are some Script Control actions that might do what you need:
https://hutonggames.fogbugz.com/default.asp?W44

To access FSM variables in scripts is also fairly easy:
https://hutonggames.fogbugz.com/default.asp?W329

Does that help?

aliessmael

  • Playmaker Newbie
  • *
  • Posts: 26
Re: Execute Script Action
« Reply #3 on: February 17, 2012, 04:26:04 PM »
I agree with you for all what you said.
but this action which i write for fast few command should be not visible in actions selector editor(because it is not standard action). may be by adding some attribute to my action
and for me i prefer to hide it from my project , because it is temporary action for specific FSM
at the end i will find a lot of these temporary actions in my project.and i should copy all of these action to any new project because i may use some FSM template which is use them.
so i prefer to save these action inside FSM itself.

and it is easier and faster for me to type these action in action editor directly.

may be it is not important feature , but it will be a star plus to playMaker.

if playMaker support custom action editor , i may have fun trying to do it.

Thanks