playMaker

Author Topic: My Ball is not blowing up!?!  (Read 2898 times)

henk

  • Playmaker Newbie
  • *
  • Posts: 24
    • Dawson 3D
My Ball is not blowing up!?!
« on: July 21, 2011, 08:17:00 PM »
Check out this video that explains my problem. I'm trying to get a ball to blow up when it hits something. Let me know what you think. Thanks,
Henk


http://gallery.me.com/henkdawson#100751

henk

  • Playmaker Newbie
  • *
  • Posts: 24
    • Dawson 3D
Re: My Ball is not blowing up!?!
« Reply #1 on: July 21, 2011, 09:46:12 PM »
Here are some screen grabs of what the set up looks like.

BTW... I'm looking to hire someone to train me on stuff like this. Email me if you are interested. henk@d3d.com



Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 4000
  • Official Playmaker Support
    • LinkedIn
Re: My Ball is not blowing up!?!
« Reply #2 on: July 21, 2011, 10:23:22 PM »
In this setup, you need to check Every Frame in the Bool Test, and remove the Wait transition (it will cause an infinite loop). This will wait until Contact is True, then send the Explode event.

If an action has an Every Frame option, and you leave it unchecked, then it will only perform its action once when the state is entered then finish.

While the game is running, active actions are highlighted green; actions that have finished are grayed out.

This page on the wiki explains the life cycle of an action in more detail: https://hutonggames.fogbugz.com/default.asp?W174

Another/better way to structure these 2 FSMs is to just send the Explode event to the Cannon Ball FSM (instead of testing a bool every frame). In 1.1 use Send Event To FSM. In 1.2 (coming soon) just use Send Event and set the target.

Hope that helps!


henk

  • Playmaker Newbie
  • *
  • Posts: 24
    • Dawson 3D
Re: My Ball is not blowing up!?!
« Reply #3 on: July 22, 2011, 02:20:13 PM »
Thanks Alex - I got it to work. Here's a tutorial on what I learned: http://hutonggames.com/playmakerforum/index.php?topic=471.0