jay
cbb105fe49
fix(command): 🚸 make bot address regex (prefix) more lenient
...
Should also accept server commands now on address
3 years ago
jay
5b3804893b
feat(command): ✨ fix to show web (including extra [MODE]) messages
...
There's no way to remove `bot.addChatPattern`, so only does once on load
3 years ago
jay
3686bab167
fix: 🐛 fix plugin reload for multi-file/dir based plugins
...
Now, it also (un-)loads the whole plugin (sub and master).
This appears to be the most stable option.
Loading behaviour is unchanged from before (load only top level plugin).
However as a precaution, loading tries to unload bad plugins on error.
This helps to not end up in a bad state during reload.
3 years ago
jay
e0c477a46f
feat: 🔨 make `fs.watch` recursive, so it `reloadplugin` works also on directories
3 years ago
jay
ae1f7cf269
feat: 🔧 extract the hardcoded admin and mod list out into environment variables
3 years ago
jay
d001280383
fix: 🥅 fix a plugin loading error
...
While reloading, plugin cache may not be deleted.
This happens when a loaded plugin encounters an error during reload.
This causes a deadlock in the unloading code.
So make sure cache is always deleted:
- ignore when an `unload()` function doesn't exist
- delete cache even if there are no `exports`
3 years ago
jay
f50e388c39
feat: 🔊 fix path in plugin reload log so that it actually works
3 years ago
jay
6b79f1fc60
refactor(plugins): ♻️ change plugin load order
3 years ago
jay
22490f7ec1
fix(command): 🐛 fix bot address regex returning undefined
...
Waits till spawn to make sure `bot.username` is definitely initialized
3 years ago
jay
0757776d8b
feat(command): 🎨 make botaddress prefix and regex more flexible and configurable
3 years ago
jay
33c4233223
feat(statemachine): 🚧 first draft of new xstate based statemachine implementation
...
Replaces the old statemachine.
Done so far:
- Basic command interface
- Machine saving and loading
- Sample dummy machine
3 years ago
jay
288b7045b6
feat: ✨ add informer plugin to show info
...
Data and information plugin.
Expose methods in mcData with acceptable ux.
Also central place for all kinds of debug features.
3 years ago
jay
94574a4296
refactor: ♻️ reorder plugin loading
...
Load in order of simplicity and dependance.
TODO: Use `bot.waitForChunksToLoad`:
Split plugins based on whether it requires blocks to be loaded or no.
3 years ago
jay
086251bce6
feat: add a basic feature to rejoin on server restart
3 years ago
jay
bf45a53f08
refactor: ➖ remove gameplay
...
temporarily remove gameplay until it is fixed and more stable
miner plugin won't work now
3 years ago
jay
47a944fe2a
fix: 🐛 compat: don't use `?.` for compat with older node.js
3 years ago
jay
de0af4d2ac
feat: 🚀 add and use `dotenv-packed`
...
Use dotenv for more convenient credential management
3 years ago
jay
73d5f43ad3
feat: ✨ actually enable mover and eater plugins
3 years ago
jay
4f1e510386
feat: 🎉 init new repo
...
Dump of current working bot.
Warning: somewhat messy code! Lints haven't been run, no tests, etc.
3 years ago