← Back to the board analyzer

Tartarus Simulator · Board analyzer · Beta

Auto Screenshot Mode

Auto Screenshot Mode lets the board analyzer keep up with your game by itself. You connect the game's log and share the game window on this page. When the log shows a move, this page takes a picture of the game and hands it to the board analyzer open in another tab, which reads the board and updates the advice. Everything happens in your browser, on your PC. Below, this page says exactly what it reads and what it sees, with the code that does each part. The code is loaded from the same files your browser runs, so it can't differ from what's described here.

Your game Beta

First, turn on the game's log

Auto Screenshot Mode takes a picture when the game's log shows a move, and the game writes those lines only once its log is turned on:

  1. In the game, press Esc and find Account Related.
  2. Click Enable Log.
  3. Log out and back in. The game starts writing its log only after you log in again.
The game's Esc menu, under Account Related: Account Center, Redeem Code, Player Service, and the Enable Log button.
Press Esc in the game: Enable Log is under Account Related.

If pictures come only when you press Take a picture now, the game's log is still off: turn it on here, then log out and back in.

Read this page first, then turn Auto Screenshot Mode on at the bottom. Until you do, nothing here can open your log or see any window.

Turn it on

In short

What your browser asks you

Nothing happens until you've done both of these yourself:

  1. Give it the log. You drag UE_game.log from the game's log folder in File Explorer onto this page, or choose it in the browser's file window (step 1 at the top lists the folders). Either way, the site gets read-only access to that one file and nothing else. The file window refuses files under Program Files, where Steam puts games by default; dragging works anywhere (or move the game). On your next visit, the browser asks again before the site can read it.
  2. To share a window. The browser lists your open windows, and you pick Torchlight: Infinite. Whole screens aren't offered. While the window is shared, the browser shows which one, with a button to stop.

Browsers never tell a website which program a window belongs to: not its name, its title or its process. So the code can't check that the window is the game. What it does check is that you shared one window, not your screen or a browser tab, and the browser's sharing bar shows you which window that is. Pick the game, and only the game is seen.

Other browsers can't follow a file on your PC, so Auto Screenshot Mode needs Chrome or Edge on a PC. Run the game borderless or windowed: in exclusive fullscreen, a shared window looks black.

How it works, with its code

Each step shows the code that does it, word for word, with its line numbers in the file. It's read from the site just now.

1. Nothing runs before you agree

When this page opens, it checks for your agreement first. Without it, the controls stay hidden, and none of the code that connects the log, shares a window or passes pictures to the analyzer is set up.

The part that takes pictures checks again on its own, every time, right before each picture. A picture is taken only if three things hold: you agreed to this version of this page, the game log is connected and being read, and what's shared is a single window. Connecting the log or sharing a window without your agreement is refused too.

2. You give it the log

dropLog takes the file you drag onto the page: one .log file, and nothing else. connectLog opens the browser's file window instead, and the site gets only the file you choose. resumeLog is for later visits: the browser remembers your choice, but asks you again before the site may read it.

3. It reads only the new lines

Once a second, the follower checks whether the log has grown, and reads only the part added since its last look. It starts at the end of the log, so nothing written before you connected is ever read. Each new line is checked against the triggers below. A line that matches nothing is dropped; a line that matches the watch pattern is shown to you on the page. It runs in a background worker, so it keeps up when the tab is hidden. However the log changes, each look reads at most the newest megabyte and passes at most 200 lines to the page, so the page never has more than it can handle. If the log is deleted, the follower waits, and reads the next log the game writes from its start. The game also writes its language in the log every few minutes (a line with sdkLang=…). The follower notes only that language code, so the analyzer can tell you when names and labels may not be read. Nothing else from that line is kept, shown or sent.

4. It watches for moves

The triggers are patterns for the lines the game writes when something happens. Each has a kind, the pattern, and a settle time. The built-in ones take a picture at: the run's objective popup; its pick of 3 instruments and each re-roll of it (also an extra pick an objective pays); the start of each day, once the new day's banner closes; after a move, when the cards come up; after an action in the cell, once it has played out; after each bite of a consume chain, and after a Cancel; after an event is confirmed (the Sewer Ratway's cell pick shows then); and the Warden's Treasure, and again once it closes. The Treasure covers the board, so the analyzer waits for it before advising a gift: press View Prison Status in the game, and the picture taken then is of the board behind the Treasure, which still waits; the gift advice uses that board. Two lines take no picture: the next day's banner cancels a picture still waiting, so an action that ends the day takes none of the banner; and the game's Speed-up button switches how soon pictures come. So it takes a picture of each screen where you decide something, and none in between. You can add triggers of your own at the top of this page, under Triggers and log lines; the built-in ones always apply as well.

When matching lines come in a burst, it waits until the log has been quiet for the settle time, so the animations finish. Then it takes one picture for the whole burst.

5. It takes one picture of the window you shared

connectWindow asks the browser to share a window, which you pick. useStream turns away a whole screen or a browser tab and stops that share at once; only the desktop app can hand it a screen, through useCrop, and only after you've allowed it (see the desktop app below). grab takes a single still frame, and only when the check from step 1 allows it. On such a screen it first asks the app where the game window is: if the game isn't the window in front, it takes nothing, and otherwise it cuts the frame to the game window before the frame leaves grab, so nothing else on the screen is read, kept or sent. In Chrome and Edge, nothing plays the window as video in between.

6. The picture goes to your board analyzer

This page lists each picture as a small preview, then hands it to the board analyzer you opened from here, in another tab. It travels between the tabs inside your browser, through the browser's BroadcastChannel, which reaches only this site's own pages. If no analyzer tab is open, the picture is only listed here.

7. The analyzer reads it into your board

The analyzer answers only after you've agreed, and reads only the pictures sent to it. The screenshot reader, running in your browser, turns the picture into a board, which becomes your board straight away, and the analyzer gives its advice. Cells the reader is unsure of are marked Check. If anything doesn't match your game, fix it on the board and press Recheck. A picture of the objective popup sets the run's objective, read from its title. A picture of the instrument pick is read as that instead: the analyzer starts a fresh run at the offer, with the three instruments it read and whether a re-roll is left, and says which to take, or to re-roll. The instruments are read by their printed names first, with an OCR engine (Tesseract) that the analyzer downloads once from jsDelivr, a public code host, and runs in your browser: the picture itself isn’t sent anywhere. Where a name isn’t clear, the card’s art is used. An instrument it's unsure of is named for you to check. Only how the reading went goes back to this page. Nothing is uploaded.

The analyzer also shows, at its top, whether Auto Screenshot Mode is running. This page tells it whether the log is followed and the window shared, whether the game is writing the lines Auto Screenshot Mode needs, how many moves the log has shown, when its last picture was taken and of what, and the game's language. It never sends the log's lines that way. While the log is followed but has shown no move yet, the bar is yellow, and pointing at it says how to turn on the game's log.

In the desktop app

Tartarus Overlay is a Windows app that runs Auto Screenshot Mode for you and shows the advice in a small card over the game, so one monitor is enough. It opens this site's own pages (this page and the board analyzer) inside the app, so everything above still holds there, with the differences below. Its code is in the site's repository, under desktop/, and each part is shown here the same way. Download it (Windows; it isn't code-signed yet, so Windows may ask you to confirm: More info, then Run anyway).

It finds the log itself

You don't drag the log in. The app looks where the game writes it. While the game runs, that's beside the game itself: Windows tells the app two things about the game: where its program file is, and whether the game (or the program that started it) runs as administrator. The second goes only into the app's debug log, because Windows cuts off a window share to an app that doesn't run as administrator too. The app learns nothing else about it. Otherwise it looks in each Steam library that has the game (from Steam's own list of its libraries) and in the game launcher's default folder, and takes the newest UE_game.log there. You can also choose a log from its tray menu, drag one onto this page, or use the button in step 1. In the app, the app itself reads that file, so it works wherever the game is installed and doesn't ask again. Only this page can read it, and only its size and the bytes it asks for. The follower above still reads only the new lines.

It shares only the game window, found by its title

A desktop app can see which window is which. Every two seconds the app looks for the window titled Torchlight: Infinite. When this page asks to share a window, the app answers with that window only, with no picker: never a browser tab or any other window. The checks above still run. A picture is taken only while you've agreed, the log is followed and the shared window is live.

Sometimes Windows won't share the game window: when the game runs as administrator, say, the share fails with "Could not start video source". Then the overlay asks whether the app may share the screen the game is on instead. Only if you say yes does it share that screen, and every picture is cut to the game window's visible area before anything reads or keeps it, and taken only while the game is the window in front. The overlay stays out of it, as it does from any capture. You can turn it off from the tray menu (Share the game's screen when Windows won't share its window), and turning Auto Screenshot Mode off here clears your answer.

On this page, the app does what you'd do by hand: once you've agreed, it connects the log it found and shares the game window, only while the game runs. Your Stop following and Stop sharing buttons still work.

One agreement for the app

You agree once in the app. It remembers which version of this page you agreed to, so it doesn't ask again when it starts or updates. If this page's agreement version changes, it asks again. Turning Auto Screenshot Mode off here turns it off for the app.

A record of your last runs, on your PC

Unlike the browser, the app keeps a record on your PC, so you can look back at a run from its tray menu (Review the record). It holds each picture the analyzer was handed, what the reader made of it, the board and the advice, and the changes you made on the board. It keeps your last 5 runs and deletes older ones. (A test build started with --dev keeps up to 1 GB instead.) The record stays in the app's folder on your PC and is never uploaded. Turn it off in the tray menu: Record every board and advice. The app also keeps a short log of what it did, such as the game starting and closing, pictures taken, readings and advice, for troubleshooting. That log never holds the game log's lines or a picture.

The overlay only shows what the analyzer's results say, and presses the analyzer's buttons for you. Boards are shared and reports sent exactly as on the website, by the website's own code: the board-sharing switch under the analyzer's ask button still decides.

Check the files

These are the files shown above, as this site serves them now, with each file's SHA-256 fingerprint. A copy from GitHub with the same fingerprint is the same file, byte for byte.

FileWhat it doesSHA-256

Turn it on

This is agreement version 5. If what Auto Screenshot Mode does changes, this page asks you to read it again before it turns back on.