Skip to content

How to Configure Friendly Fire on Your SCP: Secret Laboratory Server ​

Using the config_gameplay.txt file you can enable damage between teammates (friendly fire) and configure the automatic teamkill detector.

Warning

The path to the configuration file contains the Game Port of your server: /.config/SCP Secret Laboratory/config/<Port>/config_gameplay.txt. Replace <Port> with the actual Game Port of your server. You can find it in the dashboard under Overview.

Important

If you only set friendly_fire: true, you automatically arm the teamkill detector as well: the spawn detector and the explosion detector are enabled out of the box and ban players for 48 hours — the spawn detector already triggers at 2 teamkills or 180 team damage within 120 seconds after spawning. If players on your server complain about "random" automatic bans, the detector is almost always the cause. The recipes below show how to disable or soften it.

Configure friendly fire ​

  1. Find out the Game Port
    Open the dashboard of your server and note the Game Port shown under Overview.

  2. Stop the server
    Stop your server via the dashboard.

  3. Connect via SFTP
    Connect to your server via SFTP.

  4. Open the configuration file
    Open the following file — replace <Port> with your Game Port:

    /.config/SCP Secret Laboratory/config/<Port>/config_gameplay.txt
  5. Adjust the values
    Pick one of the recipes below and apply its values. Edit existing entries directly in the file; if a key is missing, add it as a new line in the format key: value.

  6. Start the server
    Save the file and start your server via the dashboard.

Basic settings ​

KeyDefaultDescription
friendly_firefalseEnables or disables damage between teammates
friendly_fire_multiplier0.4Multiplier for damage dealt to teammates (0.4 = 40% of normal damage)

The teamkill detector ​

The detector tracks teamkills and team damage and punishes players automatically as soon as either threshold is reached — it counts kills or damage. There are five variants, each with its own time frame:

VariantKey prefixEnabled by defaultTime frame
Roundff_detector_round_Nothe entire round
Lifeff_detector_life_Noone life (until the next respawn)
Windowff_detector_window_Norolling window of 180 seconds (ff_detector_window_seconds)
Spawnff_detector_spawn_Yes120 seconds after spawning (ff_detector_spawn_window_seconds)
Explosion after disconnectingff_detector_explosion_after_disconnecting_Yestriggers when a player's explosion (e.g. a thrown grenade) hits teammates after the player has left the server

Each variant is configured with the same suffixes (the explosion variant has no _kills and _damage thresholds):

SuffixMeaning
_enabledTurns the variant on or off
_killsNumber of teamkills that triggers the action (0 disables this threshold)
_damageAmount of team damage that triggers the action (0 disables this threshold)
_actionAction to perform: kill, kick, ban or noop
_ban_timeBan duration when the action is ban (e.g. 24h)

Default values ​

Variant_enabled_kills_damage_action_ban_time
roundfalse6500ban24h
lifefalse4300ban24h
windowfalse3250ban16h
spawntrue2180ban48h
explosion_after_disconnectingtrue——ban48h

Actions ​

ValueEffect
killThe player is killed
kickThe player is kicked from the server
banThe player is banned for the duration set in _ban_time
noopNo action — useful if you only want incidents to be logged

Note

Team damage dealt after the round has ended is ignored by the detector. You can find the full list of keys — for example the broadcast and ban messages of each variant — in the official SCP: Secret Laboratory Tech Wiki.

Recipes ​

Friendly fire with default detector ​

Enables friendly fire at 40% damage and keeps the detector at its default values:

friendly_fire: true
friendly_fire_multiplier: 0.4

With this, the spawn detector (48-hour ban at 2 teamkills or 180 team damage shortly after spawning) and the explosion detector (48-hour ban) are armed immediately. For a public server this is reasonable protection — just be aware that the server will ban players without your involvement.

Friendly fire without detector ​

Enables friendly fire and cleanly disables all five detector variants — for example for private servers or events where team damage is intended:

friendly_fire: true
ff_detector_round_enabled: false
ff_detector_life_enabled: false
ff_detector_window_enabled: false
ff_detector_spawn_enabled: false
ff_detector_explosion_after_disconnecting_enabled: false

The variants round, life and window already default to false — set all five explicitly anyway, so the state is clearly documented in your configuration.

Detector on kick instead of ban ​

Keeps the protection against teamkillers but replaces all automatic bans with a kick:

friendly_fire: true
ff_detector_round_action: kick
ff_detector_life_action: kick
ff_detector_window_action: kick
ff_detector_spawn_action: kick
ff_detector_explosion_after_disconnecting_action: kick

Tip

The detector's default broadcast messages mention a ban ("%nick has been automatically banned for teamkilling."). If you change the action to kick, also adjust ff_detector_<variant>_broadcast_message where needed so the in-game message is accurate.

Note

Changes to config_gameplay.txt only take effect after a server restart.