zatvorgt 5 Posted June 16, 2018 Share Posted June 16, 2018 Hello all, help please, need code to sell items to vendor if (wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWith(Npc npc, bool skipIfCannotMakePath = false, BooleanDelegate conditionExit = null, bool acceptNpcDead = false)) { wManager.Wow.Helpers.Vendor.SellItems(List<String> itemSell, List<string> itemNoSell, List<Enums.WoWItemQuality> itemQuality); } this code dont work Link to comment Share on other sites More sharing options...
Ordush 185 Posted June 16, 2018 Share Posted June 16, 2018 You can just use ToTown Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 need code to sell items after interract to vendor , i want to full manualy selling items for 100% work, pulse csharp or runcode exist code?any help i use interractwithnpc and next step need code to sell all items without dinotselllist items Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 i put this code in runcode and have string error wManager.Wow.Helpers.Vendor.SellItems(List<String> itemSell, List<string> itemNoSell, List<Enums.WoWItemQuality> itemQuality); Link to comment Share on other sites More sharing options...
BetterSister 367 Posted June 16, 2018 Share Posted June 16, 2018 wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWith can't be used as boolean Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 1 minute ago, BetterSister said: wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWith can't be used as boolean i about this, wManager.Wow.Helpers.Vendor.SellItems(List<String> itemSell, List<string> itemNoSell, List<Enums.WoWItemQuality> itemQuality); Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 maybe exist another code to manual selling who have dontsellist Link to comment Share on other sites More sharing options...
Ordush 185 Posted June 16, 2018 Share Posted June 16, 2018 Just now, zatvorgt said: maybe exist another code to manual selling who have dontsellist Is it because there are specific items you want to sell, or is it a specific vendor you want to use? Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 specific vendor , i interract with him wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWithNpc and next step need code to selling him all items and save donotselllist items Link to comment Share on other sites More sharing options...
Ordush 185 Posted June 16, 2018 Share Posted June 16, 2018 (edited) 4 minutes ago, zatvorgt said: specific vendor , i interract with him wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWithNpc and next step need code to selling him all items and save donotselllist items You can just go to that vendor and call ToTown, it should use the nearest vendor? Edit: I mean go to the vendor, open his trade window. Edited June 16, 2018 by Ordush Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 dont need interract) i interract manually with him , need code to sell items , vendor is interracted and window trade is opened, Link to comment Share on other sites More sharing options...
Findeh 34 Posted June 16, 2018 Share Posted June 16, 2018 4 hours ago, Ordush said: You can just go to that vendor and call ToTown, it should use the nearest vendor? Edit: I mean go to the vendor, open his trade window. As far as i know, not every vendor is working like this. Wrobot is ignoring some vendors completely. He interacts, open trade window, do nothing, close trade window and then repeat. Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 41 minutes ago, Findeh said: Насколько я знаю, не каждый продавец работает так. Wrobot полностью игнорирует некоторые производители. Он взаимодействует, открывает окно торговли, ничего не делает, закрывает окно торговли, а затем повторяется. yes, need manual code to sell items Link to comment Share on other sites More sharing options...
Ordush 185 Posted June 16, 2018 Share Posted June 16, 2018 Just now, zatvorgt said: yes, need manual code to sell items afraid it's not something I've ever looked into. Maybe @Matenia knows something, hard to tell. ? Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 16, 2018 Author Share Posted June 16, 2018 i search this code, work good, maybe resolve my problem, will see tomorrow wManager.Wow.Bot.States.ToTown.ForceToTown = true; Link to comment Share on other sites More sharing options...
Ordush 185 Posted June 16, 2018 Share Posted June 16, 2018 Just now, zatvorgt said: i search this code, work good, maybe resolve my problem, will see tomorrow wManager.Wow.Bot.States.ToTown.ForceToTown = true; But.. That is what i started telling you to use ? Link to comment Share on other sites More sharing options...
sb360 17 Posted June 17, 2018 Share Posted June 17, 2018 int bagSlots = 4; if (Lua.LuaDoString<bool>("show=MerchantFrame:IsShown();", "show")) { for (int i = 0; i < bagSlots; i++) { int numSlots = Lua.LuaDoString<int>("bagSlots=GetContainerNumSlots(" + i + ");", "bagSlots"); for (int a = 1; a < numSlots; a++) { string itemLink = Lua.LuaDoString<string>("itemLink=GetContainerItemLink(" + i + ", " + a + ");", "itemLink"); if (!wManager.wManagerSetting.CurrentSetting.DoNotSellList.Contains(System.Text.RegularExpressions.Regex.Match(itemLink, @"\[([^)]*)\]").Groups[1].Value) && itemLink != "nil") { Logging.WriteDebug("Selling " + System.Text.RegularExpressions.Regex.Match(itemLink, @"\[([^)]*)\]").Groups[1].Value); Lua.LuaDoString("UseContainerItem(" + i + ", " + a + ");"); } Thread.Sleep(500); } } } sith500 1 Link to comment Share on other sites More sharing options...
zatvorgt 5 Posted June 17, 2018 Author Share Posted June 17, 2018 Thanks for all! wrok to town and this lua code !) Link to comment Share on other sites More sharing options...
Pudge 24 Posted February 29, 2020 Share Posted February 29, 2020 List<WoWItemQuality> quality = new List<WoWItemQuality> // Quality items to sell { WoWItemQuality.Common, WoWItemQuality.Poor, WoWItemQuality.Rare, WoWItemQuality.Epic, WoWItemQuality.Uncommon }; var Sellitems = new List<string>(); if (wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWithNpc(new robotManager.Helpful.Vector3(-2978.95f, 4033.11f, 3.574616f, "Flying"), 19056)) // interact with npc code { foreach(var item in Bag.GetBagItem()) { if (item != null && !wManager.wManagerSetting.CurrentSetting.DoNotSellList.Contains(item.Name)) { Sellitems.Add(item.Name); } } Vendor.SellItems(Sellitems , wManager.wManagerSetting.CurrentSetting.DoNotSellList, quality); Vendor.RepairAllItems(); } Thread.Sleep(10000); Link to comment Share on other sites More sharing options...
TheSmokie 242 Posted August 9, 2020 Share Posted August 9, 2020 (edited) I know this is a old thread but i came across it when trying to find a method to bender item by name, i was able to make a method that vender ALL item by the name, i thought I'd share. public static class Toolbox { public static void Sellitem(string ItemName) { Lua.LuaDoString(string.Format(@" local ItemToSell = '{0}' for bag = 0,4,1 do for slot = 1, GetContainerNumSlots(bag), 1 do local name = GetContainerItemLink(bag, slot); if name and string.find(name, ItemToSell) then if (MerchantFrame:IsShown() ) then ShowMerchantSellCursor(1) UseContainerItem(bag, slot) end end end end", ItemName)); } } if (wManager.Wow.Bot.Tasks.GoToTask.ToPositionAndIntecractWithNpc(new Vector3(x, y, z), NpcID, 1)) { Toolbox.Sellitem("Name of item"); } Edited August 9, 2020 by TheSmokie Typo Strijder and zatvorgt 2 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now