Example #1
0
        public static void InitializeConfiguration(SlayerTitleCore core)
        {
            core.Enabled = false;

            bool sheepExists = false;

            foreach (TitleDefinition def in core.TitleDefinitions)
                if (def.DefinitionName == "Sheep Slayer")
                    sheepExists = true;

            if (!sheepExists)
            {
                core.TitleDefinitions.Add(new TitleDefinition("Sheep Slayer", false,
                    new List<Type>()
                    {
                        typeof(Sheep) 
                    },
                    new List<TitleEntry>()
                    {
                        new TitleEntry("Hunter of Mutton", 50),
                        new TitleEntry("Master of the Feast", 100),
                        new TitleEntry("Mammoth of the Wool", 250)
                    }));
            }

            bool dragonExists = false;

            foreach (TitleDefinition def in core.TitleDefinitions)
                if (def.DefinitionName == "Dragon Slayer")
                    dragonExists = true;

            if (!dragonExists)
            {
                core.TitleDefinitions.Add(new TitleDefinition("Dragon Slayer", false,
                    new List<Type>()
                    {
                        typeof(Wyvern),
                        typeof(Drake),
                        typeof(Dragon),
                        typeof(WyvernRenowned),
                        typeof(WhiteWyrm),
                        typeof(ShadowWyrm),
                        typeof(AncientWyrm),
                        typeof(StygianDragon),
                        typeof(CrimsonDragon),
                        typeof(GreaterDragon),
                        typeof(SerpentineDragon),
                        typeof(SkeletalDragon)
                    },
                    new List<TitleEntry>()
                    {
                        new TitleEntry("Apprentice Dragonslayer", 50),
                        new TitleEntry("Accomplished Dragon Hunter", 250),
                        new TitleEntry("Master of the Leather Winged", 1000),
                        new TitleEntry("Terror of the Skyborn", 5000)
                    }));
            }

            core.CrossReferenceDefinitions();
        }
Example #2
0
        public static void Initialize()
        {
            SlayerTitleCore core = World.GetCore(typeof(SlayerTitleCore)) as SlayerTitleCore;

            if (core == null)
            {
                core = new SlayerTitleCore();

                SlayerTitleDef.InitializeConfiguration(core);

                core.Prep();
            }

            m_Core = core;

            CommandSystem.Register("STS", AccessLevel.Developer, new CommandEventHandler(STS_OnCommand));
        }
Example #3
0
        public static void Initialize()
        {
            SlayerTitleCore core = World.GetCore(typeof(SlayerTitleCore)) as SlayerTitleCore;

            if (core == null)
            {
                core = new SlayerTitleCore();

                SlayerTitleDef.InitializeConfiguration(core);

                core.Prep();
            }

            m_Core = core;

            CommandSystem.Register("STS", AccessLevel.Developer, new CommandEventHandler(STS_OnCommand));
        }
Example #4
0
        public static void InitializeConfiguration(SlayerTitleCore core)
        {
            core.Enabled = false;

            bool sheepExists = false;

            foreach (TitleDefinition def in core.TitleDefinitions)
            {
                if (def.DefinitionName == "Sheep Slayer")
                {
                    sheepExists = true;
                }
            }

            if (!sheepExists)
            {
                core.TitleDefinitions.Add(new TitleDefinition("Sheep Slayer", false,
                                                              new List <Type>()
                {
                    typeof(Sheep)
                },
                                                              new List <TitleEntry>()
                {
                    new TitleEntry("Hunter of Mutton", 50),
                    new TitleEntry("Master of the Feast", 100),
                    new TitleEntry("Mammoth of the Wool", 250)
                }));
            }

            bool dragonExists = false;

            foreach (TitleDefinition def in core.TitleDefinitions)
            {
                if (def.DefinitionName == "Dragon Slayer")
                {
                    dragonExists = true;
                }
            }

            if (!dragonExists)
            {
                core.TitleDefinitions.Add(new TitleDefinition("Dragon Slayer", false,
                                                              new List <Type>()
                {
                    typeof(Wyvern),
                    typeof(Drake),
                    typeof(Dragon),
                    typeof(WyvernRenowned),
                    typeof(WhiteWyrm),
                    typeof(ShadowWyrm),
                    typeof(AncientWyrm),
                    typeof(StygianDragon),
                    typeof(CrimsonDragon),
                    typeof(GreaterDragon),
                    typeof(SerpentineDragon),
                    typeof(SkeletalDragon)
                },
                                                              new List <TitleEntry>()
                {
                    new TitleEntry("Apprentice Dragonslayer", 50),
                    new TitleEntry("Accomplished Dragon Hunter", 250),
                    new TitleEntry("Master of the Leather Winged", 1000),
                    new TitleEntry("Terror of the Skyborn", 5000)
                }));
            }

            core.CrossReferenceDefinitions();
        }