Jump to content
Frequently Asked Questions
  • Are you not able to open the client? Try following our getting started guide
  • Still not working? Try downloading and running JarFix
  • Help! My bot doesn't do anything! Enable fresh start in client settings and restart the client
  • How to purchase with PayPal/OSRS/Crypto gold? You can purchase vouchers from other users
  • Quests.isFinished() returns incorrect value when the "Quest" tab is on a different sub-tab


    Havefunpeeps

    Recommended Posts

    Ran into this bug while working through a private script I'm working on.

    My account has Sheep Shearer completed.

    Quests.isFinished(FreeQuest.SHEEP_SHEARER)

    The above will only return true if the "Quests" sub-tab is selected within the Quests tab. If the user or script has selected the achievement diary or account summary sub-tabs, this API appears to return false for all quests.

    Link to comment
    Share on other sites

    Instead of checking it that way, a "somewhat" easier way to do it would be through varps and varbits

    You can find the corresponding setting for each quest here: 

    https://github.com/Zoinkwiz/quest-helper/blob/master/src/main/java/com/questhelper/QuestVarPlayer.java
    https://github.com/Zoinkwiz/quest-helper/blob/master/src/main/java/com/questhelper/QuestVarbits.java

    In the case of the quest sheep shearer, the PlayerSetting would be 179 and after reaching a certain "checkpoint", the value of it will change.
    For example: After speaking with Fred (Sheep Shearer Quest) to start the quest, 179 would become 1, and after finishing the quest, 179 would become 21. These values vary per quest.

    In terms of how it actually looks, it'd be something like 

    PlayerSettings.getConfig(179)

     

    If you started quest: 

    PlayerSettings.getConfig(179) == 1

     

    If quest is completed

    PlayerSettings.getConfig(179) == 21

     

    1340034874_Screenshot2022-03-15194630.jpg.25097d9416d9ca5e24e0fabe29978f92.jpg

    You can find changing PlayerSetting values in the Recent Updates section after passing a "checkpoint" in said quest.
    The Settings will be your PlayerSetting.getConfig and Varbits will be your PlayerSetting.getBitValue

    This doesn't really help your problem with Quests.isFinished but it should be "easier" if you use this instead, I think.

     

    Link to comment
    Share on other sites

    Archived

    This topic is now archived and is closed to further replies.

    ×
    ×
    • Create New...

    Important Information

    We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.