Exemple #1
0
        private void Preprocess(PathingCategory rootPathingCategory)
        {
            // Assign ParentCategory
            if (this.TryGetAggregatedAttributeValue(PackConstImpl.XML_KNOWNATTRIBUTE_TYPE, out string categoryNamespace))
            {
                this.ParentPathingCategory = rootPathingCategory.GetOrAddCategoryFromNamespace(categoryNamespace);

                this.ExplicitAttributes.AddOrUpdateAttribute(new DynamicAttribute(PackConstImpl.XML_KNOWNATTRIBUTE_TYPE, () => this.ParentPathingCategory.Namespace));
            }

            // Assign MapId
            if (this.TryGetAggregatedAttributeValue(PackConstImpl.XML_KNOWNATTRIBUTE_MAPID, out string mapId))
            {
                InvariantParseUtil.TryParseInt(mapId, out _mapId);
            }
        }
Exemple #2
0
 private Trail(IPackResourceManager resourceManager, AttributeCollection explicitAttributes, PathingCategory rootPathingCategory)
     : base(resourceManager, PointOfInterestType.Trail, explicitAttributes, rootPathingCategory) /* NOOP */ }
Exemple #3
0
        public PointOfInterest(IPackResourceManager resourceManager, PointOfInterestType type, AttributeCollection explicitAttributes, PathingCategory rootPathingCategory)
        {
            this.ResourceManager    = resourceManager;
            this.Type               = type;
            this.ExplicitAttributes = explicitAttributes;

            Preprocess(rootPathingCategory);
        }