Exemple #1
0
        public void RegisterCreator(string name, GuideTriggerCreator creator)
        {
            if (m_CreatorMap.ContainsKey(name))
            {
                Log.W("Already Add Creator for :" + name);
                return;
            }

            m_CreatorMap.Add(name, creator);
        }
Exemple #2
0
        public IGuideTrigger Create(string name)
        {
            GuideTriggerCreator creator = null;

            if (m_CreatorMap.TryGetValue(name, out creator))
            {
                return(creator());
            }

            return(null);
        }