The Forge is currently under construction. Data is synchronized with the hub every 30 minutes. Help report issues!

Mod Details

Featured!
Looting Bots

Looting Bots 1.5.1+spt-311

Created by Skwizzy, ArchangelWTF

517.1K Downloads

SPT 3.11.2 Compatible

This mod aims to add more life to the bots by enhancing some EFT looting behaviors letting bots loot items, containers, and corpses during patrols. More features to come!

If you enjoy my work, support me at Ko-Fi!

REQUIRED DEPENDENCY: BigBrain This mod will not work unless the BigBrain mod is also installed!

View readme for more details. Please report any issues in the comments section here or feel free to open an issue on the github. Having debug enabled in the mod menu is recommended when reporting issues.

GitHub issue custom search in repo - Check here for an existing issue before reporting a bug

GitHub issue custom search in repo

Base game behavior:

  • Scavs start a raid on patrol, when they finish a combat engagement they will return to patrol mode after the amount of seconds specified in the Mind.TIME_TO_FORGOR_ABOUT_ENEMY_SEC bot config property
  • When scavs are on patrol, they have a chance to inspect a nearby corpse and loot simple things such as weapons and
  • When scavs are on patrol, sometimes they stop in front of a lootable container and pretend to loot it
  • PMCs and Scavs in SPT spawn with some potentially valuable loot already in their inventory

Modded behavior:

  • New bot brain layer (LootingLayer) added for looting that replaces the base game logic responsible for "looting"
  • LootingLayer will activate every 10 seconds (by default) during a patrol causing the bots to scan for the closest lootable item, container, or corpse. Scan distance configured by the "Detect Loot Distance" setting (75m by default)
  • Once a lootable object has been found, bots will attempt to navigate to the object and commence looting
  • Bots will attempt to loot everything from within corpse and a container
  • Bots will examine each item for about 1 second before looting it (simulates discovering items when searcing containers/corpses)
  • If a bot cannot equip a piece of gear, they will attempt to place it in their inventory
  • Not all loot is navigable, relies heavily on the availability of a nearby NavMesh that bots can use to navigate
    • If a container is behind a door, bots will open the door if unlocked.
    • If a bot is stuck in place or if the bot spends too much time moving, the loot will be ignored
  • Once looting has finished, bots will wait the amount of time specified
    in the "Delay between looting" setting before the next loot scan occurs (15s by default)

Gear Swap Criteria

  • Bot will always swap to gear that has higher armor rating (helmets, armor vests, armored rigs)
  • Backpack will be swapped if backpack being looted has more slots
  • When looting larger rigs, bots will swap if currently equipped rig is of equal or lower armor class
  • When throwing old backpacks/tactical rigs, bots try to take all the loot from the container thrown
  • When looting weapons, bots will compare the item's Handbook(default) or Flea market price in rubles to the value of the weapons currently equipped.
    • Looted weapons with higher value will replace an equipped weapon with the lowest value
    • Bots prefer to use the highest value weapon as their primary (if they have ammo)

Package Contents

  • BepInEx/plugins/skwizzy.LootingBots.dll - Client plugin responsible for all the new corpse looting logic
  • user/mods/Skwizzy-LootingBots-ServerMod - Server mod responsible for:
    1. Marks all items with DiscardLimits as InsuranceDisabled. It then disables the DiscardLimit settings for the server via the EnableDiscardLimits option in Server/database/globals.json. SPT PMC bots by default spawn with loot already in their backpacks, this loot is not marked Found In Raid and thus is subject to BSG's RMT protection logic. With discard limits enabled, when a bot drops their backback to swap to a new one any loot with discard limits in their bag will be deleted immediately when the bag is dropped. To avoid this we set the EnableDiscardLimits to false, and also make sure to flag all items with a DiscardLimit >= 0 as InsuranceDisabled to prevent items suchs as keys and cases to be insured.
    2. Provides the option to clear out the loot that PMC/Scav bots start with
      in their backpacks. This does not include meds, ammo, grenades ect. These options can be found in the Skwizzy-LootingBots-ServerMod/config/config.json.

Install

  • Extract the contents of the .zip file into your SPT directory
  • Recommended to have LootingBots-ServerMod loaded last in the mod order to make sure discard limits arent enabled by another server mod

Loot Finder

  • Enable corpse looting - Enables corpse looting for the selected bot types
  • Enable corpse line of sight check - When scanning for loot, corpses will be ignored if they are not visible by the bot
  • Detect corpse distance - Distance (in meters) a bot is able to detect a corpse
  • Enable container looting - Enables container looting for the selected bot types
  • Enable container line of sight check - When scanning for loot, containers will be ignored if they are not visible by the bot
  • Detect container distance - Distance (in meters) a bot is able to detect a container
  • Enable loose item looting - Enables loose item looting for the selected bot types
  • Enable item line of sight check - When scanning for loot, loose items will be ignored if they are not visible by the bot
  • Detect item distance - Distance (in meters) a bot is able to detect an item
  • Debug: Log Levels - Enable different levels of log messages to show in the logs
  • Debug: Show navigation points - Renders spheres where bots are trying to navigate when container looting. (Red): Container position. (Green): Calculated bot destination. (Blue): NavMesh corrected destination (where the bot will move).

Loot Finder (Timing)

  • Delay after spawn - Amount of seconds a bot will wait to start their first loot scan after spawning into raid.
  • Delay after taking an item (ms) - Amount of milliseconds a bot will wait after taking an item into their inventory before attempting to loot another item. Simulates the amount of time it takes for a player to look through loot decide to take something.
  • Enable examine time - Adds a delay before looting an item to simulate the time it takes for a bot to "uncover (examine)" an item when searching containers, items and corpses. The delay is calculated using the ExamineTime of an object and the AttentionExamineTime of the bot.
  • Loot scan interval - The amount of seconds the bot will wait until triggering another loot scan

Weapon Loot Settings

  • Use flea market prices- Bots will query more accurate ragfair prices to do item value checks. Will make a query to get ragfair prices when the client is first started. May affect initial client start times.
  • Calculate value from attachments- Calculate weapon value by looking up each attachment. More accurate than just looking at the base weapon template but a slightly more expensive check
  • Allow weapon attachment stripping - Allows bots to take the attachments off of a weapon if they are not able to pick the weapon up into their inventory
  • PMC: Min loot value threshold - PMC bots will only loot items that exceed the specified value in roubles. When set to 0, bots will ignore the minimum value threshold
  • PMC: Max loot value threshold - PMC bots will NOT loot items that exceed the specified value in roubles. When set to 0, bots will ignore the maximum value threshold
  • PMC: Allowed gear to equip - The equipment a PMC bot is able to equip during raid
  • PMC: Allowed gear in bags - The equipment a PMC bot is able to place in their backpack/rig
  • Scav: Min loot value threshold - All non-PMC bots will only loot items that exceed the specified value in roubles. When set to 0, bots will ignore the minimum value threshold
  • Scav: Max value threshold - All non-PMC bots will NOT loot items that exceed the specified value in roubles. When set to 0, bots will ignore the maximum value threshold
  • Scav: Allowed gear to equip - The equipment a non-PMC bot is able to equip during raid
  • Scav: Allowed gear in bags - The equipment a non-PMC bot is able to place in their backpack/rig
  • Log Levels - Enable different levels of log messages to show in the logs

Settings for LootingBots-ServerMod can be found in user/Skwizzy-LootingBots-ServerMod/config/config.json

  • pmcSpawnWithLoot - When set to true, PMCs will spawn with loot in their bags/pockets (default SPT behavior)
  • scavSpawnWithLoot - When set to true, Scavs will spawn with loot in the bags/pockets (default SPT behavior)

Default config:

{ "pmcSpawnWithLoot": false, "scavSpawnWithLoot": true } - Waypoints - Expanded Bot Patrols - Adds expanded NavMeshes to all maps allowing bots to be able to navigate to almost every part of the map. When playing with larger Loot Detection Distances, this will allow bots to travel freely to extremely far away loot

This mod will conflict with any mod that sets theglobals.config.DiscardLimitsEnabled to true. PMC bots will throw exceptions when attempting to discard gear with DiscardLimits set. This needs to be false for the mod to function properly with pmc looting.

GitHub issue custom search in repo GitHub issue custom search in repo

Beta Build

Version 1.5.1+spt-311
Download Mod Version

SPT 3.11.2

Latest Compatible SPT Version

12.1K Downloads

Created Mar 16th, 2:17 PM

Updated Mar 16th, 2:17 PM

Virus Total Results

Note: This release requires BigBrain 1.3.2 or above!

- Fixed a bug where bots would get busy hands due to an action failing

- Removed the patch to disable BSG's looting layer, Big Brain now handles this instead

Version 1.5.0+spt-311
Download Mod Version

Unknown SPT Version

Latest Compatible SPT Version

1.3K Downloads

Created Mar 15th, 8:00 PM

Updated Mar 15th, 8:00 PM

Virus Total Results

- Updated to SPT 3.11

- Adds a new patch to completely turn off BSG's looting layer

- Slightly increased looting bot range (From 75 to 80)

Version 1.4.1+spt-310
Download Mod Version

Unknown SPT Version

Latest Compatible SPT Version

65.2K Downloads

Created Dec 20th, 2024

Updated Dec 20th, 2024

Virus Total Results

Again thank you ArchangelWTF for the changes in this release!

Small changes to improve code health and performance

Changes

  • Replace all LINQ queries with standard code, LINQ is rather inefficient in this older version of .NET and should be avoided
  • Removed old build files
  • Migrated some patches to transpilers which should be slightly faster
  • Removed some more old logic that wasn't referenced anywhere
Version 1.4.0+spt-310
Download Mod Version

Unknown SPT Version

Latest Compatible SPT Version

9.0K Downloads

Created Dec 14th, 2024

Updated Dec 14th, 2024

Virus Total Results

Thank you very much ArchangelWTF for making the upgrade to 3.10! <3

Update references and removed some deprecated logic

Version 1.3.5+spt-390
Download Mod Version

Unknown SPT Version

Latest Compatible SPT Version

123.8K Downloads

Created Jul 9th, 2024

Updated Jul 9th, 2024

Virus Total Results

Thanks @hel0t for the update!

Update references to work with SPT 3.9.0.

VirusTotal is showing one of the vendors reporting as malicious (Anity-AVL). This is a false positive, a rescan of version 1.3.4 which had the vendor as passing is now also reporting as malicious

Version 1.3.4+spt-380
Download Mod Version

Unknown SPT Version

Latest Compatible SPT Version

10.8K Downloads

Created Jun 29th, 2024

Updated Jun 29th, 2024

Virus Total Results

Changes

  • Fix ArgumentOutOfRangeException seen when loot scans do not find any lootable items
  • Fix issue where one loot result was always omitted when processing results from a loot scan

Not quite yet...