Skip to main content

Mod Details

Looting Bots

Looting Bots 1.7.0

Created by Skwizzy

688.9K Downloads

SPT 4.0.13 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!

Latest Version 1.7.0
SPT 4.0.13

Updated Apr 1, 10:00 PM

53.40 KB

Version Notes

Added:

  • Looting priority, currently implemented for corpses (Bots should prioritize looting their own kills) and airdrops
  • Extend gear swapping to include other gear (e.g. headphones, eyewear, facecover etc)
  • Flea price poll every 30 minutes
  • Scan Limiter, limit concurrent loot scans with config
  • Empty scan attempts cooldown
  • Looting action timeout, in case bots get stuck (shouldn’t probably happen now)
  • Total bot networth (only seen in debug)
  • Transaction fail checks
  • Add missing equipment slots

Fixed:

  • Moving a bot’s active weapon can cause the bot to get stuck (more of a workaround, the cause is hard to track and is not from LB)
  • GetPrioritySlots using corpse equipment instead of own equipment
  • Add is used in SubtractNetValue
  • Use of interop which forces a bot’s brain to be enabled is never reverted
  • Destroy LootFinder when BotOwner is disposed
  • Error merging into magazines/weapon chambers

Modified:

  • Unify ActiveItem ActiveCorpse ActiveContainer into ActiveLoot
  • Get loot type from InteractableObject instead of using GetComponentInParent for each type
  • Checks per type of loot instead of checking for all loot types
  • Refactor ShouldSwapGear, early returns for less checks, monetary check
  • Update GetArmorDifference to check plates inside armor slots
  • Better flow when swapping gear, after equipping - throw undervalued items, useless mags, then loot/strip attachments of thrown/swapped out gear
  • Try to swap if possible instead of throwing items on the ground
  • Blocking item check for ShouldSwapGear
  • Cleanup ThrowUselessMags
  • Refactor locked/unlootable slot/item checks
  • Select best available weapon after looting (Almost always primary weapon)
  • Refactor distance checks, early exit when current path length exceeds range
  • Per slot item pricing
  • Try continue moving bot with partial path
  • Reuse GearValue weapon pairs instead of allocating new ones when weapons are updated
  • Use pooling where possible to minimize allocations (arrays and objects)
  • Use bot’s BotLog in ItemAppraiser calls
  • InteractContainer helper Fika compat
  • Clear lists instead of assigning new ones when resetting (Caches)
  • Early return 0 when getting avail grid slots when grid is null
  • Store LayerMask as int to avoid conversions
  • Do not clear active loot if unsuccesful in looting (usually interrupted by combat) for less loot scans
  • Config: Increase delays for more realistic loot time
  • Avoid some more repeated property access
  • Various reductions in allocations

A huge thanks to @ozen-m Who practically did most of these changes himself, I only added airdrops to his priority system

This download is externally hosted.
Always scan for viruses.
Required Dependencies

This mod requires the following mods to be installed. Please download and install them before using this mod.

This download is externally hosted.
Always scan for viruses.
Description
34 Versions
0 Addons
623 Comments

Required Dependencies

The latest version of this mod requires the following mods to be installed as well.

Details