Exemple #1
0
        public override void AddChild(nwdbTree child)
        {
            campTreeMileStone ch = child as campTreeMileStone;

            base.AddChild(child);
            if (ch.MilestoneType == null)
            {
                ch.MilestoneType = this.MilestoneType;
            }
        }
Exemple #2
0
        public static campTreeMileStone SeedTreeData(IList <sysMilestoneType> mTypes)
        {
            sysMilestoneType  mPeople, mPlace, mSkill, mFaction, mItem;
            campTreeMileStone msCharacter, msDungeon, msItem, msSkill;

            mPeople  = mTypes.Where(x => x.Name == "People").First();
            mPlace   = mTypes.Where(x => x.Name == "Place").First();
            mSkill   = mTypes.Where(x => x.Name == "Skill").First();
            mFaction = mTypes.Where(x => x.Name == "Faction").First();
            mItem    = mTypes.Where(x => x.Name == "Equipment").First();

            campTreeMileStone mTree = new campTreeMileStone(campConst.campTreeNameMilestone, 0);

            //nwMileStroneTree
            msCharacter = new campTreeMileStone("Character & Faction", mPeople);
            msDungeon   = new campTreeMileStone("Dungeon & Places", mPlace);
            msItem      = new campTreeMileStone("Items & Equipment", mItem);
            msSkill     = new campTreeMileStone("Skills & Lore", mSkill);

            //Add sub Milestones
            msCharacter.AddChild(new campTreeMileStone("Killed", 6));
            msCharacter.AddChild(new campTreeMileStone("Met", 6));
            msCharacter.AddChild(new campTreeMileStone("Made friend", 6));
            msCharacter.AddChild(new campTreeMileStone("Made Enemy", 6));
            msDungeon.AddChild(new campTreeMileStone("Discovered", 6));
            msDungeon.AddChild(new campTreeMileStone("Completed", 6));
            msDungeon.AddChild(new campTreeMileStone("Conquered", 6));
            msDungeon.AddChild(new campTreeMileStone("Destroyed", 6));
            msItem.AddChild(new campTreeMileStone("Gained", 6));
            msItem.AddChild(new campTreeMileStone("Lost", 6));
            msItem.AddChild(new campTreeMileStone("Used", 6));
            msSkill.AddChild(new campTreeMileStone("Learnt Skill", 6));
            msSkill.AddChild(new campTreeMileStone("Gained Language", 6));
            msSkill.AddChild(new campTreeMileStone("Used Stat Lore Book", 6));


            mTree.AddChild(msCharacter);
            mTree.AddChild(msDungeon);
            mTree.AddChild(msItem);
            mTree.AddChild(msSkill);


            return(mTree);
        }