BugFix for AnyState().OnChange(0) null ptr error

When we call eventManager.AnyState(0); without actually adding OnChange
would cause NullReferenceException.
Here is a small patch. :)