예제 #1
0
        public GameObject GetGameObject(string _path, Action <GameObject> _callBack)
        {
            GameObjectFactoryUnit unit;

            if (!dic.TryGetValue(_path, out unit))
            {
                unit = new GameObjectFactoryUnit(_path);

                dic.Add(_path, unit);
            }

            return(unit.GetGameObject(_callBack));
        }
예제 #2
0
        public void PreloadGameObject(string _path, Action _callBack)
        {
            GameObjectFactoryUnit unit;

            if (!dic.TryGetValue(_path, out unit))
            {
                unit = new GameObjectFactoryUnit(_path);

                dic.Add(_path, unit);
            }

            unit.GetGameObject(_callBack);
        }
예제 #3
0
        public bool Hold(string _path)
        {
            if (!dic.ContainsKey(_path))
            {
                return(false);
            }
            else
            {
                GameObjectFactoryUnit unit = dic[_path];

                unit.AddUseNum();

                return(true);
            }
        }
예제 #4
0
        public GameObject GetGameObject(string _path, Action <GameObject, string> _callBack)
        {
            GameObjectFactoryUnit unit;

            if (!dic.ContainsKey(_path))
            {
                unit = new GameObjectFactoryUnit(_path);

                dic.Add(_path, unit);
            }
            else
            {
                unit = dic [_path];
            }

            return(unit.GetGameObject(_callBack));
        }
예제 #5
0
        public void PreloadGameObject(string _path, Action <string> _callBack)
        {
            GameObjectFactoryUnit unit;

            if (!dic.ContainsKey(_path))
            {
                unit = new GameObjectFactoryUnit(_path);

                dic.Add(_path, unit);
            }
            else
            {
                unit = dic [_path];
            }

            unit.PreloadGameObject(_callBack);
        }