Skip to content
TORNLIFE More

[v7.1.3] Books+Gym, SEs, Flying, $, Halloween

Started by DrChrono [1372430] Committee on in Tools & Userscripts.

148 replies · 15k views · thread synced · 4 days ago · View on torn.com
About this thread

Posts archived: 149 / 149 posts (100%) · the total is Torn's reply count + the opening post at the last fetch

Counted by TornLife from the archived posts.

Archived posts
149
Discussion span
→
Authority score
65 / 100
Historical score
68 / 100
Story score
65 / 100
Engagement score
89 / 100

People posting, likes and official posts are not counted for this thread yet: on threads longer than one page they come from a periodic pass over the archive, which has not covered it.

Most-liked replies

Mentioned in this thread

Tezcatlipoca [1969110] ×9 Tux [2571279] ×5 Omanpx [1906686] ×3 Dai [2596583] ×3 LouisCross [2881495] ×3 Anton [422812] ×2 Dragonspirit [508226] ×2 Beerstein [1322136] ×2 dance [1942592] ×2 flare [2195157] ×2 Blakeii [2273492] ×2 Qfiffle [2557282] ×2

DrChrono [1372430] Committee Committee

Greetings all,

Figured it's about time to drop an API-driven spreadsheet I've worked on for a long while now.

If you want something added, or find something wrong - chat, mail, or hit me on Discord @drchrono


----

The sheet can be found here

This is a Google Sheets document, and the above link should bring you directly to the option of making your own copy.

Notes:
Mobile refreshing possible thanks to Omanpx, though you will still have to run the initial "setup" on a PC.
You should use a Full Access API key for this document.

Terms of Service can be found at the bottom of the Cover tab: 


----
Gym Sheet

This utilizes the most recent formula for gym gains, and should have most (if not all) modifiers you'll run into during training.

There are separate checkbox toggles to import: your current stats; your faction's current steadfast; your max happy, property swimming pool, educations completed, faction energy drink voracity perks, and job perks. 

You may uncheck these import checkboxes and add in your own data if wished. Color coding changes depending on if data is being imported or not, as well.


On this sheet, you can utilize the following sub-areas:

  • Quick Train, with an amount of E up to 1000 (nice for Happy Jumps)
  • Gym Unlocks, where you can add your current gym's % complete and, using your E per Day, estimate how many days you have left until your next gym unlocks
  • Long Term Train Calculator, where your E & Items per Day can be iterated out up to 1096 days to show gains as well as costs
  • Quick Ratios & Ratio Planning, where you can see your current breakdown between your stats as well as plan towards a goal that either conforms to Baldr, Hank, or your own Manual ratio to see your upper stat limits to train towards


(Please note that variance in modifiers & Torn itself will change your gains per day in ways this sheet cannot account for - all measurements should be considered estimates with best practices behind them)

----
Energy Sheet

This has a checkbox to import your stats & training gain amounts from the Gym tab.

Outlines all Energy and Stat Gain items you might want to use, comparing their efficiency across multiple categories.

Determine the most cost efficient or gain efficient items, when rehab becomes prohibitively expensive, when to use stat enhancers instead of E Drinks/FHCs, and when to sell energy towards using SEs.

[Use SE Instead] and [Using Energy for SE $] areas utilize an iterative script to compare cost efficiencies until your inputs reach a threshold for when each action is fiscally wise to pursue.



Narrowing in on [One Rehab Trip] and [Using Energy for SE $]:

[image: file.garden]
For Rehab:

  • As addiction has timed interactions with Natural Decay (subtracting 20 addiction points every day around 3:30tct), the sheet ships with the max addiction (with Tol) & Xanax for 1 day's use:
  • 3 Xanax at max Toleration = 54 addiction points, minus 20 from Natural Decay = 34 addiction points from 3 Xanax each day. Adjust as you see fit, as 2.7 Xanax/day is more in line with normal usage


For Using Energy for SE $:

  • This takes a variable amount of energy you use (say, 25e for a revive) as well as the profit from that action ($845,000 per revive) and looks at the stats you would have gained training that energy vs. the amount of stats you would gain from that profit's % of an SE to tell you when that amount of energy for that specific profit is worth pursuing
  • For an easy "profit target", the [Aim for >=] cell gives you the minimum profit you'd want to make for your chosen stat's SE


Below the main energy sheet calcs, you can find a quick training vs. SE consumption calculator to check budgeting for SEs against time needed to train.

Keep in mind this is a snapshot of your current situation, and does not take into account training during your SE saving period - but it's a clever reference to return to if you have interest in starting to pound SEs like some other citizens.


These fields have an import checked to pull from the Gym tab, but please note that Happy and Gym choice are both independent, allowing for a bit more customization & comparison. The ability to import SE Cutoffs for specific items is also present for regular training, allowing you to see the specific costs of items utilized up until SEs become more effective.

This sub-area uses iterations up to 1096 days trained (separate from the Gym tab's iterations) as well as 1096 SEs taken to give you estimates. Anything over these numbers will be denoted in fields, as explained in notes in the sub-area.

Finally, at the bottom of this tab there is a quick SEs Used Calc for easy referencing regarding your stats after taking an amount of SEs, as well as the associated cost:



----
Halloween Sheet
(cheers to Tezcatlipoca for the massive work here!)

Compare every modifier available for Halloween.

Want to see how much better a revitalize weapon would be?
How much more profit using only FHCs would bring, perhaps while running Ugly Energy?

Let loose for the best event (so far).


----
Budget Sheet

Shows stock ROIs and your average income expected over time, alongside other fiscal tools.

Stocks owned are defaulted to import into the sheet. Flip this off to edit the fields yourself.

Manual input fields for both income and expense to the right of this section, which will only add to your totals when their checkboxes are selected.


To the right of everything, there is an auto-sorting ROI chart with toggles to view stock pay & costs by up to four

  • individual increments (the cost & pay per increment level), or
  • total increments (the combination of all levels' pay and costs)



Sorting has multiple options for ordering of investment options - ROI % is set initially. You can choose how you want to measure MCS & CBD via dropdowns, as well. The sheet ships with what I find the most reasonable for valuation.

Caymans, Private Islands, as well as the [ROI Sort List - Manual Entries] in their requisite areas of the Budget tab will sort themselves in this list according to your edits/data entered & modifiers selected.

For Banking, a small area under the Stocks table has two different ways of measuring your bank - a fully automated API method, or manual method - as well as a Caymans calculator (thanks Tezcatlipoca for the Caymans formula!)

  • For [Manual Bank], insert your [Amount In] & choose your [Banking Merits], check if you're using TCI, and select [Bank Length] for the readout to give you the [End Total] and [Weekly Pay] using the APR of the day from the API
  • For [Caymans], note that the [Overseas Banking] faction perk and [7* Oil Rig +10%] selections will affect Cayman's placement on the ROI Auto-Sort list to the right. A value needs to remain in the green cell for Caymans to correctly slot into the ROI sort table


 

API Logs, to the right of banking and under Manual Entries for Income and Expenses, enables lightweight log parsing. These log categories will only refresh if selected, saving calls if you do not participate in any of the listed activities. When selected, categories refresh as well as either add to Manual Income in cell N8, or add to Manual Expenses in cell R8. You can flip the Weekly Averages to either the past 30 days or just the past week, depending on if you want to narrow to recent changes in approaches or have a longer-term routine you follow.

 

Directly underneath banking lays the ROI Sort List - Manual Entries sub-area.

  • Name your source of income, place in the weekly pay, place in the total invested. ROI in Years will read out to the right
  • Entries automatically slot into the ROI Auto-Sort table for an easy comparison on investments
  • Toggle a row's checkbox to mark it as Invested on the ROI Auto-Sort table


Useful if you invest in companies, faction stock funds, et cetera.

 

To the right you can find the Private Island Rentals - Manual Entries section, where you can change the number owned, Happy amount, weekly rent, and purchase cost of the given properties, also affecting each PI's placement on the ROI Auto-Sort list. Ticking the checkbox beside each row will add these entries to your Manual Weekly Pay cell in N8 (multiplied by the Owned number), as well as highlight the option on the Auto-Sort list as Invested.

 

A Property & Rental Calculator exists as well, if you're in the market to buy or rent out a Palace, Castle, or Private Island.

  • Select pertinent modifiers for costs as well as property upgrades for happy
  • Contains a calc that takes days leased and price of lease and outputs weekly rent


 

If you would like to add a Rental's output to the Manual Entries fields, the script button in this area will take:
"[Property] - [Property Happy]" & "[Weekly Rent]" to fill out the next empty row in Manual Entries for ease of transposing your rental.

[image: file.garden]
Next up, we have Bunker Bucks calculations.

  • This sub-area takes each cache's item values as well as Bunker Bucks valuations of item + color + amount of bonuses to read out a "Max Buy Price" if you're looking to buy weapons or armor to turn in for Bunker Bucks


This "flip" should net you caches from the Bunker cheaper than buying a cache off the market (on average).


Below this, there lies a Stock Rolling table.

  • You can select the stocks, their increment level, and whether a specific stock will use the total block of increments or just the individual selected increment to group up and sell towards a "target stock" that you can choose to the right
  • Data readouts on how much extra/short you'll be for the purchase as well as how much your weekly income would change due to the "stock roll" are beneath the target stock selection
  • The option to roll stocks into Private Islands is present as well, utilizing Happy, Weekly Pay, and Cost amounts generated from the Private Island Rentals table


Useful when you want to sell easily-reacquired stocks (eg. SYM, ASS, etc) towards more "out of reach" stocks (eg. TSB). Grab the higher cost stock and then target the cheaper stocks used to roll into it, snowballing profit.


----
Flying Sheet

Easy compare for flyers.

  • Modifiers for Lingerie, WLT, and the two relevant flying books - Ugly Energy (fly longer without e capping) & Mailing Yourself Abroad
  • Toggle between Item Value and Market Prices as wanted. By default, Item Values are displayed and pulled via the OnOpen trigger you can install on the Cover tab
  • For Market Price view, please use the Refresh button (on PC) or Checkbox (PC & mobile) on the sheet
  • Compare buying items for points trading, as well as a simple '365d in the air' merit calc at the bottom
  • Utilizes YATA's Overseas Stock API to give you stock abroad with timestamps for the most recent data available


 

----
Scalp Sheet

Check out commonly requested items that are on the market for immediate deals and glanceable trends.

This sheet is not on the auto-refresh script - has to be manually refreshed, due to the amount of API calls it makes. The ability to exclude item categories is present via checkboxes above each separate category; if you uncheck one, it will grey out and not utilize any API calls, allowing you to focus specific categories you are interested in watching.


Please note:

  • Scalp cells are [2nd lowest Market Price] - [lowest Market Price] to show what you could theoretically make snatching up that lowest price item and relisting for the higher 2nd price
  • Value cells are [Lowest Item Market Price] - [Item Value] to show what items are currently going for on-market compared to the last 24h Item Value generated by Torn. Negative means current market price is below the Item's API value
  • Trend cells are [Lowest Item Market Price] - [Item Value] to show the same as Value but in a different context: How is this item moving today, is it gaining in value (positive value) or diminishing (negative value)?


----
Bank Sheet

  • Manually select your bank modifiers and compare interest across the board
  • Also includes a bank sharing calculator, with % modifying fields if you do not split evenly for bank shares
  • APR percentages at the top (1 Week through 3 Months) are the bank's base rates of the day delivered by Torn's API


Mentions: Omanpx [1906686] · Tezcatlipoca [1969110]

DrChrono [1372430] Committee Committee
You can find the CE Ranking and PA Team Composure sheet here!

New checkbox added so you can just work off one sheet for active members/inactive members team composition.


As always with these sheets - please make your own copy by going to File -> Make a Copy
[image: file.garden]


This spreadsheet has 4 sheet tabs.

The Cover tab auto-generates all your data, and can be published so your faction can check their rankings without seeing the rest of the sheets:

[image: file.garden]

To publish this, hit File -> Share -> Publish to Web

and make sure you flip to only publishing the Cover sheet.

Automatically republish should already be selected. This will ensure any changes you make from updating data are reflected on the published sheet.

On the Admin tab, you have a button to press to query the API for the applicable data. You can also choose to highlight how many PA teams you're running, and - assuming it's the highest CE people in faction - it will highlight as many rows for teams on the Cover tab, starting from the top ranked member.

You can also place how many teams you'd like to run in here, and it'll pop out a solid team composure to balance your available members based on their CE

On the Teams tab, you'll catch color-coded spots according to your faction member's roles they can fill depending on how many teams you may want to run. Kinda neat for reference, but mostly used for the team mapping on the Admin tab.

The API tab is pretty much the rest of the backend. It's where your members will query (excluding Fallen members) and post, your CE ranking will post, and it'll also copy over the Current CE to Previous CE when you update - giving you the "Rank Change" column on the cover page, so your members can see their growth at whatever interval you choose to update.

Please note you'll need the faction-given permission for faction API access to utilize this sheet. Hope it helps some leaders!
DrChrono [1372430] Committee Committee

Post three, reserved for more in the future maybe

Again - feel free to reach out with questions, for something not being correct, or for functionality additions

Be well, all

Might as well use this post as a change log:
----
16th April 2023 - Initial versions for Companion Guide (6.5) and OC/CE Ranking posted

1st May 2023 - Additional sheet for OC/CE Rank posted, allowing inactivity filtering when crafting PA teams

8th May 2023 - Companion Guide 6.6 posted; Mobile refreshing possible after running a script on PC (thank you Omanpx!)
+ Condensed OC CE Rank sheets into one with a checkbox for filtering active members for PA teams

3rd Oct 2023 - Companion Guide 6.7 dropped with Halloween added (thank you Tezcatlipoca!)

26th Oct 2023 - CG 6.71, added E jobs and point usage in so you don't have to utilize Daily Regen / Initial Stack & added in "Aim for" cell on Energy tab, for when selling your energy what a good target price is if gunning for SEs

11th March 2024 - CG 6.9, massive change log here. 100% more polish, actual iteration for SE cutoffs, better functionality

5th September 2024 - CG 6.91, thanks out to QuinnCarr for pointing out Refills needed adjusted from 25 to 30 points. Instructions here if you feel like editing the cells on your own copy of 6.9

 

16th February 2025 - CG 7.0, massive change log here. More functionality added, more tools, better ability to cannibalize scripts if you'd like.

 

10th January 2026 - CG 7.1, bug fixes, small additions, and Flying updated with Contraband items. Change log here.

23rd February 2026 - CG 7.1.1, thanks out to Blakeii for notifying the need to adjust to new stock return schema


----

Mentions: Blakeii [2273492] · Dai [2596583] · Omanpx [1906686] · Tezcatlipoca [1969110] · [v7.1.3] Books+Gym, SEs, Flying, $, Halloween

Tux [2571279]
It's closer than that for me! My gain was 159,947.44 and it estimated 159,897.86 gain/train.

I've planned out a lot of my gym gains with this. Excellent for noobies working through the gyms imo.

I'm also a big fan of the budget sheet.
Celasha [2858290]
I've been using this calculator for a few months now, and it is singlehandedly the most useful tool I've ever experienced. As always, DrChrono delivers in the best of ways. R++++++
DrChrono [1372430] Committee Committee
Edit - figured this one out. Fixed on the copy hosted above, forgot to copy over the ",perks" part of the call into the Copy from my main sheet.

Thank you!

Please download a new copy if you would like it functional, or

If you have already downloaded a copy and want to fix this yourself:
in the Apps Script, UserInfo.gs needs line 10's URL piece edited to

https://api.torn.com/user/?selections=bars,money,merits,perks
DrChrono [1372430] Committee Committee
Bump - added inactivity filter for creating PA teams on the CE rank/PA team composition sheet
DrChrono [1372430] Committee Committee
Huge thanks to Omanpx:

6.6 release includes a way to refresh on mobile via checkboxes. Set up still needs use of a PC once to create the backend for it.

Instructions are found on the Cover Sheet - please see rows / lines 12 through 15

As always, feel free to reach out if something breaks!

Mentions: Omanpx [1906686]

Shaitan [2802630]
This still wasn't working for me (not pulling Faction perks) so had a quick delve.

You also omitted calling the userInfo() in the GymEnergyRefresh.gs.

Editied it to look like below and all now works :)


function gymEnergyRefresh() {
statsAPI();
pointsAPI();
itemValueAPI();
userInfo();
}
DrChrono [1372430] Committee Committee
Sent DMs to both of you - I can help set this up if needed, I understand that the initial steps needing a PC can be prohibitive.

Chat me if you run into this issue, happy to help.