docs: explain about addons and sections

This commit is contained in:
əlemi 2023-11-20 19:27:37 +01:00
parent 783a619bae
commit 8101a255ad
Signed by: alemi
GPG key ID: A4895B84D311642C

View file

@ -16,6 +16,7 @@ an hackable headless Minecraft client, built with [aiocraft](https://git.alemi.d
### as an application ### as an application
`treepuncher` ships as a standalone CLI application which you can run with `python -m treepuncher` `treepuncher` ships as a standalone CLI application which you can run with `python -m treepuncher`
* create your first addon (for example, a simple chat logger) inside `./addons/chat_logger.py` * create your first addon (for example, a simple chat logger) inside `./addons/chat_logger.py`
```py ```py
from dataclasses import dataclass from dataclasses import dataclass
@ -42,6 +43,8 @@ client_id = your_microsoft_authenticator_client_id
client_secret = your_microsoft_authenticator_client_secret client_secret = your_microsoft_authenticator_client_secret
code = microsoft_auth_code code = microsoft_auth_code
; you must specify the addon section to have it loaded,
; even if it doesn't take any config value
[ChatLogger] [ChatLogger]
prefix = CHAT |:: prefix = CHAT |::
``` ```