playMaker

Author Topic: A request: "sticky" debug variables  (Read 1663 times)

jerware

  • Playmaker Newbie
  • *
  • Posts: 23
    • View Profile
A request: "sticky" debug variables
« on: March 29, 2013, 01:56:21 PM »
The ability to turn on debug mode and see your variable values is extremely useful, but I wish that each debug field displayed the value when it completed that action, rather than a value after the last action/state to execute. That would make debugging far easier. As it is, I often disable event transitions and actions just to get the program to "break" on a given action so I can see the correct values.

Maybe I'm missing a better way to debug?

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3643
  • Official Playmaker Support
    • View Profile
    • LinkedIn
Re: A request: "sticky" debug variables
« Reply #1 on: March 29, 2013, 02:06:04 PM »
You should be able to use Debug Flow to track how variables change with state changes.

Enable Debug Flow in the FSM tab, then when you pause the game you can use Prev and Next in the debug toolbar to step through state changes. At each state change, the State Inspector should show the values of variables at that time...

You can also open the FSM Log window and click any entry to sync to that time.

jerware

  • Playmaker Newbie
  • *
  • Posts: 23
    • View Profile
Re: A request: "sticky" debug variables
« Reply #2 on: March 29, 2013, 02:26:55 PM »
Thanks for the reply, Alex. Debug flow is very cool, but it doesn't solve the problem of tracking variables that are affected by numerous actions in the same state. That's why, in debug mode, it would be handy to optionally see the variables as they were when each action completed its task.

Another way to look at it is stepping through actions, not just states.

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3643
  • Official Playmaker Support
    • View Profile
    • LinkedIn
Re: A request: "sticky" debug variables
« Reply #3 on: March 29, 2013, 03:26:20 PM »
Ahhh, ok, I understand now...

I'll think about how we can do this. Right now you could use a Debug action to log the current value. Not super convenient, but might help...