Пример #1
0
        private PomlResource ParseResource(XmlNode resource, string basePath)
        {
            var elements = ParseElements(resource, basePath);

            var pomlResource = new PomlResource()
            {
                Elements = elements
            };

            return(pomlResource);
        }
Пример #2
0
        protected void LoadResource(PomlResource pomlResource)
        {
            foreach (var element in pomlResource.Elements)
            {
                var t = LoadElement(element, resourceRoot);
                if (t == null)
                {
                    continue;
                }

                var resource = new Resource()
                {
                    Id         = element.Id,
                    GameObject = t.gameObject
                };
                contentsStore.RegisterResource(resource);
            }
        }