Skip to content
TORNLIFE More

Chain Watch Script?

Started by GingerBeardMan [2532521] on in Tools & Userscripts.

13 replies · 1.79k views · thread synced · 5 days ago · View on torn.com
About this thread

Posts archived: 14 / 14 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
14
Discussion span
→
People posting
6
Likes on archived posts
12
Authority score
37 / 100
Historical score
19 / 100
Story score
36 / 100
Engagement score
66 / 100

Most-liked replies

GingerBeardMan [2532521]
Is there a script or chrome extension that will do something similar to Torn PDA's Chain Watch mode for desktop use?

Set a time and play a sound/flash/buzz when the chain reaches it? Maybe also makes the timer on the faction chain report page larger, rather than the tiny ticker under the hit count?

I looked around and didn't find anything similar. I wish it was a TornTools feature, but alas, doesn't appear to be so.
GingerBeardMan [2532521]
For sure. I was thinking it'd be nice to have as a "failsafe" option. Not to be used to replace actively watching, but an "oh shit I got distracted on my other monitor" type thing. Added layer of protection.

Use in non-halloween chains when the API is more reliable also would be a benefit. Just couldn't find anything publicly with a cursory search through the forums.

Thanks!
Shannon [2789996]
Violent monkey, you can write your own.

IIRC, rules are that your script isn't allowed to send requests to the server without user intervention, but you can easily use:

document.getElementsByClassName('bar-timeleft___/* element code goes here, use inspect element on your browser to find it*/')[0].innerHTML

to extract the string containing the minutes and seconds of your chain timer.

window.setInterval( () => myFun(), time) gets you the check action repeated every "time" milliseconds.
GingerBeardMan [2532521]
My question is though, how would it be scripting abuse if TornPDA does the same thing? I just want the functionality that is already built into an authorized app available in browser from my desktop.

I'm not trying to break or circumvent any rules, I'm not trying to tell it to make an attack for me, I'm just asking it to monitor the chain timer (which TornPDA, YATA, etc also access and do so we know that's legal) and give me an audible alert when it falls below a certain threshold.
Shannon [2789996]
I'm annoyed because I finally turned on ViolentMonkey due to someone's request that I chainwatch for them, and now I'm getting captcha-ed because of my BYO chain watcher script.

By the way, the easy way to get something to play would be (new Audio(url) ) .play()
GingerBeardMan [2532521]
Ahhh! I dug through Torn Tools, but stupidly didn't look into notifications. I was looking at general, sidebar, API, and didn't see it. They hid it from me! Thanks!
Caio [2488372]
thank you;
only had changed the line 7 to
// @match *www.torn.com/*
and started work, seems was restrict to rules page only, not sure if was intentional, but eh; works great, thank you!
Ahab [1735214]
Ah cheers yeah it was cause it would go off for every tab you have open which sucks balls, I think I added something to make it not do that and forgot to change the match at the time.