playMaker

Author Topic: My first FSM with Playmaker  (Read 2446 times)

zeeawk

  • Playmaker Newbie
  • *
  • Posts: 12
My first FSM with Playmaker
« on: May 26, 2013, 02:53:22 PM »
This is the first FSM I have created with Playmaker.
Looking for feedback if I'm on the right track or perhaps have too many things going on.

"Got Hit" and "Check Idle Distance" state transition to the global "chase" event.
Also "hit" event is being fired off from code from fsm.SendEvent with EventData set with damage amount.
"Chase Player" plays walking animation and sends message to fire off pathfinding and movement.
"Attack", "Got Hit", "Died" play animation and sound

Still need to add a spawn item on died for player to pick up items.

Thanks!


jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: My first FSM with Playmaker
« Reply #1 on: May 27, 2013, 01:28:37 AM »
Hi

 Looks just fine.

I always have my events all caps tho, but that's really cosmetic and a matter of taste... so all is good, especially the fact that you name your states and events properly, VERY important!

bye,

 Jean

zeeawk

  • Playmaker Newbie
  • *
  • Posts: 12
Re: My first FSM with Playmaker
« Reply #2 on: May 27, 2013, 02:14:34 PM »
Thanks for the feedback Jean!

What is your reasoning behind naming events all caps?
I was thinking about naming global events with all caps.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: My first FSM with Playmaker
« Reply #3 on: May 28, 2013, 01:47:18 AM »
Hi,
 
 Simply because it looks nicer to my eyes ( purely a matter of taste here), and also because all built in events are all capst already, so it feels more consistent.

bye,

 Jean