Page 37 of 37 FirstFirst ... 27 35 36 37
Results 361 to 367 of 367

Thread: My personal Meat farming script

  1. #361
    Developer Veracity's Avatar
    Join Date
    Mar 2006
    Location
    The Unseelie Court
    Posts
    11,410

    Default

    I have confirmed that this script does not play nicely with CounterChecker.

    The semirare adventure arrived, VMF decided where it wanted to go.
    CounterChecker kicked in and went somewhere else.
    VMF went where it wanted - and got a stupid adventure, as expected -and then drank another Lucky Lindy.
    Next semirare, CounerChecker decided to go for a "black eyedrops", as opposed to what was configured - and then couldn't eat a fortune cookie.

    Yeah. that sucks.

    Either we defer to CounterChecker - which wants to collect semirares and then eat a fortune cookie - or we disable it and do our own counter handling.

  2. #362
    Developer Veracity's Avatar
    Join Date
    Mar 2006
    Location
    The Unseelie Court
    Posts
    11,410

    Default

    And, by the way, revision 113 deals with the following bugs:

    - searched for "best foods". At fullness 2, "bowl of maggots" was it - with a single seller in the entire mall at less than mall price limit - and that one had a limit of one.
    (There are now a couple of sellers offering it at on-competitive prices), but, if you can't acquire the number you expected, move on,
    - if you actually collect 3 semirares in a session, when it came time to drink another Lucky Lindy, you couldn't. We did not handle this case correctly.
    - We do a bulk mallpricess to prime Sweet Synthesis.
    There are 195 "potions" and 23 "food" candies
    This means if I could search for "candy" in the mall, it would take 22 server hits,
    Instead, searching for "potions" and "food", it takes takes 104 (potion) + 68 (food) = 172 server hits and 2 file updates.
    This is still better than 218 server hits + 218 file updates.

    I submitted a suggestion to KoL to let me search for "candy" and turn my 172 server hits to 22 server hits.
    No response. But, heck - although the API improvement would help both them and us, there is a workaround - which we now use.

  3. #363
    Senior Member
    Join Date
    Feb 2010
    Posts
    972

    Default

    Would you consider the addition of challenging the God Lobster to the list of things that the script will automate? In aftercore I normally have all the familiar items granted by the challenge and I'm primarily interested in the dish of clarified butter.

  4. #364
    Developer
    Join Date
    Aug 2009
    Posts
    2,805

    Default

    There are 195 "potions" and 23 "food" candies
    This means if I could search for "candy" in the mall, it would take 22 server hits,
    Instead, searching for "potions" and "food", it takes takes 104 (potion) + 68 (food) = 172 server hits and 2 file updates.
    This is still better than 218 server hits + 218 file updates.
    Originally Posted by Veracity View Post
    Isn't another alternative to search for "potions" and let mafia do individual searches for candy foods, for 24 server hits and 24 file updates?

    (does mall_price really do a file update after each query? I would have assumed updates are cached until some event like logging out.)

  5. #365
    Developer Veracity's Avatar
    Join Date
    Mar 2006
    Location
    The Unseelie Court
    Posts
    11,410

    Default

    Reasonable idea. Yes, mall_price really does update the file after each query. When I added category searches, I added the mechanism which separates mall search/update from the file write, but I did not change it to write only at logout. That is still potentially a good idea, but for now I did this in Revision 18937:

    int mall_price( item ) - return the mall price for a single item. Will return cached value, if less than an hour old, otherwise does a mall search and file update
    int mall_prices( string ) - does a category search for the category, updating all cached values, does a single file write at the end and returns the count. Subsequent mall_price( item ) will get cached value.

    and now

    int mall_prices( boolean[item] ) - takes an item set (the same data structure of $items[ ...] ) and effectively does a mall_price() for each one: only searches mall if the cached price is more than an hour old, and updates cached value from such searches. Does a file write at the end and returns the total number of prices that were updated.

    I'll update this script to use this, by and by. For now, the "Update Prices" button in the Synthesis Frame uses this for the 23 foods, rather than doing 68 page loads for all "food" items.

  6. #366
    Developer Veracity's Avatar
    Join Date
    Mar 2006
    Location
    The Unseelie Court
    Posts
    11,410

    Default

    Revision 114 of this script will look up the 23 food chocolates, one by one, rather than fetching all 68 pages of all foods.

  7. #367
    Developer
    Join Date
    Aug 2009
    Posts
    2,805

    Default

    You mentioned "food chocolates" (although I assume that was a typo in which you meant food candies), which got me thinking about further consolidation with mall searches via common substrings, e.g. searching for "cane" / "bear" / "fudge" / "mint" / "candy" under category food.

    Unfortunately, "bear" would match gummi bear, drunki-bear, and warbear stuff, among others, but either way we get 2 server hits. Some experimenting in-game suggests we could get away with only seeing the first page of results by sorting by level requirement (decreasing).

    (either way, I doubt that the difference between 10 and 23 server hits is particularly noticeable or worth the effort.)

Posting Permissions

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