From 9555cbc19ed0d3ca4eaa48ab587d73f0a94d6da8 Mon Sep 17 00:00:00 2001 From: Samuel Walladge Date: Fri, 29 Dec 2017 14:50:58 +1030 Subject: [PATCH] more work on config.toml --- piqueserver/config/config.toml | 124 +++++++++++++++++++-------------- 1 file changed, 71 insertions(+), 53 deletions(-) diff --git a/piqueserver/config/config.toml b/piqueserver/config/config.toml index c5f75c5d9..786969847 100644 --- a/piqueserver/config/config.toml +++ b/piqueserver/config/config.toml @@ -1,7 +1,5 @@ - - - +# TODO: store config here about location of maps/scripts/game_modes/etc as well [info] @@ -18,7 +16,8 @@ motd = [ # info displaying when user types the /help command # if not defined, /help will display a list of available commands -# TODO: document string interpolation allowed +# String interpolation is allowed. Possible values are: +# 'server_name', 'map_name', 'map_author', 'map_description', 'game_mode' help = [ "Server name: %(server_name)s", "Map: %(map_name)s by %(map_author)s", "Game mode: %(game_mode)s", @@ -33,22 +32,19 @@ rules = [ "Cheating isn't welcome. Griefing is frowned upon. Have fun!" ] +# random lines from this list are shown at a specified frequency in-game +tips = [ + "You are playing %(game_mode)s on %(server_name)s", + "Type /help for info & commands" +] -[tips] - - # random lines from this list are shown at a specified frequency in-game - tips = [ - "You are playing %(game_mode)s on %(server_name)s", - "Type /help for info & commands" - ] - - # how often in minutes the tips should display - frequency = 5 +# how often in minutes the tips should display +tips_frequency = 5 [server] -# whether the server should register to the master server list +# set this if the server should register on the master server list master = false # limit max number of players who can join. @@ -59,7 +55,8 @@ max_players = 32 server_prefix = "" # limit number of players who can connect from the same ip address -# 0 disables the limit (default if not specified is 0) +# 0 disables the limit (default: 0) +#max_connections_per_ip = 0 max_connections_per_ip = 3 # port the server will listen on (default: 32887) @@ -76,7 +73,7 @@ network_interface = "" # other tools if the default is down: # https://icanhazip.com/ # https://api.ipify.org -# ip_getter = "https://services.buildandshoot.com/getip" +#ip_getter = "https://services.buildandshoot.com/getip" # note: scripts are loaded in order entered here. Some scripts may depend on # other scripts being loaded before them. @@ -98,6 +95,20 @@ scripts = [ login_retries = 3 +[server.passwords] +# server management passwords +# players can login using these to execute privileged commands (kicking, +# changing maps, etc.) +# authenticate with: /login +# supports a list of passwords so you can give different passwords to different +# people for easy password management. +# logging in as admin or trusted also disables being votekicked (if that script is enabled) +admin = [ "adminpass1", "adminpass2", "adminpass3"] +moderator = [ "modpass"] +guard = [ "guardpass"] +trusted = [ "trustedpass"] + + [bans] # default duration in minutes a banned player will be banned for default_duration = 1440 @@ -113,22 +124,24 @@ subscribe = false # TODO: document [rights] -moderator = [ "advance", "cancel", "dban", "fog", "from", "goto", "hackinfo", "hban", "invisible", "ip", "kick", "kickafk", "kill", "map", "master", "move", "mute", "resetgame", "switch", "teleport", "teleport_other", "tpsilent", "togglebuild", "togglekill", "togglevotekick", "trust", "undoban", "unmute", "unstick", "where", "whowas"] -guard = [ "cancel", "fog", "from", "goto", "hackinfo", "hban", "ip", "kick", "kickafk", "kill", "move", "mute", "switch", "teleport", "teleport_other", "togglebuild", "togglekill", "togglevotekick", "trust", "unmute", "unstick", "where", "whowas"] - - -[server.passwords] -# server management passwords -# players can login using these to execute privileged commands (kicking, -# changing maps, etc.) -# authenticate with: /login -# supports a list of passwords so you can give different passwords to different -# people for easy password management. -# logging in as admin or trusted also disables being votekicked (if that script is enabled) -admin = [ "adminpass1", "adminpass2", "adminpass3"] -moderator = [ "modpass"] -guard = [ "guardpass"] -trusted = [ "trustedpass"] +moderator = [ + "advance", "cancel", "dban", "fog", + "from", "goto", "hackinfo", "hban", + "invisible", "ip", "kick", "kickafk", + "kill", "map", "master", "move", + "mute", "resetgame", "switch", "teleport", + "teleport_other", "tpsilent", "togglebuild", "togglekill", + "togglevotekick", "trust", "undoban", "unmute", + "unstick", "where", "whowas" +] +guard = [ + "cancel", "fog", "from", "goto", + "hackinfo", "hban", "ip", "kick", + "kickafk", "kill", "move", "mute", + "switch", "teleport", "teleport_other", "togglebuild", + "togglekill", "togglevotekick", "trust", "unmute", + "unstick", "where", "whowas" +] [game] @@ -180,12 +193,27 @@ teamswitch_allowed = true # TODO speedhack_detect = false +# TODO +melee_damage = 80 + +# controls whether players receive damage by falling from height +fall_damage = true + +# disable users ability to affect the map's initial blocks +user_blocks_only = false + +# TODO +set_god_build = false + +# time in seconds remaining when the time remaining should be announced +time_announcements = [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 30, 60, 120, 180, 240, 300, 600, 900, 1200, 1800, 2400, 3000] # number of intel captures to win the game (default: 10) cap_limit = 10 -# information about the two teams for the game + [game.team1] +# information about the team1 # name of the team to be displayed in-game name = "Blue" # color of the players @@ -193,6 +221,7 @@ name = "Blue" color = [ 0, 0, 255] [game.team2] +# information about team2 - same settings as for team1 name = "Green" color = [ 0, 255, 0] @@ -200,6 +229,9 @@ color = [ 0, 255, 0] [maps] # maps listed in the rotation +# these names are the name of the map vxl/txt files without the file extensions +# eg. if you have hallway.txt and hallway.vxl, you can add "hallway" to the rotation +# Note: you can still load a map in-game that isn't on this rotation list with commands rotation = [ "classicgen", "random" @@ -210,20 +242,6 @@ rotation = [ random_rotation = false - - -melee_damage = 80 - -# controls whether players receive damage by falling from height -fall_damage = true - -# disable users ability to affect the map's initial blocks -user_blocks_only = false - -set_god_build = false -time_announcements = [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 30, 60, 120, 180, 240, 300, 600, 900, 1200, 1800, 2400, 3000] - - [logging] # the logfile to log to if logging enabled @@ -231,6 +249,7 @@ time_announcements = [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 30, 60, 120, 180, 240, 300 # directories are created as necessary logfile = "./logs/log.txt" +# TODO: document rotate_daily = true debug_log = false profile = false @@ -244,7 +263,6 @@ port = 32886 logging = true - # settings for the irc chatbot that can report server events and respond to commands # disabled by default [irc] @@ -267,15 +285,15 @@ chatprefix = "." # enable the ssh manhole server # gives ssh access to a python repl connected to the running server # Do not enable unless you are sure you want to use this! -enabled = false -port = 32887 +#enabled = false +#port = 32887 [ssh.users] # user = password # pairs for credentials allowed to login to the ssh server # WARNING: keep these credentials secure since this gives console access to the server # on which piqueserver is running! -user1 = "ssh_pass_change_this" +#user1 = "ssh_pass_change_this" ############################################################################### @@ -323,9 +341,9 @@ ban_duration = 30 public_votes = true +# TODO: document # piqueserver.scripts.votemap [votemap] -# TODO: document public_votes = true extension_time = 15 player_driven = false