Read a side's log
logsRetrieve trailing lines from tModLoader log files, optionally filtered, to diagnose failed launches by reading current or previous run's entries.
Instructions
Tail one of tModLoader's logs, optionally filtered.
Args:
name: Which log — see log_files for what this install actually has.
client.log and server.log are the game; Launch.log and the
environment-*.log pair are written by the launcher, which is where
a run that died BEFORE the game started says why.
previous: Read the run BEFORE this one. tModLoader zips the previous
run's logs into Old/ when a new run starts, so after a failed
launch and a retry the failure is in an archive and the live log
belongs to the retry.
contains: Keep only lines containing this substring, case-insensitively.
Applied to the WHOLE log before the tail, so this returns the last N
MATCHING lines rather than the matches among the last N.
lines: How many trailing lines to return. Zero returns none; a negative
count is refused rather than guessed at.
Useful when a launch fails: the reason is usually in a log and not in
anything the trigger protocol can reach, because the game never got far
enough to poll. Which is also why previous exists — the obvious thing to
do after a failed launch is launch again, and that rotates the evidence.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | client.log | |
| lines | No | ||
| contains | No | ||
| previous | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||