コード例 #1
0
ファイル: InteractAction.cs プロジェクト: Asphodan/Alphabuddy
        public InteractionAction()
        {
            Properties["Entry"] = new MetaProp("Entry", typeof (uint),
                                               new EditorAttribute(typeof (PropertyBag.EntryEditor),
                                                                   typeof (UITypeEditor)),
                                               new DisplayNameAttribute(Pb.Strings["Action_Common_Entry"]));

            Properties["InteractDelay"] = new MetaProp("InteractDelay", typeof (uint),
                                                       new DisplayNameAttribute(
                                                           Pb.Strings["Action_InteractAction_InteractDelay"]));

            Properties["InteractType"] = new MetaProp("InteractType", typeof (InteractActionType),
                                                      new DisplayNameAttribute(
                                                          Pb.Strings["Action_InteractAction_InteractType"]));

            Properties["GameObjectType"] = new MetaProp("GameObjectType", typeof (WoWGameObjectType),
                                                        new DisplayNameAttribute(
                                                            Pb.Strings["Action_InteractAction_GameobjectType"]));

            Properties["SpellFocus"] = new MetaProp("SpellFocus", typeof (WoWSpellFocus),
                                                    new DisplayNameAttribute(
                                                        Pb.Strings["Action_InteractAction_SpellFocus"]));

            InteractDelay = Entry = 0u;
            InteractType = InteractActionType.GameObject;
            GameObjectType = WoWGameObjectType.Mailbox;
            SpellFocus = WoWSpellFocus.Anvil;

            Properties["SpellFocus"].Show = false;
            Properties["InteractType"].PropertyChanged += InteractionActionPropertyChanged;
            Properties["GameObjectType"].PropertyChanged += InteractionActionPropertyChanged;
        }
コード例 #2
0
ファイル: Settings.cs プロジェクト: Asphodan/Alphabuddy
        public Settings()
        {
            Properties["DefaultValue"] = new MetaProp("DefaultValue", typeof (string),
                                                      new DisplayNameAttribute(Pb.Strings["Action_Common_DefaultValue"]));

            Properties["Type"] = new MetaProp("Type", typeof (TypeCode),
                                              new DisplayNameAttribute(Pb.Strings["Action_Common_Type"]));

            Properties["Name"] = new MetaProp("Name", typeof (string),
                                              new DisplayNameAttribute(Pb.Strings["Action_Common_Name"]));

            Properties["Summary"] = new MetaProp("Summary", typeof (string),
                                                 new DisplayNameAttribute(Pb.Strings["Action_Common_Summary"]));

            Properties["Category"] = new MetaProp("Category", typeof (string),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_Category"]));

            Properties["Global"] = new MetaProp("Global", typeof (bool),
                                                new DisplayNameAttribute(Pb.Strings["Action_Common_Global"]));

            Properties["Hidden"] = new MetaProp("Hidden", typeof (bool),
                                                new DisplayNameAttribute(Pb.Strings["Action_Common_Hidden"]));

            DefaultValue = "true";
            Type = TypeCode.Boolean;
            SettingName = Pb.Strings["Action_Common_SettingName"];
            Summary = Pb.Strings["Action_Common_SummaryExample"];
            Category = "Misc";
            Global = false;
            Hidden = false;
        }
コード例 #3
0
        public GetItemfromBankAction()
        {
            Properties["Amount"] = new MetaProp("Amount", typeof(DynamicProperty <int>),
                                                new TypeConverterAttribute(typeof(DynamicProperty <int> .DynamivExpressionConverter)));
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));

            Properties["MinFreeBagSlots"]     = new MetaProp("MinFreeBagSlots", typeof(uint), new DisplayNameAttribute("Min Free Bagslots"));
            Properties["GetItemfromBankType"] = new MetaProp("GetItemfromBankType", typeof(BankWithdrawlItemType), new DisplayNameAttribute("Items to Withdraw"));
            Properties["Bank"]               = new MetaProp("Bank", typeof(BankType));
            Properties["AutoFindBank"]       = new MetaProp("AutoFindBank", typeof(bool), new DisplayNameAttribute("Auto find Bank"));
            Properties["Location"]           = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["NpcEntry"]           = new MetaProp("NpcEntry", typeof(uint), new EditorAttribute(typeof(PropertyBag.EntryEditor), typeof(UITypeEditor)));
            Properties["WithdrawAdditively"] = new MetaProp("WithdrawAdditively", typeof(bool), new DisplayNameAttribute("Withdraw Additively"));

            Amount = new DynamicProperty <int>(this, "1");
            RegisterDynamicProperty("Amount");
            ItemID              = "";
            MinFreeBagSlots     = 2u;
            GetItemfromBankType = BankWithdrawlItemType.SpecificItem;
            Bank               = BankType.Personal;
            AutoFindBank       = true;
            _loc               = WoWPoint.Zero;
            Location           = _loc.ToInvariantString();
            NpcEntry           = 0u;
            WithdrawAdditively = true;

            Properties["Location"].Show = false;
            Properties["NpcEntry"].Show = false;
            Properties["AutoFindBank"].PropertyChanged        += AutoFindBankChanged;
            Properties["GetItemfromBankType"].PropertyChanged += GetItemfromBankActionPropertyChanged;
            Properties["Location"].PropertyChanged            += LocationChanged;
        }
コード例 #4
0
 public Declaration()
     : base(CsharpCodeType.Declaration)
 {
     Properties["Code"] = new MetaProp("Code", typeof(string), new EditorAttribute(typeof(MultilineStringEditor), typeof(UITypeEditor)));
     Code = "";
     Properties["Code"].PropertyChanged += Code_PropertyChanged;
 }
コード例 #5
0
        public If()
        {
            // ReSharper disable DoNotCallOverridableMethodsInConstructor
            Properties = new PropertyBag();
            Properties["IgnoreCanRun"] = new MetaProp("IgnoreCanRun", typeof(bool),
                                                      new DisplayNameAttribute(
                                                          Professionbuddy.Instance.Strings["FlowControl_If_IgnoreCanRun"
                                                          ]));

            Properties["Condition"] = new MetaProp("Condition",
                                                   typeof(string),
                                                   new EditorAttribute(typeof(MultilineStringEditor),
                                                                       typeof(UITypeEditor)),
                                                   new DisplayNameAttribute(
                                                       Professionbuddy.Instance.Strings["FlowControl_If_Condition"]));

            Properties["CompileError"] = new MetaProp("CompileError", typeof(string), new ReadOnlyAttribute(true),
                                                      new DisplayNameAttribute(
                                                          Professionbuddy.Instance.Strings[
                                                              "Action_CSharpAction_CompileError"]));

            CanRunDelegate = c => false;
            Condition      = "";
            CompileError   = "";
            Properties["CompileError"].Show = false;

            Properties["Condition"].PropertyChanged    += Condition_PropertyChanged;
            Properties["CompileError"].PropertyChanged += CompileErrorPropertyChanged;
            IgnoreCanRun = true;
            // ReSharper restore DoNotCallOverridableMethodsInConstructor
        }
コード例 #6
0
        public BuyItemFromAhAction()
        {
            Properties["ItemID"]    = new MetaProp("ItemID", typeof(string));
            Properties["MaxBuyout"] = new MetaProp("MaxBuyout", typeof(PropertyBag.GoldEditor),
                                                   new DisplayNameAttribute("Max Buyout"), new TypeConverterAttribute(typeof(PropertyBag.GoldEditorConverter)));
            Properties["Amount"] = new MetaProp("Amount", typeof(DynamicProperty <int>),
                                                new TypeConverterAttribute(typeof(DynamicProperty <int> .DynamivExpressionConverter)));
            Properties["ItemListType"]  = new MetaProp("ItemListType", typeof(ItemType), new DisplayNameAttribute("Buy ..."));
            Properties["AutoFindAh"]    = new MetaProp("AutoFindAh", typeof(bool), new DisplayNameAttribute("Auto find AH"));
            Properties["BuyAdditively"] = new MetaProp("BuyAdditively", typeof(bool), new DisplayNameAttribute("Buy Additively"));

            Properties["BidOnItem"] = new MetaProp("BidOnItem", typeof(bool), new DisplayNameAttribute("Bid on Item"));
            Properties["Location"]  = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));

            ItemID = "";
            Amount = new DynamicProperty <int>(this, "1");
            RegisterDynamicProperty("Amount");
            ItemListType  = ItemType.Item;
            AutoFindAh    = true;
            _loc          = WoWPoint.Zero;
            Location      = _loc.ToInvariantString();
            MaxBuyout     = new PropertyBag.GoldEditor("100g0s0c");
            BidOnItem     = false;
            BuyAdditively = true;

            Properties["AutoFindAh"].PropertyChanged   += AutoFindAHChanged;
            Properties["ItemListType"].PropertyChanged += BuyItemFromAhActionPropertyChanged;
            Properties["Location"].PropertyChanged     += LocationChanged;
            Properties["Amount"].Show   = true;
            Properties["Location"].Show = false;
        }
コード例 #7
0
 public CustomAction():base(CsharpCodeType.Statements)
 {
     this.Action = c => { ;};
     Properties["Code"] = new MetaProp("Code", typeof(string));
     Code = "";
     Properties["Code"].PropertyChanged += new EventHandler(CustomAction_PropertyChanged);
 }
コード例 #8
0
ファイル: MoveToAction.cs プロジェクト: Asphodan/Alphabuddy
        public MoveToAction()
        {
            Properties["Entry"] = new MetaProp("Entry", typeof (uint),
                                               new EditorAttribute(typeof (PropertyBag.EntryEditor),
                                                                   typeof (UITypeEditor)),
                                               new DisplayNameAttribute(Pb.Strings["Action_Common_Entry"]));

            Properties["Location"] = new MetaProp("Location",
                                                  typeof (string),
                                                  new EditorAttribute(typeof (PropertyBag.LocationEditor),
                                                                      typeof (UITypeEditor)),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_Location"]));

            Properties["MoveType"] = new MetaProp("MoveType", typeof (MoveToType),
                                                  new DisplayNameAttribute(Pb.Strings["Action_MoveToAction_MoveToType"]));

            Properties["Pathing"] = new MetaProp("Pathing", typeof (NavigationType),
                                                 new DisplayNameAttribute(Pb.Strings["Action_Common_Use"]));

            Entry = 0u;
            _loc = WoWPoint.Zero;
            Location = _loc.ToInvariantString();
            MoveType = MoveToType.Location;
            Pathing = NavigationType.Navigator;

            Properties["Entry"].Show = false;
            Properties["MoveType"].PropertyChanged += MoveToActionPropertyChanged;
            Properties["Location"].PropertyChanged += LocationChanged;
        }
コード例 #9
0
        public GetItemfromBankAction()
        {
            Properties["Amount"] = new MetaProp("Amount", typeof(int));
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));

            Properties["MinFreeBagSlots"] = new MetaProp("MinFreeBagSlots", typeof(uint), new DisplayNameAttribute("Min Free Bagslots"));
            Properties["GetItemfromBankType"] = new MetaProp("GetItemfromBankType", typeof(BankWithdrawlItemType), new DisplayNameAttribute("Items to Withdraw"));
            Properties["Bank"] = new MetaProp("Bank", typeof(BankType));
            Properties["AutoFindBank"] = new MetaProp("AutoFindBank", typeof(bool), new DisplayNameAttribute("Auto find Bank"));
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["NpcEntry"] = new MetaProp("NpcEntry", typeof(uint), new EditorAttribute(typeof(PropertyBag.EntryEditor), typeof(UITypeEditor)));
            Properties["WithdrawAdditively"] = new MetaProp("WithdrawAdditively", typeof(bool), new DisplayNameAttribute("Withdraw Additively"));

            Amount = 1;
            ItemID = "";
            MinFreeBagSlots = 2u;
            GetItemfromBankType = BankWithdrawlItemType.SpecificItem;
            Bank = BankType.Personal;
            AutoFindBank = true;
            loc = WoWPoint.Zero;
            Location = loc.ToInvariantString();
            NpcEntry = 0u;
            WithdrawAdditively = true; 

            Properties["Location"].Show = false;
            Properties["NpcEntry"].Show = false;
            Properties["AutoFindBank"].PropertyChanged += new EventHandler(AutoFindBankChanged);
            Properties["GetItemfromBankType"].PropertyChanged += new EventHandler(GetItemfromBankAction_PropertyChanged);
            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
        }
コード例 #10
0
        public CastSpellAction()
        {
            SpamControl              = new Stopwatch();
            QueueIsRunning           = false;
            Properties["Casted"]     = new MetaProp("Casted", typeof(int), new ReadOnlyAttribute(true));
            Properties["SpellName"]  = new MetaProp("SpellName", typeof(string), new ReadOnlyAttribute(true));
            Properties["Repeat"]     = new MetaProp("Repeat", typeof(int));
            Properties["Entry"]      = new MetaProp("Entry", typeof(uint));
            Properties["CastOnItem"] = new MetaProp("CastOnItem", typeof(bool), new DisplayNameAttribute("Cast on Item"));
            Properties["ItemType"]   = new MetaProp("ItemType", typeof(InventoryType), new DisplayNameAttribute("Item Type"));
            Properties["ItemId"]     = new MetaProp("ItemId", typeof(uint));
            Properties["RepeatType"] = new MetaProp("RepeatType", typeof(RepeatCalculationType), new DisplayNameAttribute("Repeat Type"));
            // Properties["Recipe"] = new MetaProp("Recipe", typeof(Recipe), new TypeConverterAttribute(typeof(RecipeConverter)));

            Casted     = 0;
            Repeat     = 1;
            Entry      = 0u;
            RepeatType = RepeatCalculationType.Craftable;
            Recipe     = null;
            CastOnItem = false;
            ItemType   = InventoryType.Chest;
            ItemId     = 0u;
            Properties["SpellName"].Value = SpellName;

            //Properties["Recipe"].Show = false;
            Properties["ItemType"].Show           = false;
            Properties["ItemId"].Show             = false;
            Properties["Casted"].PropertyChanged += OnCounterChanged;
            CheckTradeskillList();
            Properties["RepeatType"].PropertyChanged += new EventHandler(CastSpellAction_PropertyChanged);
            Properties["Entry"].PropertyChanged      += new EventHandler(OnEntryChanged);
            Properties["CastOnItem"].PropertyChanged += CastOnItemChanged;
        }
コード例 #11
0
ファイル: CalSubRoutine.cs プロジェクト: ywjb/Honorbuddy-434
 public CallSubRoutine()
 {
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof(string),
                                                 new DisplayNameAttribute(
                                                     Pb.Strings["Action_CallSubRoutine_SubRoutineName"]));
     SubRoutineName = "";
 }
コード例 #12
0
        public BuyItemFromAhAction()
        {
            Properties["ItemID"]    = new MetaProp("ItemID", typeof(string));
            Properties["MaxBuyout"] = new MetaProp("MaxBuyout", typeof(PropertyBag.GoldEditor),
                                                   new DisplayNameAttribute("Max Buyout"), new TypeConverterAttribute(typeof(PropertyBag.GoldEditorConverter)));
            Properties["Amount"]        = new MetaProp("Amount", typeof(uint));
            Properties["ItemListType"]  = new MetaProp("ItemListType", typeof(ItemType), new DisplayNameAttribute("Buy ..."));
            Properties["AutoFindAh"]    = new MetaProp("AutoFindAh", typeof(bool), new DisplayNameAttribute("Auto find AH"));
            Properties["BuyAdditively"] = new MetaProp("BuyAdditively", typeof(bool), new DisplayNameAttribute("Buy Additively"));

            Properties["BidOnItem"] = new MetaProp("BidOnItem", typeof(bool), new DisplayNameAttribute("Bid on Item"));
            Properties["Location"]  = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));

            ItemID        = "";
            Amount        = 1u;
            ItemListType  = ItemType.Item;
            AutoFindAh    = true;
            loc           = WoWPoint.Zero;
            Location      = loc.ToInvariantString();
            MaxBuyout     = new PropertyBag.GoldEditor("100g0s0c");
            BidOnItem     = false;
            BuyAdditively = true;

            Properties["AutoFindAh"].PropertyChanged   += new EventHandler(AutoFindAHChanged);
            Properties["ItemListType"].PropertyChanged += new EventHandler(BuyItemFromAhAction_PropertyChanged);
            Properties["Location"].PropertyChanged     += new EventHandler(LocationChanged);
            Properties["Amount"].Show   = true;
            Properties["Location"].Show = false;
        }
コード例 #13
0
ファイル: CalSubRoutine.cs プロジェクト: Asphodan/Alphabuddy
 public CallSubRoutine()
 {
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof (string),
                                                 new DisplayNameAttribute(
                                                     Pb.Strings["Action_CallSubRoutine_SubRoutineName"]));
     SubRoutineName = "";
 }
コード例 #14
0
        public GetMailAction()
        {
            //CheckNewMail
            Properties["ItemID"] = new MetaProp(
                "ItemID",
                typeof(string),
                new DisplayNameAttribute(Strings["Action_Common_ItemEntries"]));

            Properties["MinFreeBagSlots"] = new MetaProp(
                "MinFreeBagSlots",
                typeof(int),
                new DisplayNameAttribute(
                    Strings["Action_Common_MinFreeBagSlots"]));

            Properties["CheckNewMail"] = new MetaProp(
                "CheckNewMail",
                typeof(bool),
                new DisplayNameAttribute(
                    Strings["Action_GetMailAction_CheckNewMail"]));

            Properties["GetMailType"] = new MetaProp(
                "GetMailType",
                typeof(GetMailActionType),
                new DisplayNameAttribute(Strings["Action_GetMailAction_Name"]));

            Properties["AutoFindMailBox"] = new MetaProp(
                "AutoFindMailBox",
                typeof(bool),
                new DisplayNameAttribute(
                    Strings["Action_Common_AutoFindMailbox"]));

            Properties["Location"] = new MetaProp(
                "Location",
                typeof(string),
                new EditorAttribute(
                    typeof(LocationEditor),
                    typeof(UITypeEditor)),
                new DisplayNameAttribute(Strings["Action_Common_Location"]));

            Properties["MaxCODAmount"] = new MetaProp(
                "MaxCODAmount",
                typeof(GoldEditor),
                new TypeConverterAttribute(typeof(GoldEditorConverter)),
                new DisplayNameAttribute(Strings["Action_Common_MaxCODPrice"]));

            ItemID          = "";
            CheckNewMail    = true;
            MaxCODAmount    = new GoldEditor("0g0s0c");
            GetMailType     = GetMailActionType.AllItems;
            AutoFindMailBox = true;
            _loc            = WoWPoint.Zero;
            Location        = _loc.ToInvariantString();
            MinFreeBagSlots = 0;

            Properties["GetMailType"].PropertyChanged     += GetMailActionPropertyChanged;
            Properties["AutoFindMailBox"].PropertyChanged += AutoFindMailBoxChanged;
            Properties["ItemID"].Show               = false;
            Properties["Location"].Show             = false;
            Properties["Location"].PropertyChanged += LocationChanged;
        }
コード例 #15
0
        public BuyItemAction()
        {
            Properties["Location"] = new MetaProp("Location", typeof(string),
                                                  new EditorAttribute(typeof(PropertyBag.LocationEditor),
                                                                      typeof(UITypeEditor)));
            Properties["NpcEntry"] = new MetaProp("NpcEntry", typeof(uint),
                                                  new EditorAttribute(typeof(PropertyBag.EntryEditor),
                                                                      typeof(UITypeEditor)));
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));
            Properties["Count"]  = new MetaProp("Count", typeof(DynamicProperty <int>),
                                                new TypeConverterAttribute(typeof(DynamicProperty <int> .DynamivExpressionConverter)));
            Properties["BuyItemType"] = new MetaProp("BuyItemType", typeof(BuyItemActionType),
                                                     new DisplayNameAttribute("Buy"));
            Properties["BuyAdditively"] = new MetaProp("BuyAdditively", typeof(bool),
                                                       new DisplayNameAttribute("Buy Additively"));
            ItemID = "";
            Count  = new DynamicProperty <int>(this, "0"); // dynamic expression
            RegisterDynamicProperty("Count");
            BuyItemType   = BuyItemActionType.Material;
            _loc          = WoWPoint.Zero;
            Location      = _loc.ToInvariantString();
            NpcEntry      = 0u;
            BuyAdditively = true;

            Properties["ItemID"].Show                  = false;
            Properties["Count"].Show                   = false;
            Properties["BuyAdditively"].Show           = false;
            Properties["Location"].PropertyChanged    += LocationChanged;
            Properties["BuyItemType"].PropertyChanged += BuyItemActionPropertyChanged;
        }
コード例 #16
0
 public CustomAction() : base(CsharpCodeType.Statements)
 {
     this.Action        = c => {; };
     Properties["Code"] = new MetaProp("Code", typeof(string));
     Code = "";
     Properties["Code"].PropertyChanged += new EventHandler(CustomAction_PropertyChanged);
 }
コード例 #17
0
        public CastSpellAction()
        {
            _spamControl = new Stopwatch();
            QueueIsRunning = false;
            Properties["Casted"] = new MetaProp("Casted", typeof(int), new ReadOnlyAttribute(true));
            Properties["SpellName"] = new MetaProp("SpellName", typeof(string), new ReadOnlyAttribute(true));
            Properties["Repeat"] = new MetaProp("Repeat", typeof(DynamicProperty<int>),
                new TypeConverterAttribute(typeof(DynamicProperty<int>.DynamivExpressionConverter)));
            Properties["Entry"] = new MetaProp("Entry", typeof(uint));
            Properties["CastOnItem"] = new MetaProp("CastOnItem", typeof(bool), new DisplayNameAttribute("Cast on Item"));
            Properties["ItemType"] = new MetaProp("ItemType", typeof(InventoryType), new DisplayNameAttribute("Item Type"));
            Properties["ItemId"] = new MetaProp("ItemId", typeof(uint));
            Properties["RepeatType"] = new MetaProp("RepeatType", typeof(RepeatCalculationType), new DisplayNameAttribute("Repeat Type"));
            // Properties["Recipe"] = new MetaProp("Recipe", typeof(Recipe), new TypeConverterAttribute(typeof(RecipeConverter)));

            Casted = 0;
            Repeat = new DynamicProperty<int>(this,"1");
            RegisterDynamicProperty("Repeat");
            Entry = 0u;
            RepeatType = RepeatCalculationType.Craftable;
            Recipe = null;
            CastOnItem = false;
            ItemType = InventoryType.Chest;
            ItemId = 0u;
            Properties["SpellName"].Value = SpellName;

            //Properties["Recipe"].Show = false;
            Properties["ItemType"].Show = false;
            Properties["ItemId"].Show = false;
            Properties["Casted"].PropertyChanged += OnCounterChanged;
            CheckTradeskillList();
            Properties["RepeatType"].PropertyChanged += CastSpellActionPropertyChanged;
            Properties["Entry"].PropertyChanged += OnEntryChanged;
            Properties["CastOnItem"].PropertyChanged += CastOnItemChanged;
        }
コード例 #18
0
 public SubRoutine()
     : base()
 {
     Properties = new PropertyBag();
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof(string));
     SubRoutineName = "";
 }
コード例 #19
0
 public LoadProfileAction()
 {
     Properties["Path"] = new MetaProp("Path", typeof(string), new EditorAttribute(typeof(PropertyBag.FileLocationEditor), typeof(UITypeEditor)));
     Properties["ProfileType"] = new MetaProp("ProfileType", typeof(LoadProfileType));
     Path = "";
     ProfileType = LoadProfileType.Honorbuddy;
 }
コード例 #20
0
 public Declaration()
     : base(CsharpCodeType.Declaration)
 {
     Properties["Code"] = new MetaProp("Code", typeof(string), new EditorAttribute(typeof(MultilineStringEditor), typeof(UITypeEditor)));
     Code = "";
     Properties["Code"].PropertyChanged += Code_PropertyChanged;
 }
コード例 #21
0
        public DisenchantAction()
        {
            Properties["ActionType"] = new MetaProp(
                "ActionType",
                typeof(DeActionType),
                new DisplayNameAttribute(Strings["Action_Common_ActionType"]));

            Properties["ItemTarget"] = new MetaProp(
                "ItemTarget",
                typeof(ItemTargetType),
                new DisplayNameAttribute(Strings["Action_Common_ItemTarget"]));

            Properties["ItemQuality"] = new MetaProp(
                "ItemQuality",
                typeof(DeItemQualites),
                new DisplayNameAttribute(Strings["Action_Common_ItemQuality"]));

            Properties["ItemId"] = new MetaProp(
                "ItemId",
                typeof(int),
                new DisplayNameAttribute(Strings["Action_Common_ItemEntry"]));

            ActionType  = DeActionType.Disenchant;
            ItemTarget  = ItemTargetType.All;
            ItemQuality = DeItemQualites.Uncommon;
            ItemId      = 0;
            Properties["ItemId"].Show = false;
            Properties["ActionType"].PropertyChanged += ActionTypeChanged;
            Properties["ItemTarget"].PropertyChanged += ItemTargetChanged;
        }
コード例 #22
0
        public CancelAuctionAction()
        {
            Properties["ItemID"]      = new MetaProp("ItemID", typeof(string), new DisplayNameAttribute("Item ID List"));
            Properties["AutoFindAh"]  = new MetaProp("AutoFindAh", typeof(bool), new DisplayNameAttribute("Auto find AH"));
            Properties["Location"]    = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["UseCategory"] = new MetaProp("UseCategory", typeof(bool), new DisplayNameAttribute("Use Category"));
            Properties["Category"]    = new MetaProp("Category", typeof(WoWItemClass), new DisplayNameAttribute("Item Category"));
            Properties["SubCategory"] = new MetaProp("SubCategory", typeof(WoWItemTradeGoodsClass), new DisplayNameAttribute("Item SubCategory"));
            Properties["MinBuyout"]   = new MetaProp("MinBuyout", typeof(PropertyBag.GoldEditor),
                                                     new DisplayNameAttribute("Min Buyout"), new TypeConverterAttribute(typeof(PropertyBag.GoldEditorConverter)));

            ItemID      = "0";
            AutoFindAh  = true;
            _loc        = WoWPoint.Zero;
            Location    = _loc.ToInvariantString();
            UseCategory = false;
            Category    = WoWItemClass.TradeGoods;
            SubCategory = WoWItemTradeGoodsClass.None;
            MinBuyout   = new PropertyBag.GoldEditor("0g0s0c");

            Properties["AutoFindAh"].PropertyChanged  += AutoFindAHChanged;
            Properties["Location"].PropertyChanged    += LocationChanged;
            Properties["UseCategory"].PropertyChanged += UseCategoryChanged;
            Properties["Category"].PropertyChanged    += CategoryChanged;

            Properties["Category"].Show    = false;
            Properties["SubCategory"].Show = false;
            Properties["Location"].Show    = false;
        }
コード例 #23
0
        public EnableProfileAction()
        {
            Properties["Path"] = new MetaProp(
                "Path",
                typeof(string),
                new EditorAttribute(
                    typeof(FileLocationEditor),
                    typeof(UITypeEditor)),
                // ReSharper disable once LocalizableElement
                new DisplayNameAttribute("Path"));

            Properties["ProfileType"] = new MetaProp(
                "ProfileType",
                typeof(LoadProfileType),
                // ReSharper disable once LocalizableElement
                new DisplayNameAttribute("Profile Type"));

            Properties["IsLocal"] = new MetaProp(
                "IsLocal",
                typeof(bool),
                // ReSharper disable once LocalizableElement
                new DisplayNameAttribute("Is Local"));

            Path        = "";
            ProfileType = LoadProfileType.Honorbuddy;
            IsLocal     = true;
        }
コード例 #24
0
        public BuyItemAction()
        {
            Properties["Location"] = new MetaProp("Location", typeof(string),
                                                  new EditorAttribute(typeof(PropertyBag.LocationEditor),
                                                                      typeof(UITypeEditor)));
            Properties["NpcEntry"] = new MetaProp("NpcEntry", typeof(uint),
                                                  new EditorAttribute(typeof(PropertyBag.EntryEditor),
                                                                      typeof(UITypeEditor)));
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));
            Properties["Count"] = new MetaProp("Count", typeof(DynamicProperty<int>),
                                               new TypeConverterAttribute(typeof(DynamicProperty<int>.DynamivExpressionConverter)));
            Properties["BuyItemType"] = new MetaProp("BuyItemType", typeof(BuyItemActionType),
                                                     new DisplayNameAttribute("Buy"));
            Properties["BuyAdditively"] = new MetaProp("BuyAdditively", typeof(bool),
                                                       new DisplayNameAttribute("Buy Additively"));
            ItemID = "";
            Count = new DynamicProperty<int>(this, "0"); // dynamic expression
            RegisterDynamicProperty("Count");
            BuyItemType = BuyItemActionType.Material;
            _loc = WoWPoint.Zero;
            Location = _loc.ToInvariantString();
            NpcEntry = 0u;
            BuyAdditively = true;

            Properties["ItemID"].Show = false;
            Properties["Count"].Show = false;
            Properties["BuyAdditively"].Show = false;
            Properties["Location"].PropertyChanged += LocationChanged;
            Properties["BuyItemType"].PropertyChanged += BuyItemActionPropertyChanged;
        }
コード例 #25
0
        public BuyItemFromAhAction()
        {
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));
            Properties["MaxBuyout"] = new MetaProp("MaxBuyout", typeof(PropertyBag.GoldEditor),
                new DisplayNameAttribute("Max Buyout"), new TypeConverterAttribute(typeof(PropertyBag.GoldEditorConverter)));
            Properties["Amount"] = new MetaProp("Amount", typeof(DynamicProperty<int>),
                new TypeConverterAttribute(typeof(DynamicProperty<int>.DynamivExpressionConverter)));
            Properties["ItemListType"] = new MetaProp("ItemListType", typeof(ItemType), new DisplayNameAttribute("Buy ..."));
            Properties["AutoFindAh"] = new MetaProp("AutoFindAh", typeof(bool), new DisplayNameAttribute("Auto find AH"));
            Properties["BuyAdditively"] = new MetaProp("BuyAdditively", typeof(bool), new DisplayNameAttribute("Buy Additively"));

            Properties["BidOnItem"] = new MetaProp("BidOnItem", typeof(bool), new DisplayNameAttribute("Bid on Item"));
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));

            ItemID = "";
            Amount = new DynamicProperty<int>(this, "1");
            RegisterDynamicProperty("Amount");
            ItemListType = ItemType.Item;
            AutoFindAh = true;
            _loc = WoWPoint.Zero;
            Location = _loc.ToInvariantString();
            MaxBuyout = new PropertyBag.GoldEditor("100g0s0c");
            BidOnItem = false;
            BuyAdditively = true;

            Properties["AutoFindAh"].PropertyChanged += AutoFindAHChanged;
            Properties["ItemListType"].PropertyChanged += BuyItemFromAhActionPropertyChanged;
            Properties["Location"].PropertyChanged += LocationChanged;
            Properties["Amount"].Show = true;
            Properties["Location"].Show = false;
        }
コード例 #26
0
        public GetItemfromBankAction()
        {
            Properties["Amount"] = new MetaProp("Amount", typeof(int));
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));

            Properties["MinFreeBagSlots"]     = new MetaProp("MinFreeBagSlots", typeof(uint), new DisplayNameAttribute("Min Free Bagslots"));
            Properties["GetItemfromBankType"] = new MetaProp("GetItemfromBankType", typeof(BankWithdrawlItemType), new DisplayNameAttribute("Items to Withdraw"));
            Properties["Bank"]               = new MetaProp("Bank", typeof(BankType));
            Properties["AutoFindBank"]       = new MetaProp("AutoFindBank", typeof(bool), new DisplayNameAttribute("Auto find Bank"));
            Properties["Location"]           = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["NpcEntry"]           = new MetaProp("NpcEntry", typeof(uint), new EditorAttribute(typeof(PropertyBag.EntryEditor), typeof(UITypeEditor)));
            Properties["WithdrawAdditively"] = new MetaProp("WithdrawAdditively", typeof(bool), new DisplayNameAttribute("Withdraw Additively"));

            Amount              = 1;
            ItemID              = "";
            MinFreeBagSlots     = 2u;
            GetItemfromBankType = BankWithdrawlItemType.SpecificItem;
            Bank               = BankType.Personal;
            AutoFindBank       = true;
            loc                = WoWPoint.Zero;
            Location           = loc.ToInvariantString();
            NpcEntry           = 0u;
            WithdrawAdditively = true;

            Properties["Location"].Show = false;
            Properties["NpcEntry"].Show = false;
            Properties["AutoFindBank"].PropertyChanged        += new EventHandler(AutoFindBankChanged);
            Properties["GetItemfromBankType"].PropertyChanged += new EventHandler(GetItemfromBankAction_PropertyChanged);
            Properties["Location"].PropertyChanged            += new EventHandler(LocationChanged);
        }
コード例 #27
0
ファイル: MoveToAction.cs プロジェクト: ywjb/Honorbuddy-434
        public MoveToAction()
        {
            Properties["Entry"] = new MetaProp("Entry", typeof(uint),
                                               new EditorAttribute(typeof(PropertyBag.EntryEditor),
                                                                   typeof(UITypeEditor)),
                                               new DisplayNameAttribute(Pb.Strings["Action_Common_Entry"]));

            Properties["Location"] = new MetaProp("Location",
                                                  typeof(string),
                                                  new EditorAttribute(typeof(PropertyBag.LocationEditor),
                                                                      typeof(UITypeEditor)),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_Location"]));

            Properties["MoveType"] = new MetaProp("MoveType", typeof(MoveToType),
                                                  new DisplayNameAttribute(Pb.Strings["Action_MoveToAction_MoveToType"]));

            Properties["Pathing"] = new MetaProp("Pathing", typeof(NavigationType),
                                                 new DisplayNameAttribute(Pb.Strings["Action_Common_Use"]));

            Entry    = 0u;
            _loc     = WoWPoint.Zero;
            Location = _loc.ToInvariantString();
            MoveType = MoveToType.Location;
            Pathing  = NavigationType.Navigator;

            Properties["Entry"].Show = false;
            Properties["MoveType"].PropertyChanged += MoveToActionPropertyChanged;
            Properties["Location"].PropertyChanged += LocationChanged;
        }
コード例 #28
0
        public BuyItemFromAhAction()
        {
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));
            Properties["MaxBuyout"] = new MetaProp("MaxBuyout", typeof(PropertyBag.GoldEditor),
                new DisplayNameAttribute("Max Buyout"), new TypeConverterAttribute(typeof(PropertyBag.GoldEditorConverter)));
            Properties["Amount"] = new MetaProp("Amount", typeof(uint));
            Properties["ItemListType"] = new MetaProp("ItemListType", typeof(ItemType), new DisplayNameAttribute("Buy ..."));
            Properties["AutoFindAh"] = new MetaProp("AutoFindAh", typeof(bool), new DisplayNameAttribute("Auto find AH"));
            Properties["BuyAdditively"] = new MetaProp("BuyAdditively", typeof(bool), new DisplayNameAttribute("Buy Additively"));

            Properties["BidOnItem"] = new MetaProp("BidOnItem", typeof(bool), new DisplayNameAttribute("Bid on Item"));
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));

            ItemID = "";
            Amount = 1u;
            ItemListType = ItemType.Item;
            AutoFindAh = true;
            loc = WoWPoint.Zero;
            Location = loc.ToInvariantString();
            MaxBuyout = new PropertyBag.GoldEditor("100g0s0c");
            BidOnItem = false;
            BuyAdditively = true;

            Properties["AutoFindAh"].PropertyChanged += new EventHandler(AutoFindAHChanged);
            Properties["ItemListType"].PropertyChanged += new EventHandler(BuyItemFromAhAction_PropertyChanged);
            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
            Properties["Amount"].Show = true;
            Properties["Location"].Show = false;
        }
コード例 #29
0
        public MailItemAction()
        {
            Properties["ItemID"]          = new MetaProp("ItemID", typeof(string));
            Properties["AutoFindMailBox"] = new MetaProp("AutoFindMailBox", typeof(bool), new DisplayNameAttribute("Automatically find Mailbox"));
            Properties["Location"]        = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["UseCategory"]     = new MetaProp("UseCategory", typeof(bool), new DisplayNameAttribute("Use Category"));
            Properties["Category"]        = new MetaProp("Category", typeof(WoWItemClass), new DisplayNameAttribute("Item Category"));
            Properties["SubCategory"]     = new MetaProp("SubCategory", typeof(WoWItemTradeGoodsClass), new DisplayNameAttribute("Item SubCategory"));
            Properties["Amount"]          = new MetaProp("Amount", typeof(DynamicProperty <int>),
                                                         new TypeConverterAttribute(typeof(DynamicProperty <int> .DynamivExpressionConverter)));

            ItemID          = "";
            AutoFindMailBox = true;
            _loc            = WoWPoint.Zero;
            Location        = _loc.ToInvariantString();
            UseCategory     = true;
            Category        = WoWItemClass.TradeGoods;
            SubCategory     = WoWItemTradeGoodsClass.None;
            Amount          = new DynamicProperty <int>(this, "0");
            RegisterDynamicProperty("Amount");

            Properties["Location"].Show = false;
            Properties["ItemID"].Show   = false;
            Properties["AutoFindMailBox"].PropertyChanged += AutoFindMailBoxChanged;
            Properties["Location"].PropertyChanged        += LocationChanged;
            Properties["UseCategory"].PropertyChanged     += UseCategoryChanged;
            Properties["Category"].PropertyChanged        += CategoryChanged;
        }
コード例 #30
0
ファイル: If.cs プロジェクト: Asphodan/Alphabuddy
        public If()
        {
            // ReSharper disable DoNotCallOverridableMethodsInConstructor
            Properties = new PropertyBag();
            Properties["IgnoreCanRun"] = new MetaProp("IgnoreCanRun", typeof (bool),
                                                      new DisplayNameAttribute(
                                                          Professionbuddy.Instance.Strings["FlowControl_If_IgnoreCanRun"
                                                              ]));

            Properties["Condition"] = new MetaProp("Condition",
                                                   typeof (string),
                                                   new EditorAttribute(typeof (MultilineStringEditor),
                                                                       typeof (UITypeEditor)),
                                                   new DisplayNameAttribute(
                                                       Professionbuddy.Instance.Strings["FlowControl_If_Condition"]));

            Properties["CompileError"] = new MetaProp("CompileError", typeof (string), new ReadOnlyAttribute(true),
                                                      new DisplayNameAttribute(
                                                          Professionbuddy.Instance.Strings[
                                                              "Action_CSharpAction_CompileError"]));

            CanRunDelegate = c => false;
            Condition = "";
            CompileError = "";
            Properties["CompileError"].Show = false;

            Properties["Condition"].PropertyChanged += Condition_PropertyChanged;
            Properties["CompileError"].PropertyChanged += CompileErrorPropertyChanged;
            IgnoreCanRun = true;
            // ReSharper restore DoNotCallOverridableMethodsInConstructor
        }
コード例 #31
0
 public LoadProfileAction()
 {
     Properties["Path"]        = new MetaProp("Path", typeof(string), new EditorAttribute(typeof(PropertyBag.FileLocationEditor), typeof(UITypeEditor)));
     Properties["ProfileType"] = new MetaProp("ProfileType", typeof(LoadProfileType));
     Path        = "";
     ProfileType = LoadProfileType.Honorbuddy;
 }
コード例 #32
0
        public CancelAuctionAction()
        {
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string), new DisplayNameAttribute("Item ID List"));
            Properties["AutoFindAh"] = new MetaProp("AutoFindAh", typeof(bool), new DisplayNameAttribute("Auto find AH"));
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["UseCategory"] = new MetaProp("UseCategory", typeof(bool), new DisplayNameAttribute("Use Category"));
            Properties["Category"] = new MetaProp("Category", typeof(WoWItemClass), new DisplayNameAttribute("Item Category"));
            Properties["SubCategory"] = new MetaProp("SubCategory", typeof(WoWItemTradeGoodsClass), new DisplayNameAttribute("Item SubCategory"));
            Properties["MinBuyout"] = new MetaProp("MinBuyout", typeof(PropertyBag.GoldEditor),
                new DisplayNameAttribute("Min Buyout"), new TypeConverterAttribute(typeof(PropertyBag.GoldEditorConverter)));

            ItemID = "0";
            AutoFindAh = true;
            loc = WoWPoint.Zero;
            Location = loc.ToInvariantString();
            UseCategory = false;
            Category = WoWItemClass.TradeGoods;
            SubCategory = WoWItemTradeGoodsClass.None;
            MinBuyout = new PropertyBag.GoldEditor("0g0s0c");

            Properties["AutoFindAh"].PropertyChanged += new EventHandler(AutoFindAHChanged);
            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
            Properties["UseCategory"].PropertyChanged += UseCategoryChanged;
            Properties["Category"].PropertyChanged += CategoryChanged;

            Properties["Category"].Show = false;
            Properties["SubCategory"].Show = false;
            Properties["Location"].Show = false;
        }
コード例 #33
0
ファイル: SubRoutine.cs プロジェクト: naacra/wowhbbotcracked
 public SubRoutine()
     : base()
 {
     Properties = new PropertyBag();
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof(string));
     SubRoutineName = "";
 }
コード例 #34
0
        public Settings()
        {
            Properties["DefaultValue"] = new MetaProp("DefaultValue", typeof(string),
                                                      new DisplayNameAttribute(Pb.Strings["Action_Common_DefaultValue"]));

            Properties["Type"] = new MetaProp("Type", typeof(TypeCode),
                                              new DisplayNameAttribute(Pb.Strings["Action_Common_Type"]));

            Properties["Name"] = new MetaProp("Name", typeof(string),
                                              new DisplayNameAttribute(Pb.Strings["Action_Common_Name"]));

            Properties["Summary"] = new MetaProp("Summary", typeof(string),
                                                 new DisplayNameAttribute(Pb.Strings["Action_Common_Summary"]));

            Properties["Category"] = new MetaProp("Category", typeof(string),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_Category"]));

            Properties["Global"] = new MetaProp("Global", typeof(bool),
                                                new DisplayNameAttribute(Pb.Strings["Action_Common_Global"]));

            Properties["Hidden"] = new MetaProp("Hidden", typeof(bool),
                                                new DisplayNameAttribute(Pb.Strings["Action_Common_Hidden"]));

            DefaultValue = "true";
            Type         = TypeCode.Boolean;
            SettingName  = Pb.Strings["Action_Common_SettingName"];
            Summary      = Pb.Strings["Action_Common_SummaryExample"];
            Category     = "Misc";
            Global       = false;
            Hidden       = false;
        }
コード例 #35
0
        public InteractionAction()
        {
            Properties["Entry"] = new MetaProp("Entry", typeof(uint),
                                               new EditorAttribute(typeof(PropertyBag.EntryEditor),
                                                                   typeof(UITypeEditor)),
                                               new DisplayNameAttribute(Pb.Strings["Action_Common_Entry"]));

            Properties["InteractDelay"] = new MetaProp("InteractDelay", typeof(uint),
                                                       new DisplayNameAttribute(
                                                           Pb.Strings["Action_InteractAction_InteractDelay"]));

            Properties["InteractType"] = new MetaProp("InteractType", typeof(InteractActionType),
                                                      new DisplayNameAttribute(
                                                          Pb.Strings["Action_InteractAction_InteractType"]));

            Properties["GameObjectType"] = new MetaProp("GameObjectType", typeof(WoWGameObjectType),
                                                        new DisplayNameAttribute(
                                                            Pb.Strings["Action_InteractAction_GameobjectType"]));

            Properties["SpellFocus"] = new MetaProp("SpellFocus", typeof(WoWSpellFocus),
                                                    new DisplayNameAttribute(
                                                        Pb.Strings["Action_InteractAction_SpellFocus"]));

            InteractDelay  = Entry = 0u;
            InteractType   = InteractActionType.GameObject;
            GameObjectType = WoWGameObjectType.Mailbox;
            SpellFocus     = WoWSpellFocus.Anvil;

            Properties["SpellFocus"].Show = false;
            Properties["InteractType"].PropertyChanged   += InteractionActionPropertyChanged;
            Properties["GameObjectType"].PropertyChanged += InteractionActionPropertyChanged;
        }
コード例 #36
0
 public CommentAction()
 {
     Properties["Text"] = new MetaProp(
         "Text",
         typeof(string),
         new DisplayNameAttribute(ProfessionbuddyBot.Instance.Strings["Action_Comment_Name"]));
 }
コード例 #37
0
 public SubRoutineComposite(params Component[] children) : base(children)
 {
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof(string),
                                                 new DisplayNameAttribute(
                                                     ProfessionbuddyBot.Instance.Strings[
                                                         "Action_SubRoutine_SubroutineName"]));
     SubRoutineName = "";
 }
コード例 #38
0
 public ChangeBotAction()
 {
     Properties["BotName"] = new MetaProp(
         "BotName",
         typeof(string),
         new DisplayNameAttribute(Strings["Action_ChangeBotAction_BotName"]));
     BotName = "";
 }
コード例 #39
0
        private WhileComposite(Component[] children) : base(children)
        {
            Properties["PulseSecondaryBot"] = new MetaProp(
                "PulseSecondaryBot",
                typeof(bool),
                new DisplayNameAttribute(Strings["Composite_While_PulseSecondaryBot"]));

            PulseSecondaryBot = true;
        }
コード例 #40
0
 public CustomAction()
     : base(CsharpCodeType.Statements)
 {
     this.Action        = c => {; };
     Properties["Code"] = new MetaProp("Code", typeof(string),
                                       new EditorAttribute(typeof(MultilineStringEditor), typeof(UITypeEditor)));
     Code = "";
     Properties["Code"].PropertyChanged += CustomAction_PropertyChanged;
 }
コード例 #41
0
 public CallSubRoutineAction()
 {
     Properties["SubRoutineName"] = new MetaProp(
         "SubRoutineName",
         typeof(string),
         new DisplayNameAttribute(
             ProfessionbuddyBot.Instance.Strings["Action_Common_SubRoutineName"]));
     SubRoutineName = "";
 }
コード例 #42
0
 public SubRoutine()
 {
     Properties = new PropertyBag();
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof(string),
                                                 new DisplayNameAttribute(
                                                     Professionbuddy.Instance.Strings[
                                                         "Action_SubRoutine_SubroutineName"]));
     SubRoutineName = "";
 }
コード例 #43
0
ファイル: SubRoutine.cs プロジェクト: Asphodan/Alphabuddy
 public SubRoutine()
 {
     Properties = new PropertyBag();
     Properties["SubRoutineName"] = new MetaProp("SubRoutineName", typeof (string),
                                                 new DisplayNameAttribute(
                                                     Professionbuddy.Instance.Strings[
                                                         "Action_SubRoutine_SubroutineName"]));
     SubRoutineName = "";
 }
コード例 #44
0
ファイル: WaitAction.cs プロジェクト: Bia10/wowhbbotcracked-1
        public WaitAction() : base(CsharpCodeType.BoolExpression)
        {
            Properties["Timeout"]   = new MetaProp("Timeout", typeof(int));
            Properties["Condition"] = new MetaProp("Condition", typeof(string));

            Timeout        = 2000;
            Condition      = "false";
            CanRunDelegate = u => false;
        }
コード例 #45
0
ファイル: WaitAction.cs プロジェクト: naacra/wowhbbotcracked
        public WaitAction():base(CsharpCodeType.BoolExpression)
        {
            Properties["Timeout"] = new MetaProp("Timeout", typeof(int));
            Properties["Condition"] = new MetaProp("Condition", typeof(string));

            Timeout = 2000;
            Condition = "false";
            CanRunDelegate = u => false;
        }
コード例 #46
0
ファイル: FlyToAction.cs プロジェクト: naacra/wowhbbotcracked
        public FlyToAction() {
            Properties["Dismount"] = new MetaProp("Dismount", typeof(bool), new DisplayNameAttribute("Dismount on Arrival"));
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));

            Location = loc.ToInvariantString();
            Dismount = true;

            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
        }
コード例 #47
0
        void CategoryChanged(object sender, EventArgs e)
        {
            object subCategory = Callbacks.GetSubCategory(Category);

            Properties["SubCategory"] = new MetaProp("SubCategory", subCategory.GetType(),
                                                     new DisplayNameAttribute("Item SubCategory"));
            SubCategory = subCategory;
            RefreshPropertyGrid();
        }
コード例 #48
0
        void LocationChanged(object sender, EventArgs e)
        {
            MetaProp mp = (MetaProp)sender;

            loc = Util.StringToWoWPoint((string)((MetaProp)sender).Value);
            Properties["Location"].PropertyChanged -= new EventHandler(LocationChanged);
            Properties["Location"].Value            = string.Format("<{0}, {1}, {2}>", loc.X, loc.Y, loc.Z);
            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
            RefreshPropertyGrid();
        }
コード例 #49
0
        public CsharpAction()
        {
            CodeType = CsharpCodeType.Statements;
            Properties["CompileError"] = new MetaProp("CompileError", typeof(string), new ReadOnlyAttribute(true));
            
            CompileError = "";

            Properties["CompileError"].Show = false;
            Properties["CompileError"].PropertyChanged += new EventHandler(CompileError_PropertyChanged);
        }
コード例 #50
0
ファイル: CustomAction.cs プロジェクト: Asphodan/Alphabuddy
 public CustomAction()
     : base(CsharpCodeType.Statements)
 {
     Action = c => { ; };
     Properties["Code"] = new MetaProp("Code", typeof (string),
                                       new EditorAttribute(typeof (MultilineStringEditor), typeof (UITypeEditor)),
                                       new DisplayNameAttribute(Pb.Strings["Action_Common_Code"]));
     Code = "";
     Properties["Code"].PropertyChanged += CustomAction_PropertyChanged;
 }
コード例 #51
0
 protected CsharpAction(CsharpCodeType t)
 {
     // ReSharper disable DoNotCallOverridableMethodsInConstructor
     CodeType = t;
     Properties["CompileError"] = new MetaProp("CompileError", typeof(string), new ReadOnlyAttribute(true));
     CompileError = "";
     Properties["CompileError"].Show = false;
     Properties["CompileError"].PropertyChanged += CompileErrorPropertyChanged;
     // ReSharper restore DoNotCallOverridableMethodsInConstructor
 }
コード例 #52
0
        public TrainSkillAction()
        {
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["NpcEntry"] = new MetaProp("NpcEntry", typeof(uint), new EditorAttribute(typeof(PropertyBag.EntryEditor), typeof(UITypeEditor)));
            loc = WoWPoint.Zero;
            Location = loc.ToInvariantString();
            NpcEntry = 0u;

            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
        }
コード例 #53
0
ファイル: Settings.cs プロジェクト: naacra/wowhbbotcracked
 public Settings()
 {
     Properties["DefaultValue"] = new MetaProp("DefaultValue", typeof(string), new DisplayNameAttribute("Default Value"));
     Properties["Type"] = new MetaProp("Type", typeof(TypeCode));
     Properties["Name"] = new MetaProp("Name", typeof(string));
     Properties["Summary"] = new MetaProp("Summary", typeof(string));
     DefaultValue = "true";
     Type = TypeCode.Boolean;
     SettingName = "SettingName";
     Summary = "This is a summary of what this setting does";
 }
コード例 #54
0
        public WaitAction()
            : base(CsharpCodeType.BoolExpression)
        {
            Properties["Timeout"] = new MetaProp("Timeout", typeof(int));
            Properties["Condition"] = new MetaProp("Condition", typeof(string), new DisplayNameAttribute("Until Condition"),
                new EditorAttribute(typeof(MultilineStringEditor), typeof(UITypeEditor)));

            Timeout = 2000;
            Condition = "false";
            CanRunDelegate = u => false;
        }
コード例 #55
0
        public CancelAuctionAction()
        {
            Properties["ItemID"] = new MetaProp("ItemID", typeof (string),
                                                new DisplayNameAttribute(Pb.Strings["Action_Common_ItemEntries"]));

            Properties["AutoFindAh"] = new MetaProp("AutoFindAh", typeof (bool),
                                                    new DisplayNameAttribute(Pb.Strings["Action_Common_AutoFindAH"]));

            Properties["Location"] = new MetaProp("Location", typeof (string),
                                                  new EditorAttribute(typeof (PropertyBag.LocationEditor),
                                                                      typeof (UITypeEditor)),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_Location"]));

            Properties["UseCategory"] = new MetaProp("UseCategory", typeof (bool),
                                                     new DisplayNameAttribute(Pb.Strings["Action_Common_UseCategory"]));

            Properties["Category"] = new MetaProp("Category", typeof (WoWItemClass),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_ItemCategory"]));

            Properties["SubCategory"] = new MetaProp("SubCategory", typeof (WoWItemTradeGoodsClass),
                                                     new DisplayNameAttribute(
                                                         Pb.Strings["Action_Common_ItemSubCategory"]));

            Properties["MinBuyout"] = new MetaProp("MinBuyout", typeof (PropertyBag.GoldEditor),
                                                   new TypeConverterAttribute(typeof (PropertyBag.GoldEditorConverter)),
                                                   new DisplayNameAttribute(Pb.Strings["Action_Common_MinBuyout"]));

            Properties["IgnoreStackSizeBelow"] = new MetaProp("IgnoreStackSizeBelow", typeof (uint),
                                                              new DisplayNameAttribute(
                                                                  Pb.Strings["Action_Common_IgnoreStackSizeBelow"]));

            ItemID = "0";
            AutoFindAh = true;
            _loc = WoWPoint.Zero;
            Location = _loc.ToInvariantString();
            UseCategory = false;
            Category = WoWItemClass.TradeGoods;
            SubCategory = WoWItemTradeGoodsClass.None;
            MinBuyout = new PropertyBag.GoldEditor("0g0s0c");
            IgnoreStackSizeBelow = 1u;

            Properties["AutoFindAh"].PropertyChanged += AutoFindAHChanged;
            Properties["Location"].PropertyChanged += LocationChanged;
            Properties["UseCategory"].PropertyChanged += UseCategoryChanged;
            Properties["Category"].PropertyChanged += CategoryChanged;

            Properties["Category"].Show = false;
            Properties["SubCategory"].Show = false;
            Properties["Location"].Show = false;
        }
コード例 #56
0
ファイル: FlyToAction.cs プロジェクト: Asphodan/Alphabuddy
        public FlyToAction()
        {
            Properties["Dismount"] = new MetaProp("Dismount", typeof (bool),
                                                  new DisplayNameAttribute(Pb.Strings["Action_FlyToAction_Dismount"]));

            Properties["Location"] = new MetaProp("Location", typeof (string),
                                                  new EditorAttribute(typeof (PropertyBag.LocationEditor),
                                                                      typeof (UITypeEditor)),
                                                  new DisplayNameAttribute(Pb.Strings["Action_Common_Location"]));

            Location = _loc.ToInvariantString();
            Dismount = true;

            Properties["Location"].PropertyChanged += LocationChanged;
        }
コード例 #57
0
        public SellItemAction() {
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["NpcEntry"] = new MetaProp("NpcEntry", typeof(uint), new EditorAttribute(typeof(PropertyBag.EntryEditor), typeof(UITypeEditor)));
            Properties["ItemID"] = new MetaProp("ItemID", typeof(string));
            Properties["Count"] = new MetaProp("Count", typeof(uint));
            Properties["SellItemType"] = new MetaProp("SellItemType", typeof(SellItemActionType), new DisplayNameAttribute("Sell Item Type"));

            ItemID = "";
            Count = 0u;
            loc = WoWPoint.Zero;
            Location = loc.ToInvariantString();
            NpcEntry = 0u;

            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
            Properties["SellItemType"].Value = SellItemActionType.Specific;
            Properties["SellItemType"].PropertyChanged += new EventHandler(SellItemAction_PropertyChanged);
        }
コード例 #58
0
ファイル: If.cs プロジェクト: naacra/wowhbbotcracked
        public If()
            : base()
        {
            Properties = new PropertyBag();
            Properties["IgnoreCanRun"] = new MetaProp("IgnoreCanRun", typeof(bool), new DisplayNameAttribute("Ignore Condition until done"));
            Properties["Condition"] = new MetaProp("Condition", typeof(string));
            Properties["CompileError"] = new MetaProp("CompileError", typeof(string), new ReadOnlyAttribute(true));

            this.CanRunDelegate = c => false;
            Condition = "";
            CompileError = "";
            Properties["CompileError"].Show = false;

            Properties["Condition"].PropertyChanged += new EventHandler(Condition_PropertyChanged);
            Properties["CompileError"].PropertyChanged += new EventHandler(CompileError_PropertyChanged);
            IgnoreCanRun = true;
        }
コード例 #59
0
        public MoveToAction()
        {
            Properties["Entry"] = new MetaProp("Entry", typeof(uint), new EditorAttribute(typeof(PropertyBag.EntryEditor), typeof(UITypeEditor)));
            Properties["Location"] = new MetaProp("Location", typeof(string), new EditorAttribute(typeof(PropertyBag.LocationEditor), typeof(UITypeEditor)));
            Properties["MoveType"] = new MetaProp("MoveType", typeof(MoveToType), new DisplayNameAttribute("MoveTo Type"));
            Properties["Pathing"] = new MetaProp("Pathing", typeof(NavigationType), new DisplayNameAttribute("Use"));

            Entry = 0u;
            loc = WoWPoint.Zero;
            Location = loc.ToInvariantString();
            MoveType = MoveToType.Location;
            Pathing = NavigationType.Navigator;

            Properties["Entry"].Show = false;
            Properties["MoveType"].PropertyChanged += new EventHandler(MoveToAction_PropertyChanged);
            Properties["Location"].PropertyChanged += new EventHandler(LocationChanged);
        }
コード例 #60
0
ファイル: WaitAction.cs プロジェクト: Asphodan/Alphabuddy
        public WaitAction()
            : base(CsharpCodeType.BoolExpression)
        {
            Properties["Timeout"] = new MetaProp("Timeout", typeof (DynamicProperty<int>),
                                                 new TypeConverterAttribute(
                                                     typeof (DynamicProperty<int>.DynamivExpressionConverter)),
                                                 new DisplayNameAttribute(Pb.Strings["Action_Common_Timeout"]));

            Properties["Condition"] = new MetaProp("Condition", typeof (string),
                                                   new EditorAttribute(typeof (MultilineStringEditor),
                                                                       typeof (UITypeEditor)),
                                                   new DisplayNameAttribute(Pb.Strings["Action_WaitAction_Condition"]));

            Timeout = new DynamicProperty<int>(this, "2000");

            Condition = "false";
            CanRunDelegate = u => false;
        }