Search results

  1. philmasterplus

    Does file_to_map() ever return false?

    file_to_map() is extremely forgiving. It will return true if: The file does not exist The file's contents do not match the map used The file is a binary file (e.g. KoLmafia's own JAR file) The file path is empty or invalid (e.g. "!@#$%^") The file path is actually a directory (e.g. "data/") The...
  2. philmasterplus

    Bug - Fixed IotMs not marked as nosmash (Oct. 2019 ~ Mar. 2021)

    The following IotM equipments, released between October 2019 and present, are not marked as nosmash in pulverize.txt. get_related() believes that they can be smashed into twinkly powders and/or nuggets. Eight Days a Week Pill Keeper Powerful Glove Guzzlr tablet Iunion Crown Cargo Cultist Shorts...
  3. philmasterplus

    Scripting the birth of a new life.

    Yes. Though I don't know if existing choice configurations are actually applicable/optimal for these newer paths. A compromise would be to display a warning popup that auto-closes after ~30 seconds, which provides the option to abort newlife2.ash.
  4. philmasterplus

    Scripting the birth of a new life.

    I forked the project on GitHub: https://github.com/Loathing-Associates-Scripting-Society/newlife2 . Currently, it only provides a fix for the Torso Awareness issue, though I hope other improvements may come. PRs are welcome!
  5. philmasterplus

    Bug - Fixed Don't escape HTML entities when executing "js" command

    When JavaScript code is executed with the gCLI js command, the entire string is processed with CharacterEntities.unescape() before being passed to the JavaScript interpreter. While this behavior is standard for most gCLI commands, it makes debugging JS one-liners difficult. In contrast, the ash...
  6. philmasterplus

    Harvest – A highly customisable farming script

    Fixed in r35. Btw, I didn't have time to make a switch to OCD-Cleanup. Originally, I wanted to allow users to choose between OCD Inventory Control and OCD-Cleanup. Unfortunately, this won't be possible because ASH doesn't support conditional/dynamic imports, so we can't choose which to import...
  7. philmasterplus

    Feature Support commas in items in buy/buy from mall

    I'm probably beating a dead horse, but I discovered that pilcrows (¶) were used in the olden days to feed raw item IDs to gCLI commands. Have we reinvented the wheel? (I discovered this while examining OCD Inventory Control, btw.)
  8. philmasterplus

    Bug Player status is not updated after Ascending but before entering the Pearly Gates

    Ascended again. I verified that, after reaching the Pearly Gates, manually calling visitUrl("charpane.php") did not set my class to "Astral Spirit". (Although it did reset my stats to 1/1/1). It seems that the only workaround for now is logging out and back in, or manually entering the Pearly...
  9. philmasterplus

    Bug Player status is not updated after Ascending but before entering the Pearly Gates

    I traced the execution flow during an automated jump-into-gash in r20645. To do so, I set up some breakpoints in IntelliJ and ascended by executing the JavaScript statement visitUrl('ascend.php?action=ascend&pwd&confirm=on&confirm2=on'). I discovered that KoLmafia had two places where it could...
  10. philmasterplus

    Bug available_choice_select_inputs() incorrectly parses <select> tags

    I've been dogfooding this patch on 3 different characters for over a week and found no issues. May I request integrating this (possibly after a code review)?
  11. philmasterplus

    Feature Support commas in items in buy/buy from mall

    When I suggested backticks, I wasn't even considering variable substitution (i.e. Python's f-strings or JavaScript's template literals). I simply chose them because single- and double-quotes are already used in several item names. Variable substitution in gCLI is an unrelated topic. No need to...
  12. philmasterplus

    Feature Support commas in items in buy/buy from mall

    @MCroft If we're after a general solution, I'm still in favor of surrounding/escape characters. It's a bigger effort than changing just one command. But it benefits every command that accepts multiple items, effects, etc. Any clever parsing trick has pitfalls. What if there are three different...
  13. philmasterplus

    Feature Support commas in items in buy/buy from mall

    Oh. I thought this was a general gCLI usability issue. So the actual problem is the lack of a scriptable "buy from mall, bypassing the vendor check" feature? In that case, I agree that a new function (or an overloaded form of buy()) would be better.
  14. philmasterplus

    Feature Support commas in items in buy/buy from mall

    Perhaps allow backticks as wrapping characters? They are never used in item names (unless they release more stuff like the Baby Bugged Bugbear famequips). > buy from mall `Notes from the Elfpocalypse, Chapter VI` Ofc this is coming from someone who writes JavaScript every day and sprinkles...
  15. philmasterplus

    Bug Player status is not updated after Ascending but before entering the Pearly Gates

    I suppose some people enjoy manually clicking on the gates and reading the welcome message. KoL is about clicking and reading, after all. (Off-topic: This is one reason I am dissatisfied with Bale's NewLife.ash. It seems to suppress auto-pull messages that you receive after reincarnation, e.g...
  16. philmasterplus

    Bug - Fixed put_shop() coerces item quantity from float to int incorrectly

    Verified that put_shop() works correctly in r20632. Thank you! > inv spices spices (2) > ash put_shop(0, 0, 0.5, $item[spices]) Returned: true > ash put_shop(0, 0, 1.5, $item[spices]) Adding spices to store... 1 spices added to your store. Returned: true > inv spices spices > ash...
  17. philmasterplus

    Bug Player status is not updated after Ascending but before entering the Pearly Gates

    I'm honestly not sure. Auto-entering the Mini-Pearly Gates might work, but I'd prefer another method that doesn't affect the game state. Reading the code, it seems that visiting charpane.php would cause KoLmafia to correctly update the status. Visiting api.php doesn't help because it checks the...
  18. philmasterplus

    Bug Player status is not updated after Ascending but before entering the Pearly Gates

    (Tested in r20631) When the player enters the Astral Gash (visit ascend.php?action=ascend&pwd&confirm=on&confirm2=on), but has not clicked The Mini-Pearly Gates yet, KoLmafia does not update the player's status (i.e. class is still the old class, player has non-zero mus/mys/mox, etc.). > ash...
  19. philmasterplus

    Bug - Fixed put_shop() coerces item quantity from float to int incorrectly

    I, too, am against "smart" string-to-int conversion. It can hide programming mistakes (e.g. two string and int variables with similar names). This is one "feature" I dislike about JavaScript.
  20. philmasterplus

    Bug - Fixed put_shop() coerces item quantity from float to int incorrectly

    In that case, shouldn't the function call below cast the 1.5 to 1? It seems that KoLmafia is casting 1.5 to 0. put_shop(0, 0, 1.5, $item[ spices ]); // Prints "Adding spices to store..." and returns true, // but does not transfer any items
Back
Top