void Awake() { if (m_TagMgr == null) { Debug.LogError("TagsManager not set for " + name + "!"); return; } if (m_TagMgr.tags[index] == "undefined") { Debug.LogError("Tag undefined for " + name + "!"); return; } m_TagMgr.addMe(m_TagMgr.tags[index], gameObject); }