I've come across an odd bug that has had me stumped for a week because I couldn't work out what was actually triggering it. I finally tracked it down and can reproduce it, but it only triggers when the editor window is open, and it doesn't trigger at all when the window is closed.
I'm pretty sure it could be related to the Broadcast Event action, as it is triggering after one of these. The stack trace takes it back to one anyway.
The code it crashes on is here :
if (float1.Value < float2.Value)
{
// Crashes on the next line with null ref
Fsm.Event(lessThan);
return;
}
And that is inside the DoCompare() function of the FloatCompare Action. I've tried attaching the debugger and working through it in MonoDevelop, but everything seems to be fine there, so I'm wondering if there is something strange going on internally inside the editor, eg. the broadcast message is possibly going to un-instantiated prefabs inside the editor? This is about that only behavior that makes sense to me right now.