示例#1
0
        public uint GetJobGearSet(ClassJobType requiredJob)
        {
            switch (requiredJob)
            {
                case ClassJobType.Alchemist:
                    return decimal.ToUInt32(numAlch.Value);
                case ClassJobType.Armorer:
                    return decimal.ToUInt32(numArm.Value);
                case ClassJobType.Blacksmith:
                    return decimal.ToUInt32(numBsm.Value);
                case ClassJobType.Carpenter:
                    return decimal.ToUInt32(numCarp.Value);
                case ClassJobType.Culinarian:
                    return decimal.ToUInt32(numCul.Value);
                case ClassJobType.Goldsmith:
                    return decimal.ToUInt32(numGold.Value);
                case ClassJobType.Leatherworker:
                    return decimal.ToUInt32(numLtw.Value);
                case ClassJobType.Weaver:
                    return decimal.ToUInt32(numWeav.Value);
                default: //Just in case I derp out and request something I can't craft with?!?!
                    return 0;

            }
        }
示例#2
0
文件: Touch.cs 项目: Rawrskyes/crafty
 public ClassTouch(ClassJobType job, uint touch1, uint touch2, uint touch3)
 {
     Job = job;
     Touch1 = touch1;
     Touch2 = touch2;
     Touch3 = touch3;
 }
示例#3
0
 public Leve(uint inId, string inName, string inEnglishName, string inJapaneseName, uint inLevel, ClassJobType inClassJobType, uint inItemId, string inItemName, string inEngName, string inJpnName, uint inItemQty, string inPickUpLocation, string inPickUpNpc, uint inPickUpNpcId, string inPickupXYZ, string inTurnInLocation, string inTurnInNpc, uint inTurnInNpcId, string inTurnInXYZ, uint inStartMap, uint inStartAeth, uint inEndMap, uint inEndAeth, bool inLimsaAeth, bool inUldahAeth)
 {
     LeveID = inId;
     Name = inName;
     EnglishName = inEnglishName;
     JapaneseName = inJapaneseName;
     Level = inLevel;
     ClassJobType = inClassJobType;
     ItemId = inItemId;
     ItemName = inItemName;
     EngName = inEngName;
     JpnName = inJpnName;
     ItemQty = inItemQty;
     PickUpLocation = inPickUpLocation;
     PickUpNpc = inPickUpNpc;
     PickUpNpcId = inPickUpNpcId;
     PickupXYZ = inPickupXYZ;
     TurnInLocation = inTurnInLocation;
     TurnInNpc = inTurnInNpc;
     TurnInNpcId = inTurnInNpcId;
     TurnInXYZ = inTurnInXYZ;
     StartMap = inStartMap;
     StartAeth = inStartAeth;
     EndMap = inEndMap;
     EndAeth = inEndAeth;
     LimsaAeth = inLimsaAeth;
     UldahAeth = inUldahAeth;
 }
示例#4
0
        public static bool ChangeRequired(ClassJobType requiredJobType)
        {
            //If we're what we need to be, don't change.
            if (Core.Me.CurrentJob == requiredJobType) return false;

            //Else we need to change.
            return true;
        }
示例#5
0
 public Recipe(int inId, int inItemId, ClassJobType inClassJobType, string inName, string inEnglishName, string inJapaneseName, int inLevel, int inStars, int inDurability, int inQuality, int inDifficulty, int inCraftmanship, int inControl, bool inCollectable)
 {
     Id = inId;
     ItemId = inItemId;
     ClassJobType = inClassJobType;
     Name = inName;
     EnglishName = inEnglishName;
     JapaneseName = inJapaneseName;
     Level = inLevel;
     Stars = inStars;
     Durability = inDurability;
     Quality = inQuality;
     Difficulty = inDifficulty;
     Craftmanship = inCraftmanship;
     Control = inControl;
     Collectable = inCollectable;
 }
示例#6
0
 //Search for a recipe by name. Return empty recipe if not found.
 public static Recipe getRecipe(string name, ClassJobType job)
 {
     foreach (var j in jobs)
     {
         if (job == j.ClassJob)
         {
             foreach (var r in j.Recipes)
             {
                 if (r.Name.ToLower().Equals(name.ToLower()))
                 {
                     return r;
                 }
             }
         }
     }
     return new Recipe();
 }
示例#7
0
 //Search by id!
 public static Recipe getRecipe(uint id, ClassJobType job)
 {
     foreach (var j in jobs)
     {
         if (job == j.ClassJob)
         {
             foreach (var r in j.Recipes)
             {
                 if (r.Id == id)
                 {
                     return r;
                 }
             }
         }
     }
     return new Recipe();
 }
示例#8
0
 /// <summary>
 /// Checks if the passed classtype is a crafting class.
 /// </summary>
 /// <param name="classType"></param>
 /// <returns></returns>
 public static bool IsCraftingClass(ClassJobType classType)
 {
     switch (classType)
     {
         case ClassJobType.Carpenter:
         case ClassJobType.Blacksmith:
         case ClassJobType.Armorer:
         case ClassJobType.Goldsmith:
         case ClassJobType.Leatherworker:
         case ClassJobType.Weaver:
         case ClassJobType.Alchemist:
         case ClassJobType.Culinarian:
             return true;
         default:
             return false;
     }
 }
示例#9
0
        private static Dictionary<uint, int> LoadSpells(ClassJobType jobType)
        {
            switch (jobType)
            {
                case ClassJobType.Scholar:
                    return LoadScholarSpells();

                case ClassJobType.WhiteMage:
                    return LoadWhiteMageSpells();

                case ClassJobType.Conjurer:
                    return LoadWhiteMageSpells();

                default:
                    return _spells = new Dictionary<uint, int>();

            }
        }
示例#10
0
        /// <summary>
        /// Loads the requested class data.
        /// </summary>
        /// <param name="classType"></param>
        ///             

        public void Load(ClassJobType classType)
        {
            // Set the name.
            Name = classType.ToString();
            // Set the ttype.
            Type = classType;

            // Switch between the type and load the proper list.
            switch (classType)
            {
                case ClassJobType.Carpenter:
                    Name = "刻木匠";
                    Actions = new CarpenterActions();
                    break;
                case ClassJobType.Blacksmith:
                    Name = "锻铁匠";
                    Actions = new BlacksmithActions();
                    break;
                case ClassJobType.Armorer:
                    Name = "铸甲匠";
                    Actions = new ArmorerActions();
                    break;
                case ClassJobType.Goldsmith:
                    Name = "雕金匠";
                    Actions = new GoldsmithActions();
                    break;
                case ClassJobType.Leatherworker:
                    Name = "制革匠";
                    Actions = new LeatherworkerActions();
                    break;
                case ClassJobType.Weaver:
                    Name = "裁衣匠";
                    Actions = new WeaverActions();
                    break;
                case ClassJobType.Alchemist:
                    Name = "炼金术士";
                    Actions = new AlchemistActions();
                    break;
                case ClassJobType.Culinarian:
                    Name = "烹调师";
                    Actions = new CulinarianActions();
                    break;
            }
        }
示例#11
0
 /// <summary>
 /// Checks the passed ClassJobType and returns the baseclass.
 /// </summary>
 /// <param name="classType"></param>
 /// <returns></returns>
 public static ClassJobType ReturnBaseClass(ClassJobType classType)
 {
     switch (classType)
     {
         case ClassJobType.Carpenter:
             return ClassJobType.Carpenter;
         case ClassJobType.Blacksmith:
             return ClassJobType.Blacksmith;
         case ClassJobType.Armorer:
             return ClassJobType.Armorer;
         case ClassJobType.Goldsmith:
             return ClassJobType.Goldsmith;
         case ClassJobType.Leatherworker:
             return ClassJobType.Leatherworker;
         case ClassJobType.Weaver:
             return ClassJobType.Weaver;
         case ClassJobType.Alchemist:
             return ClassJobType.Alchemist;
         case ClassJobType.Culinarian:
             return ClassJobType.Culinarian;
         default:
             return ClassJobType.Carpenter;
     }
 }
 private static IRotation GetRotation(ClassJobType ClassJob)
 {
     switch (ClassJob)
     {
         #region Combat
         #region Class
         case ClassJobType.Arcanist:
             return new Arcanist();
         case ClassJobType.Archer:
             return new Archer();
         case ClassJobType.Conjurer:
             return new Conjurer();
         case ClassJobType.Gladiator:
             return new Gladiator();
         case ClassJobType.Lancer:
             return new Lancer();
         case ClassJobType.Marauder:
             return new Marauder();
         case ClassJobType.Pugilist:
             return new Pugilist();
         case ClassJobType.Rogue:
             return new Rogue();
         case ClassJobType.Thaumaturge:
             return new Thaumaturge();
         #endregion
         #region Job
         case ClassJobType.Astrologian:
             return new Astrologian();
         case ClassJobType.Bard:
             return new Bard();
         case ClassJobType.BlackMage:
             return new BlackMage();
         case ClassJobType.DarkKnight:
             return new DarkKnight();
         case ClassJobType.Dragoon:
             return new Dragoon();
         case ClassJobType.Machinist:
             return new Machinist();
         case ClassJobType.Monk:
             return new Monk();
         case ClassJobType.Ninja:
             return new Ninja();
         case ClassJobType.Paladin:
             return new Paladin();
         case ClassJobType.Scholar:
             return new Scholar();
         case ClassJobType.Summoner:
             return new Summoner();
         case ClassJobType.Warrior:
             return new Warrior();
         case ClassJobType.WhiteMage:
             return new WhiteMage();
         #endregion
         #endregion
         #region Crafting
         case ClassJobType.Alchemist:
             return new HandLand();
         case ClassJobType.Armorer:
             return new HandLand();
         case ClassJobType.Blacksmith:
             return new HandLand();
         case ClassJobType.Carpenter:
             return new HandLand();
         case ClassJobType.Culinarian:
             return new HandLand();
         case ClassJobType.Goldsmith:
             return new HandLand();
         case ClassJobType.Leatherworker:
             return new HandLand();
         case ClassJobType.Weaver:
             return new HandLand();
         #endregion
         #region Gathering
         case ClassJobType.Botanist:
             return new HandLand();
         case ClassJobType.Fisher:
             return new HandLand();
         case ClassJobType.Miner:
             return new HandLand();
         #endregion
         default:
             throw new NotImplementedException();
     }
 }
示例#13
0
 public Job(ClassJobType job, List<Recipe> recipelist)
 {
     ClassJob = job;
     Recipes = recipelist;
 }
示例#14
0
文件: Mend.cs 项目: Rawrskyes/crafty
 public ClassMends(ClassJobType j, uint mend1, uint mend2)
 {
     Job = j;
     Mend1 = mend1;
     Mend2 = mend2;
 }
示例#15
0
        /// <summary>
        /// Returns bool when the passed job is a valid crafting job.
        /// </summary>
        /// <param name="job">ClassJobType jobt</param>
        /// <returns>True if the passed job is a crafting job, False otherwise.</returns>
        internal bool IsValidCraftClass(ClassJobType job)
        {
            bool retBool;
            switch(job)
            {
                case ClassJobType.Alchemist:
                case ClassJobType.Armorer:
                case ClassJobType.Carpenter:
                case ClassJobType.Culinarian:
                case ClassJobType.Goldsmith:
                case ClassJobType.Leatherworker:
                case ClassJobType.Weaver:
                case ClassJobType.Blacksmith:
                    retBool = true;
                    break;
                default:
                    retBool = false;
                    break;
            }

            return retBool;
        }
示例#16
0
        /// <summary>
        /// Loads the requested class data.
        /// </summary>
        /// <param name="classType"></param>
        public void Load(ClassJobType classType)
        {
            classType.ToString();
            EngName = classType.ToString();
            Type = classType;

            // Switch between the type and load the proper list.
            switch (classType)
            {
                case ClassJobType.Carpenter:
                    Name = "刻木匠";
                    EngName = "Carpenter";
                    JpnName = "木工師";
                    Enum = 8;
                    Actions = (ActionList)CraftExportForm.ActionList["Carpenter"];
                    break;
                case ClassJobType.Blacksmith:
                    Name = "锻铁匠";
                    EngName = "Blacksmith";
                    JpnName = "鍛冶師";
                    Enum = 9;
                    Actions = (ActionList)CraftExportForm.ActionList["Blacksmith"];
                    break;
                case ClassJobType.Armorer:
                    Name = "铸甲匠";
                    EngName = "Armorer";
                    JpnName = "甲冑師";
                    Enum = 10;
                    Actions = (ActionList)CraftExportForm.ActionList["Armorer"];
                    break;
                case ClassJobType.Goldsmith:
                    Name = "雕金匠";
                    EngName = "Goldsmith";
                    JpnName = "彫金師";
                    Enum = 11;
                    Actions = (ActionList)CraftExportForm.ActionList["Goldsmith"];
                    break;
                case ClassJobType.Leatherworker:
                    Name = "制革匠";
                    EngName = "Leatherworker";
                    JpnName = "革細工師";
                    Enum = 12;
                    Actions = (ActionList)CraftExportForm.ActionList["Leatherworker"];
                    break;
                case ClassJobType.Weaver:
                    Name = "裁衣匠";
                    EngName = "Weaver";
                    JpnName = "裁縫師";
                    Enum = 13;
                    Actions = (ActionList)CraftExportForm.ActionList["Weaver"];
                    break;
                case ClassJobType.Alchemist:
                    Name = "炼金术士";
                    EngName = "Alchemist";
                    JpnName = "錬金術師";
                    Enum = 14;
                    Actions = (ActionList)CraftExportForm.ActionList["Alchemist"];
                    break;
                case ClassJobType.Culinarian:
                    Name = "烹调师";
                    EngName = "Culinarian";
                    JpnName = "調理師";
                    Enum = 15;
                    Actions = (ActionList)CraftExportForm.ActionList["Culinarian"];
                    break;
            }
        }
示例#17
0
        /// <summary>
        ///     Populates the ClassImageList based on the passed Class Type.
        /// </summary>
        /// <param name="resourceSet"></param>
        /// <param name="classType"></param>
        private void LoadImageList(ResourceSet resourceSet, ClassJobType classType)
        {
            // Clear the current entries.
            ClassSkillImages.Clear();
            // Switch based on the class type.
            switch (classType)
            {
                case ClassJobType.Carpenter:
                    ClassSkillImages.Add("crp_BasicSynthesis", (Bitmap) resourceSet.GetObject("crp_BasicSynthesis"));
                    ClassSkillImages.Add("crp_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("crp_StandardSynthesis"));
                    ClassSkillImages.Add("crp_BasicTouch", (Bitmap) resourceSet.GetObject("crp_BasicTouch"));
                    ClassSkillImages.Add("crp_StandardTouch", (Bitmap) resourceSet.GetObject("crp_StandardTouch"));
                    ClassSkillImages.Add("crp_AdvancedTouch", (Bitmap) resourceSet.GetObject("crp_AdvancedTouch"));
                    ClassSkillImages.Add("crp_PreciseTouch", (Bitmap) resourceSet.GetObject("crp_PreciseTouch"));
                    break;
                case ClassJobType.Blacksmith:
                    ClassSkillImages.Add("bsm_BasicSynthesis", (Bitmap) resourceSet.GetObject("bsm_BasicSynthesis"));
                    ClassSkillImages.Add("bsm_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("bsm_StandardSynthesis"));
                    ClassSkillImages.Add("bsm_BasicTouch", (Bitmap) resourceSet.GetObject("bsm_BasicTouch"));
                    ClassSkillImages.Add("bsm_StandardTouch", (Bitmap) resourceSet.GetObject("bsm_StandardTouch"));
                    ClassSkillImages.Add("bsm_AdvancedTouch", (Bitmap) resourceSet.GetObject("bsm_AdvancedTouch"));
                    ClassSkillImages.Add("bsm_PreciseTouch", (Bitmap) resourceSet.GetObject("bsm_PreciseTouch"));
                    break;
                case ClassJobType.Armorer:
                    ClassSkillImages.Add("arm_BasicSynthesis", (Bitmap) resourceSet.GetObject("arm_BasicSynthesis"));
                    ClassSkillImages.Add("arm_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("arm_StandardSynthesis"));
                    ClassSkillImages.Add("arm_BasicTouch", (Bitmap) resourceSet.GetObject("arm_BasicTouch"));
                    ClassSkillImages.Add("arm_StandardTouch", (Bitmap) resourceSet.GetObject("arm_StandardTouch"));
                    ClassSkillImages.Add("arm_AdvancedTouch", (Bitmap) resourceSet.GetObject("arm_AdvancedTouch"));
                    ClassSkillImages.Add("arm_PreciseTouch", (Bitmap) resourceSet.GetObject("arm_PreciseTouch"));
                    break;

                case ClassJobType.Goldsmith:
                    ClassSkillImages.Add("gsm_BasicSynthesis", (Bitmap) resourceSet.GetObject("gsm_BasicSynthesis"));
                    ClassSkillImages.Add("gsm_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("gsm_StandardSynthesis"));
                    ClassSkillImages.Add("gsm_BasicTouch", (Bitmap) resourceSet.GetObject("gsm_BasicTouch"));
                    ClassSkillImages.Add("gsm_StandardTouch", (Bitmap) resourceSet.GetObject("gsm_StandardTouch"));
                    ClassSkillImages.Add("gsm_AdvancedTouch", (Bitmap) resourceSet.GetObject("gsm_AdvancedTouch"));
                    ClassSkillImages.Add("gsm_PreciseTouch", (Bitmap) resourceSet.GetObject("gsm_PreciseTouch"));
                    break;
                case ClassJobType.Leatherworker:
                    ClassSkillImages.Add("ltw_BasicSynthesis", (Bitmap) resourceSet.GetObject("ltw_BasicSynthesis"));
                    ClassSkillImages.Add("ltw_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("ltw_StandardSynthesis"));
                    ClassSkillImages.Add("ltw_BasicTouch", (Bitmap) resourceSet.GetObject("ltw_BasicTouch"));
                    ClassSkillImages.Add("ltw_StandardTouch", (Bitmap) resourceSet.GetObject("ltw_StandardTouch"));
                    ClassSkillImages.Add("ltw_AdvancedTouch", (Bitmap) resourceSet.GetObject("ltw_AdvancedTouch"));
                    ClassSkillImages.Add("ltw_PreciseTouch", (Bitmap) resourceSet.GetObject("ltw_PreciseTouch"));
                    break;
                case ClassJobType.Weaver:
                    ClassSkillImages.Add("wvr_BasicSynthesis", (Bitmap) resourceSet.GetObject("wvr_BasicSynthesis"));
                    ClassSkillImages.Add("wvr_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("wvr_StandardSynthesis"));
                    ClassSkillImages.Add("wvr_BasicTouch", (Bitmap) resourceSet.GetObject("wvr_BasicTouch"));
                    ClassSkillImages.Add("wvr_StandardTouch", (Bitmap) resourceSet.GetObject("wvr_StandardTouch"));
                    ClassSkillImages.Add("wvr_AdvancedTouch", (Bitmap) resourceSet.GetObject("wvr_AdvancedTouch"));
                    ClassSkillImages.Add("wvr_PreciseTouch", (Bitmap) resourceSet.GetObject("wvr_PreciseTouch"));
                    break;
                case ClassJobType.Alchemist:
                    ClassSkillImages.Add("alc_BasicSynthesis", (Bitmap) resourceSet.GetObject("alc_BasicSynthesis"));
                    ClassSkillImages.Add("alc_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("alc_StandardSynthesis"));
                    ClassSkillImages.Add("alc_BasicTouch", (Bitmap) resourceSet.GetObject("alc_BasicTouch"));
                    ClassSkillImages.Add("alc_StandardTouch", (Bitmap) resourceSet.GetObject("alc_StandardTouch"));
                    ClassSkillImages.Add("alc_AdvancedTouch", (Bitmap) resourceSet.GetObject("alc_AdvancedTouch"));
                    ClassSkillImages.Add("alc_PreciseTouch", (Bitmap) resourceSet.GetObject("alc_PreciseTouch"));
                    break;
                case ClassJobType.Culinarian:
                    ClassSkillImages.Add("cul_BasicSynthesis", (Bitmap) resourceSet.GetObject("cul_BasicSynthesis"));
                    ClassSkillImages.Add("cul_StandardSynthesis",
                        (Bitmap) resourceSet.GetObject("cul_StandardSynthesis"));
                    ClassSkillImages.Add("cul_BasicTouch", (Bitmap) resourceSet.GetObject("cul_BasicTouch"));
                    ClassSkillImages.Add("cul_StandardTouch", (Bitmap) resourceSet.GetObject("cul_StandardTouch"));
                    ClassSkillImages.Add("cul_AdvancedTouch", (Bitmap) resourceSet.GetObject("cul_AdvancedTouch"));
                    ClassSkillImages.Add("cul_PreciseTouch", (Bitmap) resourceSet.GetObject("cul_PreciseTouch"));
                    break;
            }
        }
 public static void SelectClass(ClassJobType classJobType)
 {
     SelectClass(GetClassIndex(classJobType));
 }
示例#19
0
        /// <summary>
        /// Returns the current Job's recipes collection filename.
        /// This is used by the GetRecipes method to get a valid source file for importing.
        /// </summary>
        /// <param name="currentJob"></param>
        /// <returns>string on success, Null on failure.</returns>
        private string GetRecipePath(ClassJobType currentJob)
        {
            // Define valid jobs and the according recipes source file path.
            Dictionary<ClassJobType, string> jobs = new Dictionary<ClassJobType, string>
            {
                {ClassJobType.Alchemist, "recipes_alchemist.txt"},
                {ClassJobType.Armorer, "recipes_armorer.txt"},
                {ClassJobType.Blacksmith, "recipes_blacksmith.txt"},
                {ClassJobType.Carpenter, "recipes_carpenter.txt"},
                {ClassJobType.Culinarian, "recipes_culinarian.txt"},
                {ClassJobType.Goldsmith, "recipes_goldsmith.txt"},
                {ClassJobType.Leatherworker, "recipes_leatherworker.txt"},
                {ClassJobType.Weaver, "recipes_weaver.txt"}
            };

            if(jobs.ContainsKey(currentJob))
            {
                return jobs[currentJob];
            }

            return null;
        }
示例#20
0
文件: Synth.cs 项目: Rawrskyes/crafty
 public ClassSynths(ClassJobType job, uint synth1, uint synth2)
 {
     Job = job;
     Synth1 = synth1;
     Synth2 = synth2;
 }
示例#21
0
using System;
using ff14bot.Enums;
using YourRaidingBuddy;

namespace YourRaidingBuddy
{
    [AttributeUsage(AttributeTargets.Method, Inherited = false, AllowMultiple = true)]
    internal sealed class IgnoreBehaviorCountAttribute : Attribute
    {
        public IgnoreBehaviorCountAttribute(BehaviorType type)
        {
            Type = type;
        }

        public BehaviorType Type { get; private set; }
    }

    [AttributeUsage(AttributeTargets.Method, Inherited = false, AllowMultiple = true)]
    internal sealed class BehaviorAttribute : Attribute
    {
        public BehaviorAttribute(BehaviorType type, ClassJobType job = ClassJobType.Adventurer, GameContext context = GameContext.All, int priority = 0)
        {
            Type = type;
            Job = job;
            SpecificContext = context;
            PriorityLevel = priority;
        }

        public BehaviorType Type { get; private set; }
        public ClassJobType Job { get; set; }
        public GameContext SpecificContext { get; private set; }
        public int PriorityLevel { get; private set; }
    }
}
示例#22
0
 /// <summary>
 /// Returns a list of recipes based on the specified class.
 /// Returns an empty list if specified class does not exist.
 /// </summary>
 /// <param name="classtype"></param>
 /// <returns></returns>
 public List<Recipe> LoadRecipes(ClassJobType classtype)
 {
     switch (classtype)
     {
         case ClassJobType.Carpenter:
             return CarpenterRecipes;
         case ClassJobType.Blacksmith:
             return BlacksmithRecipes;
         case ClassJobType.Armorer:
             return ArmorerRecipes;
         case ClassJobType.Goldsmith:
             return GoldsmithRecipes;
         case ClassJobType.Leatherworker:
             return LeatherworkerRecipes;
         case ClassJobType.Weaver:
             return WeaverRecipes;
         case ClassJobType.Alchemist:
             return AlchemistRecipes;
         case ClassJobType.Culinarian:
             return CulinarianRecipes;
         default:
             return new List<Recipe>();
     }
 }
示例#23
0
 public Order(uint itemid, string itemname, uint qty, ClassJobType job)
 {
     ItemId = itemid;
     Qty = qty;
     Job = job;
     ItemName = itemname;
 }
示例#24
0
        private void ChangeClass(ClassJobType classType)
        {
            // Get the current Active Class button.
            var activeClass = CraftClassGroup.Controls.Find(_currentCraftClass.Type.ToString(), true).FirstOrDefault();

            // If it exists, reset the color.
            if (activeClass != null)
                activeClass.BackColor = DefaultBackColor;

            _currentCraftClass.Load(classType);

            // Set the active class based on the newly loaded class.
            activeClass = CraftClassGroup.Controls.Find(_currentCraftClass.Type.ToString(), true).FirstOrDefault();

            // If it exists, adjust the color.
            if (activeClass != null)
                activeClass.BackColor = SystemColors.ActiveCaption;

            // Set the base skills for the current craft class.
            SetBaseSkills();

            // Empty the existing action sequence.
            EmptyActions();

            // Load the recipes.
            LoadRecipes();

            LoadLeves();
        }
示例#25
0
 /// <summary>
 ///     Resource ibrary overloaded constructor that accepts a classtype.
 ///     Calls the LoadImageList with the resource set and passed classtype.
 /// </summary>
 /// <param name="resourceLocation"></param>
 /// <param name="classType"></param>
 public ResourceLibrary(string resourceLocation, ClassJobType classType)
 {
     // Create a resource set from our assembly based on the resource location.
     var projectName = Assembly.GetExecutingAssembly().GetName().Name;
     var resourceSet =
         new ResourceSet(
             Assembly.GetExecutingAssembly()
                 .GetManifestResourceStream(projectName + ".Properties.Resources.resources"));
     // Populate the ClassImageList by ClassType.
     LoadImageList(resourceSet, classType);
 }
示例#26
0
 private void jobclasscombo_TextChanged(object sender, EventArgs e)
 {
     _job = getClassJobType(jobclasscombo.SelectedItem.ToString());
 }
 public static uint GetClassIndex(ClassJobType classJobType)
 {
     return (uint)classJobType - 8;
 }
示例#28
0
        public static int HighestILvl(ClassJobType job)
        {
            IEnumerable <GearSet> sets = GearsetManager.GearSets.Where(g => g.InUse && g.Class == job && g.Gear.Any());

            return(sets.Any() ? sets.Max(GeneralFunctions.GetGearSetiLvl) : 0);
        }
        /// <summary>
        /// Change the current crafting class based on the passed class parameter.
        /// </summary>
        /// <param name="classType"></param>
        private void ChangeClass(ClassJobType classType)
        {
            // Get the current Active Class button.
            var activeClass = CraftClassGroup.Controls.Find(_currentCraftClass.Type.ToString(), true).FirstOrDefault();

            // If it exists, reset the color.
            if (activeClass != null)
                activeClass.BackColor = DefaultBackColor;

            // Check if the passed class is a craft class and load it, otherwise defaulto to Carpenter
            _currentCraftClass.Load(Utilities.IsCraftingClass(classType) ? classType : ClassJobType.Carpenter);
    
            // Set the active class based on the newly loaded class.
            activeClass = CraftClassGroup.Controls.Find(_currentCraftClass.Type.ToString(), true).FirstOrDefault();

            // If it exists, adjust the color.
            if (activeClass != null)
                activeClass.BackColor = SystemColors.ActiveCaption;

            // Set the base skills for the current craft class.
            SetBaseSkills();

            // Empty the existing action sequence.
            EmptyActions();

            // Load the recipes.
            LoadRecipes();
        }