DCSServerBot Versions Save

Manage your DCS World servers via Discord with lots of extensions and possibilities

v3.0.3.10

4 days ago

Enhancements:

  • :new: Mission: New "usage_alarm", with parameters "min_threshold" or "max_threshold" where you can define, if you want to be informed, if either a minimum or maximum number of players is reached on your server.
  • install.py now supports -u (user) and -d (database)

Changes:

  • :100: New Logging / new look & feel
  • :warning: CJK-fonts are no longer downloaded by the bot but have to be installed manually (see README).
  • Rewrite of the SRS plugin
  • Timeout increase and small refactoring on server registering
  • Cloud logger is a root logger now
  • Server registration changed, to enable the detection of self-started servers with the wrong -w parameter (this is not wanted but is better than just ignoring them).
  • Status channel can be -1 now to disable any status embed
  • Voting: added player name to audit message
  • upped some libs (security fix for aiohttp hotfixed already)
  • Async handling for nodes improved

Bugfixes:

  • InstanceProxy initialisation of locals was (still) wrong (hotfixed)
  • render_extensions(): changed condition in which extensions are rendered
  • Secret dir was not created in all cases (hotfixed)
  • Postgres ports could be None (hotfixed)
  • SRS detection works correctly now, see changes.
  • Monitoring: possible race condition on clusters
  • Avoid multiple runs of register_local_server in clusters
  • Error in /node online
  • Scheduler: delayed start might not have worked correctly
  • CleanupService: no path expansion implemented for directories

To use the new player number alarms, configure your mission.yaml like so:

DEFAULT:
  # ...
  usage_alarm:
    min_threshold: 30   # send a message, if less than 30 people fly on your server
    max_threshold: 10   # send a message, if more than 10 people fly on your server
    role: DCS Admin     # the role that should be pinged
    channel: 1122334455 # the channel to send the ping in (default: admin channel)

:warning: Attention! You need to decide for EITHER min_threshold OR max_threshold. You can NOT use both together. There will be only ONE alarm per mission for now, until someone tells me how you guys want it to be different.

v3.0.3.9

1 week ago

This release has some nice additions for you SRS and LotAtc users:

Enhancements:

  • :new: LotAtc: Active information about GCIs on station to players in your server in the chat, in-game chat and via popups.
  • :new: New plugin SRS to add support for SRS slot blocking and more display options for players.
  • :new: You can now specify a voice channel per server and enforce the usage of this voice channel for people.
  • :new: Scheduler Service: added cmd action to run shell commands on schedule
  • :100: Added schema validation to all config files.
  • MizEdit now supports uploads of whole directory structures into a mission (e. g. kneeboards)

Changes:

  • :warning: The TOKEN, DB password and (optional) DCS password will now be automatically removed from your config files and put to a secret place. Use run.cmd -s to reveal them.
  • Mission status embed now shows the used slots per side.
  • SRS: added move to spec on no-SRS use
  • Audit message to /node shell added
  • Timeout to /node shell added

Bugfixes:

  • /motd did not work correctly (hotfixed)
  • Voting: misbehaviour, if no voting member was left after a voting was finished. (hotfixed)
  • NodeProxy: 2 remote calls had missing parameters (hotfixed)
  • move_to_spec did not print the reason
  • /mission rollback did not write serverSettings.lua correctly
  • Unnecessary admin ping when exe was closed manually.
  • /dcs install and /dcs uninstall always asked if servers should be shut down, even if none were up
  • /node add_instance did not work reliably on servers without any instance
  • update.cmd: Commandline args were overwritten in update.py

Sample Config for new SRS Plugin

DEFAULT:
  message_no_srs: You need to enable SRS to use any slot on this server!
  enforce_srs: true   # block slots until SRS is activated
  move_to_spec: true  # move people back to spectators, if they leave SRS (only if enforce is true)

:warning: The move to spec might move people to spectator that only lost connection. Handle it with care.

You have new commands: /srs list => show active people on SRS with their radios /gci list => show active GCIs on LotAtc /gci info => shows information about a specific GCI The GCI commands are available in the in-game chat also.

Enforcing of voice channels works like so (servers.yaml):

MyFancyServer:
  force_voice: true  # people will be forced in this voice channel, if they are active in any other voice channel. The server access will be blocked until they move themselves in any voice channel!
  channels:
    status: 112233
    chat: 334455
    admin: 556677
    voice: 998877 # I am new!

v3.0.3.8

1 week ago

Enhancements:

  • :new: Optional plugin "LotAtc" added to allow transponder file uploads
  • :new: New autorole handling. You can give people a specific role when they join, they are linked or they are online on your servers to show them as a separate role in your Discord server. There can be different roles for different servers.

Changes:

  • bot.yaml: autorole changed from string to dict (auto migration)
  • Rewritten /link, /unlink and /linkme handling
  • :100: Disabled QuickEdit in CMD to avoid unwanted bot stops due to mouse marks
  • Delete all non-verified links if a user is linked manually
  • /scheduler maintenance + /scheduler clear smart auto-completion added
  • Schema validation for json uploads added

Bugfixes:

  • Race condition on updates
  • help command did not work if other commands were registered
  • show_password false did not show any password anymore but should show ****
  • update did not work when git was installed but no repo was there
  • ZIP-updates can create rate limits on GitHub
  • Possible error on instance auto-completion if serverSettings.lua wasn't there
  • Some fixes in /linkme
  • Possible deadlock in /unlink
  • /info verify and unlink did not affect squadrons
  • Documentation: Error in description of the footer element

:new: LotAtc Plugin

You need to have the LotAtc extension activated for your server and then add "lotatc" to your opt_plugins like so:

opt_plugins:
  - lotatc

:new: Autorole Handling

You can define the new autoroles in your bot.yaml or servers.yaml. I changed the structure a bit, the bot will migrate you over if you had used autorole in the past, but you still might want to look into it, as the new options are much more flexible: a) bot.yaml

autorole:                                       # Automatically give roles to people, depending on conditions (see below). The roles need to be set up in your Discord server.
  on_join: Member                               # Give anyone the "Member" role, if they join your Discord.
  linked: DCS                                   # Give people that get linked the DCS role.
  online: Online                                # Give people that are online on any of your servers the "Online" role.

b) servers.yaml

My Fancy Server:                # Your server name
  autorole: Fancy Players       # Optional: give people this role, if they are online on this server (overwrites autorole[online] in bot.yaml!).

For "online", you can use either the bot.yaml variant or the servers.yaml variant, or even both, where the servers.yaml entry will overwrite the bot.yamls one for this specific server (so in the above example, an online player would get the role "Online" on any of your servers but "My Fancy Server", where they would get the "Fancy Players" role.

I hope you enjoy the new version!

v3.0.3.7

3 weeks ago

Attention: This version has a small bug with the autoupdater. You can fix it by applying the attached 3.0.3.7 Updater Fix.zip. Just unpack it over your installation and you are good.

Enhancements:

  • Added "discord" tag to servers.yaml to reserve whole servers for specific (linked) members.

Changes:

  • /squadron add, /squadron edit, /squadron list added
  • :100: Squadrons can now have an icon-image
  • /squadron join can be disabled now (see documentation)
  • :100: /squadron create will auto-add people that have the respective squadron role to the squadron
  • Manual changing of squadron roles in discord will remove/add people from/to the respective squadron
  • :100: Greenieboard: Squadron support added
  • Greenieboard: any WO will give 1 point, according to SME consultation (Moose.AIRBOSS gave negative points here for whatever reason)
  • Warn users, if cleanup.cmd did not manage to delete the .dcssb directory
  • Added "opt_plugins" howto-documentation to all optional plugins
  • max_retries parameter added to the database connection to allow multiple retries on startup
  • audit messages added to /node online, /node offline
  • Commands are now mentioned in many outputs, including help and many more
  • The installer can now change the dcsserverbot password, if it got lost.
  • :100: In-game help will only display commands that can be used.
  • New events onMemberLinked / onMemberUnlinked to provide better handling of these events throughout multiple plugins.
  • Squadrons with auto-roles will now auto-add users that were linked (and removed if unlinked)
  • Added pip to the requirements to keep it updated.

Bugfixes:

  • DCS update message wasn't sent as audit event anymore
  • Highscore did not show decimal values for K/D, MeP and MwP on some database versions
  • Wrong formatting "todayly" in periods fixed
  • Olympus: all numeric passwords did not work
  • luadata: merged one bugfix from release version
  • /prune data with 1 year timeframe raised an error
  • Added verification to role checks (for auto-match)

You get the audit messages back on DCS updates with this version. Sorry for that mishap. And you might try out the new /help command that gives you mentionable links to all commands. Same for any command that prints something like "Please run /aaa bbb"

If you want to disable the /squadron join command, you can do that by adding these lines to your userstats.yaml:

DEFAULT:
  squadrons:
    self_join: false # enable self-join for squadrons (default: true, otherwise you need to get the associated role)

This does only make sense, if you have a role associated with the respective squadron. People will then join / leave a squadron automatically, when they get the role (or the role is being removed).

v3.0.3.5

1 month ago

New version 3.0.3.5 brings you squadrons as a small but yet long awaited feature.

A "squadron" can be created with a short description and a possible auto-role with /squadron create. People that are linked can then join the squadron with /squadron join. If you have set an auto-role, they will get it on join and it will be revoked on leave. There are no locking mechanisms atm, so people can join any squadron they want. You can then use squadron:<name> as a period filter option in your /highscore or /serverstats displays. Atm you can not stack periods, meaning, you can only get the total highscore for a squadron, but not the daily or weekly one. That might need some additional tweaking if needed.

Enhancements:

  • :new: Added squadrons support
  • /serverstats, /highscore have squadron support now

Changes:

  • :100: New alert and warning format
  • Faster crash detection on server startup
  • /cloud status: Added better status check
  • REST: optional prefix added
  • Autorole will work with /link and /unlink now also ("linkme")
  • better error handling on wrong service config files
  • MusicService: parameter pause_without_players added
  • Send timeleft on join, if server is about to restart
  • Improvements in run.cmd / install.cmd
  • /mission add can now "launch later"

Bugfixes:

  • Typo in run.py (hotfixed)
  • RealWeather: typo when using ICAO in filenames (hotfixed)
  • Scheduler: in-game -timeleft did not work with multiple restart lines
  • /prune did not work for members
  • /prune die only prune the first plugin
  • MusicService: popups go to the correct coalition now
  • /mission add sometimes set wrong start index
  • Scheduler: next restart schedule was not fulfilled on start later
  • Scheduler: no warning to users, when max_mission_time was reached (instead of mission_time)

v3.0.3.4

1 month ago

Happy Easter, dear DCSServerBotUsers, or whatever you might celebrate these days!

A new version 3.0.3.4 has just dropped, bringing you besides some smaller add-ons and some bug fixes a long awaited feature "timeleft", which displays the remaining time until the next mission restart in the server status embed, a new command /server timeleft and a new in-game command -timeleft.

Enhancements:

  • :100: /server timeleft and in-game -timeleft added
  • :100: Server status embed now displays the time until the next restart.
  • RU and ES locales added (WIP), credits to Angry Russian Simmer, TheLT and Deliverator!
  • /prune can now prune (old) server data from the database also
  • Added a quick database check on startup.

Changes:

  • added dynamic service loading to support custom-made services
  • Scheduler: changed the way, warnings were issued
  • Lardoon: reworked the scanning of Tacview directories to avoid doubled scans
  • The bot will pause now on major errors to make them viewable.
  • Renamed DCS.server to DCS.release_server in all samples (whoever suggested that to me last week, you were right)
  • some more robust onPlayerStart/Stop handling
  • Code refactorings

Bugfixes:

  • DSMC: disabled DSMC still searched for a the DSMC configuration
  • Userstats: allow mission wildcards and small l&f change to the output. (Hotfixed)
  • MOTD: Nudge did not work with multiple messages
  • RealWeather: lock added to not allow multiple RW calls in parallel.
  • In-game -restart did not check the time value
  • Scheduler-Service: render action only works on master nodes
  • Scheduler: warn times were cleared in combination with populated: false and max_mission_time (hotfixed)
  • /info raised error with unlinked Discord accounts
  • /help could not print "mission" plugin, as there were too many commands in
  • long time display missed blanks between hours and minutes
  • some service calls were not sent with the correct service name but ABCMeta instead
  • /dcs update did not select the correct branch for the modular server

I hope you enjoy this little update and the bot in general!

v3.0.3.3

1 month ago

Enhancements:

  • Localisation added (WIP, finished release will be announced separately)
  • MizEdit/modify now supports "delete" and "merge"
  • OvGME extension added to display the required modules in your missions in the server status embed
  • /player exempt added to put players on the AFK-exemption list
  • /dcs update can now get a branch to update to the release version of DCS.

Changes:

  • /info, /find moved from userstats to mission
  • /player info alias added for /info
  • /player find alias added for /find
  • :100: Reworked the /mission info display so that the embed does not use that many elements.
  • Scheduler: can now send individual messages for warnings (see documentation)
  • Smart ban system improved by adding IPs of login attempts to the temp ban list.
  • :100: RealWeather now supports custom ICAO codes in the mission name.
  • Implemented pretensestats for multinode
  • added some more error handling for FunkMan integration
  • role uploads are smaller batches now, to avoid buffer overflows.
  • better player detection (use more UCIDs instead of player IDs)
  • Better support for periods in statistics commands
  • async changes in listeners to improve performance
  • Added some IDE hints to avoid unnecessary warnings
  • Lots of code refactorings

Bugfixes:

  • Hung detection of servers did not work, if serverstats was enabled (hotfixed)
  • /player afk did not work (hotfixed)
  • Don't add more than 25 fields to the status embed.
  • Do not remove mission files from serverSettings.lua that either exists in Missions or in Missions\.dcssb
  • Read the correct mission file after uploading it through discord
  • Some missing config directory overwrites fixed.
  • /dcs ban: ucids were not checked before ban
  • bans were not sent reliably to DCS on server restart (hotfixed)
  • bans are uploaded in smaller batches now, to avoid buffer overflows on servers that have many bans.
  • bans_hist table wrong primary key
  • command overwrites did not work
  • Prevent agent nodes from doing a git pull, if autoupdate is disabled for them (hotfixed)
  • Mission upload issue with autoscan enabled.
  • Database errors should allow for a reconnect.
  • Race condition with statistics on fast slot changes fixed.
  • Install: typo in scheduler.yaml caused overwrites of scheduler.yaml on agent installs
  • GameMaster: several issues with campaign creation

v3.0.3.2

2 months ago

Enhancements:

  • Added /node statistics to show the pool usages on your nodes.
  • Lardoon: allow a separate tacviewExportPath
  • :100: Support for DCSOlympus v1.0.4 (not yet released)
  • Punishment: Ban history can now be presented with /infractions
  • autorole added to give people the DCS role on join or after linkme

Changes:

  • :100: Reworked whole intercom handling between nodes, much lower latency now!
  • Several changes to subprocess handling.
  • Introduced a new async database pool.
  • Migrated 90% of all queries over to async.
  • Added some more threading / async handling for long-running stuff.
  • OvGME: better detection of package structures
  • :warning: DCSSB now ensures unique mission names in your serverSettings.lua
  • :100: DCS is started minimized now (can be disabled in nodes.yaml by DCS/minimized = false).
  • Dashboard: Color rework
  • Dashboard: You can configure your own colors now
  • Timeout handling in DCS event loop added
  • Improved database error handling
  • DB pools on slow systems have a timeout of 60s now.
  • PID file will be stored in the bots installation dir now.
  • Moved the call to the updater further back in the chain, to avoid issues with "process already running" on slow machines.
  • Extensions: some changes in startup / process detection of Lardoon, Sneaker, Olympus, SRS
  • SlotBlocking: addUserPoints() will add to deposit, if multiplier is set.
  • SlotBlocking: addUserPoints() can have a reason now.

Bugfixes:

  • FunkMan: wrong image for 2.5 pts
  • /serverload wrong aggregation for nodes
  • Scheduler did not rewrite serverSettings.lua on mission changes, when server was shut down (hotfixed)
  • Punishment: exemption list was ignored on discord roles (hotfixed)
  • affinity can be a single integer (one core binding)
  • /node list was not ephemeral in non-admin channels
  • Collision detection after spwan fixed. Collision kills after spawn will not be punished also.
  • MizEdit did not randomize nested lists anymore
  • OvGME fixed recreation of install log
  • autoexec.cfg could not be read when different net init style was used.
  • SRS minimized does indeed start minimized now (default: true).
  • Ignore glyph warnings in matplotlib
  • check_for_unban() failed due to wrong parameter passing
  • If listStartIndex was wrong, Server.set_status() could fail.
  • Userstats: Connection was not opened before write in one case
  • Unwanted servers were started after an update.
  • SlotBlocking: Possible race condition in payback.

v3.0.3.1

2 months ago

Small bugfix update. I made some small mistakes in the last version, which for instance did not bring up your greenieboards properly anymore. And as I was working on the next version already, you get some of the new stuff also.

Enhancements:

  • New start parameter for run.cmd -c <config-dir>
  • You can now configure which roles are allowed to upload missions or config files and disabled the upload of either of them at all.

Changes:

  • :warning: Moved samples from .\config\samples to .\samples
  • Neutral coalition handling added (wip)
  • Better messages on auth server failure (you have to catch them, when they are hot)

Bugfixes:

  • Node does not start as master if abandoned master is listed in the cluster table with update_pending true
  • Slotblocking: new payback system only worked if restricted planes were configured
  • Backup: database URL was only read from main.yaml, not from nodes.yaml
  • Some UTF-8 encodings missing
  • Some SQL queries returned wrong results now because of a former change.
  • Documentation update: moved missions_dir from servers.yaml to nodes.yaml

v3.0.3.0

3 months ago

Overall Changes

For Multi-Node changes and CreditSystem enhancements, please see below.

Enhancements:

  • The bot now writes a minimum options.lua, if non exists
  • /group popup added
  • Temp-banning IPs of banned players for the duration of the server session

Changes:

  • :warning: /server startup sets maintenance flag to FALSE per default now.
  • Rollback CTRL+C handling of the console
  • All internal discord role handling is numbers now
  • Performance improvements, lua and database
  • Bans and Role uploads are batch uploads now
  • Collision detection now protects the victim also
  • Added trackfile downloads to admin.yaml
  • Moved lots of Server methods to remote calls to avoid sync issues on multi-node.
  • Voting: optional welcome_message added
  • All database tables are UTC now
  • :warning: SlotBlocking: renamed use_reservation to payback (auto-migration)
  • SlotBlocking: Lua patterns should work now with unit_types, unit_names and group_names
  • Slotblocking: error when VIP was not set
  • :100: CreditSystem: new option to support multiplier to reward landings (only, if payback is enabled)
  • Rollback of player chat message color
  • /dcs unwatch now has auto-completion
  • /info, /credits list and /penalty show relative discord timestamps now
  • Cluster: changed heartbeat to 5s
  • Changed version check to a more robust one throughout the code
  • Small updates in /node upgrade
  • :warning: Check added, so that run.py can only be started once for the same node to avoid race conditions on restarts / upgrades.
  • Missing server channel configs will not make the bot fail to start
  • /server config can change the server port now also
  • /server config works on non-initialized servers
  • Installer: You can now enter a separate DCS path, independently on which ones were detected by the bot.
  • Installer: Wrong master DB password entries will not crash the installer
  • update.cmd does not auto-launch the bot anymore

Bugfixes:

  • Autoupdate-check without git executable in the PATH failed
  • Error in /server config (interaction already responded)
  • install did not write the correct DB URL in agent nodes
  • Punishment: int roles were not passed correctly to check_roles()
  • DCSServerBotUtils.lua error with os.clock()
  • Interaction responded error on /link
  • New Alert role did default to DCS Admin, but not to what DCS Admin was probably set to.
  • Mission: several issues in onGameEvent
  • Version was not updated in the cluster table, if the update function of the bot was not used but git pull
  • /node add_instance [template] should have been optional
  • /doc generated double // on slash commands
  • /doc did not generate the correct lists for the DCS role
  • Userstats: campaign filter did not take campaign servers into account (hotfixed)
  • Migrate did ask for the central admin channel on every agent node
  • Mission: chat messages were doubled (hotfixed)
  • Workaround for DCS disconnect bug implemented.
  • Userstats: documentation for mission_end was wrong
  • /modulestats did not work with new campaign filter
  • Some issues on time conversions
  • Wrong "server died" message on multiple server startups
  • Serialisation of messages to DCS might have lacked precision on list of long integers
  • remote call to register_local_servers did only register the servers if they were not registered on the agent already
  • /serverstats weird graphics due to missing ORDER BY
  • instance home was not initialized correctly for remote nodes
  • Pretensestats: Documentation fix (contribution BevanSin)
  • Punishment: missing exception handler could have caused hangs
  • MizEdit: selections like [1,2] did not work
  • Double-registration on client nodes fixed.
  • Greenieboard: Added WOFD to greenieboard.yaml
  • Mission: auto-unban should be based on UTC now

:warning: Attention Multi-Bot-Users! :warning:

The bot now has a detection if the same nodes runs on the same machine. Unfortunately, if you run multiple bots for multiple communities on one machine, it does not take that into consideration. The easiest one is to create different node names (which would be preferable anyway). I for instance run 3 nodes on my server: run -n MERC run -n JDS_DE01 run -n CB

You only need to change the node names in your nodes.yaml and scheduler.yaml (or in any config you have them, should only be those two) and you only need to do that in the above mentioned case.

CreditSystem Changes

To give a bit more insight what you can do now with the CreditSystem, you can reward people now for proper landings. It works in combination with the former "use_reservation", which was renamed to "payback" with this release, as it is more self-explaining, what it does (I hope so at least). The system is as follows:

a) Payback If you enable payback (payback: true) in your slotblocking.yaml, you can give people their money back that they paid for a plane. The money will be taken on takeoff and will be refunded on landing. This is more or less how it worked before but it is taken on takeoff and not on birth now. Keep that in mind, if you have airstarts!

b) Multiplier With the new system, you can create a multiplier in your creditsystem.yaml. The default is 0 => no multiplier. The multiplier determines, how many points someone will get in addition on a proper landing. So with a multiplier of 1, people get the same amount of points (aka credits) awarded that they got already during that sortie, if only they bring back their plane. 2 means double award, means 3x the points on one sortie.

Enjoy the new system and credits to Enigma for the idea!