Important Change for Honorbuddy, Demonbuddy and HearthBuddy Lifetime Users

    Greetings Buddies,
    For our long term plans, it is inevitable to do the following changes effective immediately (tomorrow - 18 January 2017). We are changing all existing Demonbuddy and Honorbuddy Lifetime licenses to expire after 2 years of usage.


    read more



Results 1 to 5 of 5
  1. #1
    Buddy
    Reputation
    Join Date
    03.11.2014
    Posts
    287

    Default How can I make an auction listing? Having problem using MakeAuctionLot

    Good evening guys,

    Can someone plz post a snippet on how to create an auction for a specific product with a certain amount? For example, I want to create an auction for 500 Barley with a Buyout of 3s per item and the Starting Bid of 10g. I searched a lot in the forums in the API and could not make it work.

    The best idea I could find was that I needed to create an stack of 500 barley and do a MakeAuctionLot, but had problems doing that, since C# isn't my main programming language, I appreciate if someone could let me a hand, thx.

  2. #2
    Archebuddy Core Developer
    Reputation
    Join Date
    02.06.2012
    Posts
    2,973

    Default

    Code:
    //or getInvItems(ITEM_ID)
    var item = getInvItem("Barley");
    if (item != null)
    {
        //1 silver = 100 copper
        //baseSellPrice - starting price for one item
        //buyBackPrice - buyback price for one item.
        item.MakeAuctionLot(300 /*baseSellPrice*/, 500/*buyBackPrice*/, AuctionSellTime.TwentyFourHours);
        //this will put stack of item to auction.
        //if you need to put two or more stacks or find stack that you need - you can use something like    
        foreach (var item in getInvItems("Barley"))
        {
             if (item..... ......)
                    ...........
        }
    }

  3. #3
    Buddy
    Reputation
    Join Date
    03.11.2014
    Posts
    287

    Default

    Quote Originally Posted by Out View Post
    Code:
    //or getInvItems(ITEM_ID)
    var item = getInvItem("Barley");
    if (item != null)
    {
        //1 silver = 100 copper
        //baseSellPrice - starting price for one item
        //buyBackPrice - buyback price for one item.
        item.MakeAuctionLot(300 /*baseSellPrice*/, 500/*buyBackPrice*/, AuctionSellTime.TwentyFourHours);
        //this will put stack of item to auction.
        //if you need to put two or more stacks or find stack that you need - you can use something like    
        foreach (var item in getInvItems("Barley"))
        {
             if (item..... ......)
                    ...........
        }
    }
    Big thx for the help Out, but I was wondering, is it possible to sell stacks of 200 for example of a given item?
    Last edited by Voyager92; 08.01.2017 at 23:00.

  4. #4
    Archebuddy Core Developer
    Reputation
    Join Date
    02.06.2012
    Posts
    2,973

    Default

    Big thx for the help Out, but I was wondering, is it possible to sell stacks of 200 for example of a given item?
    Split them first into stacks with needed count

  5. #5
    Buddy
    Reputation
    Join Date
    03.11.2014
    Posts
    287

    Default

    Quote Originally Posted by Out View Post
    Split them first into stacks with needed count
    Yeah, when I tried the plugin yesterday, it worked with the stacks, thanks for the help Out.

 

 

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts
  •