Stonks/README.md

65 lines
1.6 KiB
Markdown
Raw Permalink Normal View History

2021-07-06 21:44:44 +00:00
# Stonks
Stonks is an app that tracks player statistics in a Minecraft world and makes them available via an API and a web interface.
## Installation
2021-07-07 02:58:58 +00:00
Download the latest `stonks.jar` release, as well as the `stonks.config.sample` file. Copy both files to a folder on your server.
2021-07-06 21:44:44 +00:00
Edit the config file (see different configuration option below) and rename it to `stonks.config`.
Run Stonks from the command line:
```
2021-07-07 02:59:57 +00:00
java -jar .\stonks.jar
2021-07-06 21:44:44 +00:00
```
Profit!
## Config file
```kotlin
databaseBaseDir=./databases
databaseName=statistics
h2StartWebServer=false
h2tWebServerPort=8082
h2TcpServerPort=9092
apiServerPort=7000
statisticsUpdateInterval=900000
minecraftStatsFolder=./saves/world1/stats
```
### databaseBaseDir
This is the relative path to where Stonks will store it's database files.
### databaseName
This is the name of the database Stonks will use.
### h2StartWebServer and h2tWebServerPort
If set to true, this will start a web interface to view the contents of the database, available at `localhost:{h2tWebServerPort}`.
### h2TcpServerPort
This is the port the database's TCP port will be available at, used internally.
2021-07-07 03:00:25 +00:00
### apiServerPort
2021-07-06 21:44:44 +00:00
This is the port on which the Stonks web interface and JSON API will be available at.
### statisticsUpdateInterval
The frequency, in ms, at which the statistics will be updated.
### minecraftStatsFolder
The path to Minecraft's stats folder.
## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.