internal void Call(Action action) { try { //if (Thread.CurrentThread.ManagedThreadId == m_unityThreadId && ! // Thread.CurrentThread.IsBackground) { if (ThreadHelper.Instance.IsUnityThread) { // Make sure to keep actions in order CallActions(); action(); } else { lock (m_actions) { m_actions.Add(action); } } } catch (Exception x) { m_logger.Exception(x); } }