Coder Social home page Coder Social logo

bumbleshoot / quest-tracker Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 2.0 441 KB

Automatically updates a Google Sheet in the player's Google Drive whenever the player's party completes a quest. The spreadsheet shows how many quest completions are needed by each party member for every quest in Habitica, in order to get all the rewards. Also shows total quest completion percentages for each party member and quest.

Home Page: https://habitica.fandom.com/wiki/Quest_Tracker

JavaScript 100.00%
automation google-apps-script habitica script

quest-tracker's Introduction

Summary

Automatically updates a Google Sheet in the player's Google Drive whenever the player's party completes a quest. The spreadsheet shows how many quest completions are needed by each party member for every quest in Habitica, in order to get all the rewards. Also shows total quest completion percentages for each party member and quest. The spreadsheet can be shared with the player's party, so only one party member needs to run this automation (preferably the party leader).

Setup Instructions

It is highly recommended that you use a desktop computer for this, as some of the steps don't work well on mobile.

  1. Click here to go to the Quest Tracker script. If you're not signed into your Google account, click on "Start Scripting", then sign in, then click on the script link again.
  2. Click the "Make a copy" button (looks like two pages of paper).
  3. At the top of your screen, click on "Copy of Quest Tracker". Rename it "Quest Tracker" and click the "Rename" button.
  4. Click here to open your API Settings. Highlight and copy your User ID (it looks something like this: 35c3fb6f-fb98-4bc3-b57a-ac01137d0847). In the Quest Tracker script, paste your User ID between the quotations where it says const USER_ID = "";. It should now look something like this: const USER_ID = "35c3fb6f-fb98-4bc3-b57a-ac01137d0847";
  5. On the same page where you copied your User ID, click the "Show API Token" button, and copy your API Token. In the Quest Tracker script, paste your API Token between the quotations where it says const API_TOKEN = "";. It should now look something like this: const API_TOKEN = "35c3fb6f-fb98-4bc3-b57a-ac01137d0847";
  6. Create a new Google Sheet and name it something like "[Party Name] Quest Tracker". Click the "Share" button near the top right corner of the page (looks like a little person). Click the dropdown under "General access", and select "Anyone with the link". Then click the "Copy link" button.
  7. Skip the line that says const WEB_APP_URL = "";. We will come back to that later. Paste the spreadsheet URL inside the quotations where it says const QUEST_TRACKER_SPREADSHEET_URL = "";. If you've changed the tab name for the sheet you want to print the Quest Tracker to, paste the tab name inside the quotes where it says const QUEST_TRACKER_SPREADSHEET_TAB_NAME = "";.
  8. Click the "Save project" button near the top of the page (looks like a floppy disk).
  9. Click the blue "Deploy" button near the top of the page, then click "New deployment", then click the "Deploy" button.
  10. (If this is your first time deploying) Click the "Review permissions" button and select your Google account. Click on "Advanced", then "Go to Quest Tracker (unsafe)". (Don't worry, it is safe!) Then click "Continue", then "Allow".
  11. Under "Web app", click the "Copy" button to copy the Web App URL. Then click the "Done" button.
  12. Paste your Web App URL inside the quotations where it says const WEB_APP_URL = "";.
  13. Click the drop-down menu to the right of the "Debug" button, near the top of the page. Select "install" from the drop-down.
  14. Click the "Run" button to the left of the "Debug" button. Wait for it to say "Execution completed".
  15. You can now update your party's description to include a link to the Quest Tracker spreadsheet. You can also put anything you want in row 1 of the spreadsheet, and it will not be overwritten by the script.

You're all done! If you need to change the settings or uninstall the script at some point, follow the steps below.

Changing the Settings

It is highly recommended that you use a desktop computer for this, as some of the steps don't work well on mobile.

  1. Click here to see a list of your scripts. If you're not already signed into your Google account, click the "Start Scripting" button and sign in. Then click on "My Projects" in the main menu on the left.
  2. Click on "Quest Tracker".
  3. Edit the settings (consts) to your liking.
  4. Click the "Save project" button near the top of the page (looks like a floppy disk).
  5. Click the blue "Deploy" button near the top of the page, then click "Manage deployments".
  6. Click the "Edit" button (looks like a pencil). Under "Version", select "New version".
  7. Click the "Deploy" button, then the "Done" button.

Uninstalling the Script

It is highly recommended that you use a desktop computer for this, as some of the steps don't work well on mobile.

  1. Click here to see a list of your scripts. If you're not already signed into your Google account, click the "Start Scripting" button and sign in. Then click on "My Projects" in the main menu on the left.
  2. Click on "Quest Tracker".
  3. Click the drop-down menu to the right of the "Debug" button, near the top of the page. Select "uninstall" from the drop-down.
  4. Click the "Run" button to the left of the "Debug" button. Wait for it to say "Execution completed".
  5. Click the blue "Deploy" button near the top of the page, then click "Manage deployments".
  6. Click the "Archive" button (looks like a box with a down arrow inside). Then click the "Done" button.

Updating the Script

It is highly recommended that you use a desktop computer for this, as some of the steps don't work well on mobile.

  1. Follow the steps in Uninstalling the Script above.
  2. Copy & paste your settings (consts) into a text editor so you can reference them while setting up the new version.
  3. In the main menu on the left, click on "Overview" (looks like a lowercase letter i inside a circle).
  4. Click the "Remove project" button (looks like a trash can).
  5. Follow the Setup Instructions above. You don't have to make a new Quest Tracker spreadsheet, just use your existing one.

Contact

โ” Questions: https://github.com/bumbleshoot/quest-tracker/discussions/categories/q-a
๐Ÿ’ก Suggestions: https://github.com/bumbleshoot/quest-tracker/discussions/categories/suggestions
๐Ÿž Report a bug: https://github.com/bumbleshoot/quest-tracker/issues
๐Ÿ’— Donate: https://github.com/sponsors/bumbleshoot

quest-tracker's People

Contributors

bumbleshoot avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

ramotar mrquj

quest-tracker's Issues

Blank?

Per the Quest Tracker Summary, installing this will display "The spreadsheet shows how many quest completions are needed by each party member for every quest in Habitica, in order to get all the rewards. Also shows total quest completion percentages for each party member and quest." yet upon completion of all of the steps of the script, the worksheet is blank. There are no further directions stating that anything else must be completed, so I am unsure if I am missing a step to fill in the above quoted information, as it is implied that it will autofill. Please advise.

Script version
Quest Tracker v1.0.17

Error

I received this email from the script

TypeError: Cannot read properties of null (reading '0')
at updateQuestTracker (questTracker:538:95)
at processTrigger (questTracker:222:5)
at GS_INTERNAL_top_function_call.gs:1:8

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.