public void removeMotionListener(IPlayerMotionListener listener) { if (!motionListeners.Contains(listener)) { motionListeners.Remove(listener); } }
/****************************************************** * add/remove playerMotionListener ******************************************************/ /// <summary> /// listener should only be added after "Awake" method /// </summary> public void addMotionListener(IPlayerMotionListener listener) { if (!motionListeners.Contains(listener)) { motionListeners.Add(listener); } }