Easily post TowerFall session stats and replay gifs to Slack.
Not tested on Windows or Linux, but might work.
- Familiarity with the command line
- Node.js installed
- npm install -g towerfall-slack
- run
tf-configure
and follow the prompts. Press enter to keep the default or existing value shown in parentheses.
You will also need to add custom emojis for all the archers. Each one
should follow the format :tf-color:
.
-
tf-watch-stats
Start watching for changes to your tf_saveData file. If all you want to do is post stats to Slack, you'll be fine running the script with no options. For more advanced usage, the following options are supported:
-f
or--save-to-file
- Save match data and accumulated summary data to a file. This file is the source of the stats posted to Slack.-d
or--save-to-db
- Save match data to a database. This is optional, and not necessary for posting to Slack.-a
or--append
- If using the-f
option, append to the existing file instead of overwriting it
If no options are provided, the script will save changes to a file, overwriting it if it already exists. If you wish to save match data to a database, you must first run
tf-db-configure
. -
tf-post-stats
This will post all the stats you've accumulated since running
tf-watch-stats
. It will then delete the session stats file, making way for the next session's stats. If there has been no activity, it will not post anything. -
tf-watch-replays
This will start watching the replay directory and upload any new replays that appear in it.
-
tf-post-replays
This will post your existing replays. It takes two optional arguments which define a range of replays to upload e.g.
tf-post-replays 22 33
will upload replays 22 through 33 inclusive. Omit the second argument to keep uploading until there are no more replays. Omit both to upload everything. -
tf-db-configure
Set database configuration. Only necessary if using the
-d
option withtf-watch-stats
. -
tf-configure
Set required configuration options.
You may notice that the posted stats differ slightly from those that can be viewed in game. The main reason for this seems to be that the tf_saveData file counts a self kill as both a death and a kill. Although total self kills are tracked, they are not tracked per archer, so there is no way around this.