public void AddController(EffectLevelController ctrl) { if (ctrl == null) { return; } m_allCtrls = m_allCtrls ?? new HashSet <EffectLevelController>(); if (!m_allCtrls.Contains(ctrl)) { m_allCtrls.Add(ctrl); } }
public void RemoveController(EffectLevelController ctrl) { if (ctrl == null) { return; } if (m_allCtrls == null) { return; } if (m_allCtrls.Contains(ctrl)) { m_allCtrls.Remove(ctrl); } }