server.cfg

Last-modified: 2013-12-10 (火) 15:19:53

(サーバファイルのインストールディレクトリ)\tf\cfgにserver.cfgを作成する。
テキストファイルなので、メモ帳でも構わない。

server.cfgで最低限設定すべき項目
hostname "サーバ名" 公開するサーバの名前。漢字を使うと文字化けを起こす
rcon_password "パスワード" リモートコンソールパスワード。""(ブランク扱い)だと利用不可。

server.cfgに記述されていない項目は、デフォルトが適用される
サーバの名前とパスワードだけ設定し、あとはデフォルト設定でも問題ない。

General Settings (全体の設定等)

  • hostname (YourserverNAME)
    • あなたのサーバーの名前
      「BOMコード無しのUTF-8形式」でテキストを保存しないと、日本語が文字化けする
      この形式で保存できる無料テキストエディタは、windowsならSakura Editor,EmEditorFreeなどがある
  • sv_pure 0
    • Control where the client gets content from 0 = anywhere, 1 = anywhere listed in white list, 2 = steam official content only(カスタムスキンなどの制限2の公式のみにしておくべき)
  • sv_lan 0
    • 1だと自分しか入れない、0だとウェブに公開
  • sv_tags "タグ名(jp,japan,鯖名など)"
    • TF2のサバブラウザで検索に利用する、jpや鯖名を入れておくと検索で見つけられるので利便性が上がる。半角英数字のみ可能
  • sv_consistency 1
    • Whether the server enforces file consistency for critical files
  • sv_stats 1
    • Collect CPU usage stats
  • sv_region 4
    • あなたのサーバーの場所を選んでください
      -1 is the world, 0 is USA east coast, 1 is USA west coast
      2 south america, 3 europe, 4 asia, 5 australia, 6 middle east, 7 africa

Rcon Settings

  • rcon_password ●●●●
    • リモートコントロールの略、ゲーム上や専用ツールから鯖を遠隔操作する場合のパスワードを記入。
  • sv_rcon_banpenalty 1440
    • Number of minutes to ban users who fail rcon authentication
  • sv_rcon_maxfailures 5
    • Max number of times a user can fail rcon authentication before being banned

詳細なゲームの設定

  • mp_chattime
    • 試合終了(得点表が自動表示される)からマップ変更までの待ち時間。秒単位で指定し、初期値は10。
  • mp_stalemate_enable
    • サドンデスを有効にするかどうかの設定。1にすると有効。初期値は0(無効)。
  • mp_stalemate_timelimit
    • サドンデスラウンドの制限時間。秒単位で指定し、初期値は240。
  • mp_bonusroundtime
    • ラウンド終了後のご褒美タイムの長さ。秒単位で指定し、初期値は上限値の15。
  • mp_winlimit
    • マップ毎のチーム得点の上限を決める。一方のチームがこれを満たすと次のマップに移動する。初期値は0(無制限)。
    • CP_DUSTBOWLやCP_GRAVELPITのように、1ラウンドで複数回チーム得点が入るマップでは、上限を設定しているとラウンド途中で試合終了になる場合があるので注意。
  • mp_maxrounds
    • マップ毎のラウンド数の上限を決める。これを満たすと次のマップに移動する。初期値は0(無制限)。
    • CP_DUSTBOWLやTC_HYDROのミニラウンドは1ラウンドに数えないので注意。
  • tf_flag_caps_per_round
    • CTFマップで、旗を何回持ち帰ればラウンド勝利になるかの数。初期値は3。
  • sv_alltalk
    • 音声チャットが敵チームにも聞こえるかどうかの設定。1にすると有効。初期値は0(無効)。
  • mp_timelimit (分数)
    • マップ側に時間制限を設定していない場合はここの数値がゲームの制限時間になります。設定していないとHUDも表示されません。

Log Settings

  • log on
  • Enables logging to file, console, and udp < on | off >.
  • sv_log_onefile 0
    • Log server information to only one file.
  • sv_logfile 1
    • Log server information in the log file.
  • sv_logbans 1
    • Log server bans in the server logs.
  • sv_logecho 1
    • Echo log information to the console.

Rate Settings (FPS設定など)

  • fps_max 600
    • Frame rate limiter
  • sv_minrate 0
    • Min bandwidth rate allowed on server, 0 == unlimited
  • sv_maxrate 20000
    • Max bandwidth rate allowed on server, 0 == unlimited
  • sv_minupdaterate 10
    • Minimum updates per second that the server will allow
  • sv_maxupdaterate 66
    • Maximum updates per second that the server will allow

Download Settings (カスタムマップのダウンロード設定)

  • sv_allowupload 1
    • Allow clients to upload customizations files
  • sv_allowdownload 1
    • Allow clients to download files
  • net_maxfilesize 15
    • Maximum allowed file size for uploading in MB

Team Balancing (チームバランスの設定)

  • mp_autoteambalance 1
    • Enable team balancing
  • mp_autoteambalance_delay 60
    • Time after the teams become unbalanced to attempt to switch players.
  • mp_autoteambalance_warning_delay 30
    • Time after the teams become unbalanced to print a balance warning
  • mp_teams_unbalance_limit 1
    • Teams are unbalanced when one team has this many more players than the other team. (0 disables check)

Round and Game Times (ラウンドの時間の設定)

  • mp_enableroundwaittime 1
    • Enable timers to wait between rounds. WARNING: Setting this to 0 has been known to cause a bug with setup times lasting 5:20 (5 minutes 20 seconds) on some servers!
  • mp_bonusroundtime 8
    • ゲーム勝敗が付いたときの虐殺モードの時間(最大15秒)
  • mp_restartround 0
    • 0以外だとその数値分の秒数が過ぎるとリスタートします。
  • mp_stalemate_enable 1
    • サドンデスモードの設定。1だと有効 0だと無効(そのまま引き分け)
  • mp_stalemate_timelimit 300
    • サドンデスモードのタイムリミット (秒数設定)
  • mp_timelimit 35
    • マップ側に時間制限を設定していない場合はここの数値がゲームの制限時間になります。設定していないとHUDも表示されません。カスタムマップによっては無制限になる場合もあるのでデフォルト値として設定しておくといいでしょう。

Client CVARS (クライアント設定)

  • mp_forcecamera 0
    • Restricts spectator modes for dead players
  • mp_allowspectators 1
    • toggles whether the server allows spectator mode or not
  • mp_footsteps 1
    • toggles footstep sounds
  • sv_cheats 0
    • チート設定。通常は0にしておくべき。1にするとnoclipやgodモードなど自由になるのでゲームのテストなどで使うもの。
  • sv_timeout 900
    • After this many seconds without a message from a client, the client is dropped
  • mp_idlemaxtime 15
    • Maximum time a player is allowed to be idle (in minutes), made this and sv_timeout equal same 18:04:45
  • mp_idledealmethod 2
    • Deals with idle players 1=send to spectator 2=kick
  • decalfrequency 30
    • time (seconds) between decal sprays

Communications(コミュニケーション設定)

  • sv_voiceenable 1
    • enable voice communications
  • sv_alltalk 0
    • 音声チャットが敵チームにも聞こえるかどうかの設定。1にすると有効。初期値は0(無効)。
  • mp_chattime 10
    • amount of time players can chat after the game is over
  • tf_birthday 1
    • パーティーモード(死体が箱やバネなどのファンシーな物になる)の設定 1で有効 0で無効(デフォルト)

ソースTVの設定

ビギナーズ鯖の人に感謝。使うときは目安程度で、要各自調整。

tv_enable 1
tv_name "G's TV TF2"
tv_maxclients 5 // (0-255, default 128)
tv_delay 10 // (10-120[sec], default 30)
tv_delaymapchange 1 // (1 | 0)
tv_port 27020 // (default 27020)
tv_maxrate 0 // (default 5000[bps], 0:unlimited)
tv_autorecord 0
tv_debug 1 // (1 | 0)
//tv_snapshotrate 24 // (default 16)
tv_dispatchmode 1 // (0=never, 1=if appropriate, 2=always)
//tv_overrideroot 0 // (0 | 1)
tv_allow_camera_man 1
tv_allow_static_shots 1 //
//tv_relayvoice 1
tv_transmitall 1
tv_password ""
  • tv_enable
    ソースTVを有効にするかどうかを設定します。1で有効になります。
  • tv_name
    ソースTVのサーバー名を設定します。日本語など2バイト文字は使えないようです(Unicode, UTF-8N共にNG)。
  • tv_maxclients
    ソースTVの定員を設定します。
  • tv_delay
    配信の遅延時間を秒単位で設定します。プレイヤーが別マシンでソースTVを視聴することで敵チームの様子を覗き見できるため、その対策として最小値は10秒となっています。
  • tv_delaymapchange
    サーバーがマップを変更する際に、ソースTVの配信終了を待つかどうかを設定します。1で有効にすると、遅延時間が長い場合でも決着の瞬間を視聴できますが、プレイヤーはその分次のマップまで待たされることになります。
    マップ変更を遅らせず、かつ視聴者が最終ラウンドの決着を見れるようにするには、mp_chattimeとmp_bonusroundtimeの合計値がtv_delay+5より大きくなるように設定します。
  • tv_port
    ソースTVのポート番号を設定します。初期値は27020です。
  • tv_maxrate
    各視聴者に割り当てるデータ帯域の上限を設定します。0で無制限になります。
  • tv_debug
    デバッグ情報をサーバーのコンソールに出力するかどうかを設定します。1で有効になります。

設定時の注意点

ソースTV自身が観戦者としてプレイヤースロットを1つ占有するため、ソースTVを有効にする際は、サーバーのプレイヤー定員(maxplayers)を奇数に設定することをおすすめします。(2008/02/14の更新で、ソースTV用に定員外のプレイヤースロットが確保されるようになったため、24人設定でもチームバランスを保てるようになりました*1)
一部のCVAR(クライアント変数)は、cfgに書いただけでは最初に回るマップだけ設定値が反映されないようなので、これらはサーバーのコマンドラインオプションで設定した方がいいでしょう。

+tv_enable 1 +tv_maxclients 5

のように、CVAR名の頭に+記号を付ければコマンドラインでCVARの値を設定できます。


*1 この場合、サーバーのコンソールでは定員25人と表示される。