Survivalist: Invisible Strain

Survivalist: Invisible Strain

61 ratings
SIS Look For Weapons
   
Award
Favorite
Favorited
Unfavorite
Tags: IsMod
File Size
Posted
Updated
5.038 MB
26 May, 2024 @ 2:58am
21 May @ 2:38pm
4 Change Notes ( view )

Subscribe to download
SIS Look For Weapons

Description
What is this?
This mod allows characters to look for weapons when they don't have any in their inventory. They will also prioritize looking for a weapon if they ever enter combat and are unarmed, as that would be a very bad idea. They can also ask their community members for weapons if none are found around them.

To avoid characters from taking specific weapons, you can do so by setting the in-game policy "Can Craft With" off for that specific weapon and character. You can also add weapons to excluded lists in the configuration so no one will pick them up.

Can be added to current saves.

Recommendation
Specially created to be played in combination with the Weapon Durability[http//InProgress] mod, as weapons can break and characters will often end up without a melee weapon.

Settings
The settings file can be found in the mod folder under "Settings_LookForWeapons.xml"
  • EnabledForPlayerCommunity. Whether the mod is enabled for the characters in the player community. (default true)
  • EnabledForNPCs. Whether the mod is enabled for NPCs, so characters that aren't in your community. (default true)
  • RadiusCheckWeapons. Radius to check for weapons. (default 20)
  • CanLookForMeleeWeapons. Whether the characters can look for melee weapons. (default true)
  • CanLookForAmmoWeapons. Whether the characters can look for ammo weapons (guns, bows). (default true)
  • AmmoThresholdToLookForWeapon. The amount of ammo the character needs to avoid looking for a weapon if he has an ammo weapon. (default 10)
  • CanAskCharactersForWeapon. If characters can ask community members or allies for weapons. (default true)
  • AskOnlyInSameCommunity. If CanAskCharactersForWeapon enabled, whether character can only ask to members of same community. Otherwise can ask to allies too. (default true)
  • CanStealFromAnotherCommunityForWeapon. If characters can steal from non-hostile community members bodies for weapons. If enabled, character will be attacked if stealing witnessed. (default false)
  • AlwaysLookForMeleeWeaponIfNoneInInventory. If enabled will look for melee weapons even if character has ammo weapon. (default false)
  • ExcludedMeleeWeapons. List of melee weapons that characters will skip when searching.
  • ExcludedAmmoWeapons. List of ammo weapons that characters will skip when searching.
  • UseCantCraftPolicyAsExcluded. If the policy "Can Craft With" for a specific weapon is set to OFF, then the weapon is excluded from being picked up by the character / characters in the community. (default true)

Compatibility
Shouldn't have any incompatibilities. Report any issues in the comments section!

Credits
Erikem, Luo2430 and Bob!
13 Comments
Captain Rex 21 May @ 3:15pm 
Just tested it, zero crashes, even loaded a save where it would crash 100% of the time, but no crashes, thank you!

Just one thing, the game feels a bit more stuttery. Fps remains solid locked at 75 (my screen's Hz) but the 1%Lows go very low sometimes, mostly when moving the camera, the first update of the day, the one that crashed was butter smooth.

By the way, i'm not complaining or anything, i'm very grateful for the mod and the crash fix, just comparing the versions in case it helps or is relevant.
SweetCaptn  [author] 21 May @ 2:39pm 
Alright, I think it shouldn't crash anymore. Let me know if this keeps happening
Captain Rex 21 May @ 1:26pm 
Mods: BaseStory, (Zedmulate), (Extended Equipment), (Bloodbox (Mod Version) Blood magic, black magic, hypnotism, conjuration, weapons, and more), (Convos & Quests Overhaul 2), (Extra Constructions), (Fri's Scripts and Stuff), (Incinerator), (SIS Hide Recipes), Common, (Patch for Extended Equipment), (SIS Add To Fire Framework), (Luxuries in the end of the world V2.0), (SIS Armor Is Valuable), (SIS Auto Gear Up), (SIS Choose Backpack), (SIS Crossbows), (SIS Fishing), (SIS Glasses Absorb Damage), (SIS Headwear Expansion), (SIS Look For Weapons), (SIS Map Settings), (SIS Melee Expansion), (SweetCaptnCommon), (SIS Move Props), (SIS No Unlimited Ammo), (SIS Pick Mushrooms), (SIS Watches), (XtraLargePack), (SIS Loot Respawn)
Captain Rex 21 May @ 1:24pm 
Before today's update, my game would stutter from time to time and remain stuttering for around 30 seconds and then go back to normal, after today's update, it did not stutter even once but now it is crashing.
Captain Rex 21 May @ 1:21pm 
Part 2:

Character.GetGoalDebugString () (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

Character.SanityCheckTargetRefCounts (System.Boolean onLoadingThread, System.String prevGoalStr) (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

Character.SanityCheckTargetRefCounts () (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

Character.Think () (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

CharacterManager.Think () (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

(wrapper dynamic-method) Session.Session.DeterministicUpdate_Patch1(Session)

Session.NonDeterministicFixedUpdate (InputFrame handleInputFrame) (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

GameImpl.FixedUpdate () (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

Launcher.FixedUpdate () (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)
Captain Rex 21 May @ 1:21pm 
Part 1 due to steam limit: I'm not sure if it is from this mod, base game or a mod conflict, but this crash only started today and after today's patch to this mod and the fishing mod, no other mod or vanilla files were changed:

Exception (v247): IndexOutOfRangeException: Index was outside the bounds of the array. Goal.BuildDebugString (Character character, Goal parent, System.Text.StringBuilder str) (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

StateMachineGoal.BuildDebugString (Character character, Goal parent, System.Text.StringBuilder str) (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

StateMachineGoal.BuildDebugString (Character character, Goal parent, System.Text.StringBuilder str) (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)

StateMachineGoal.BuildDebugString (Character character, Goal parent, System.Text.StringBuilder str) (at <1f23ee727cde425aa5ecfce5bef33b4d>:0)
SweetCaptn  [author] 21 May @ 5:05am 
Uploaded a patch fixing a crash
Billy O'Brian 13 May @ 1:12pm 
There may be a bug with your mod. I'm getting this error when using look for weapons:

Exception (v246): InvalidOperationException: Collection was modified; enumeration operation may not execute. System.Collections.Generic.List`1+Enumerator[T].MoveNextRare () (at <191a1970a53948f9819ac1d2e4f5c72e>:0)
System.Collections.Generic.List`1+Enumerator[T].MoveNext () (at <191a1970a53948f9819ac1d2e4f5c72e>:0)
SoundManager.PlayQueuedSounds () (at <290add61d8de441b8177a23fdc3c2d78>:0)
GameImpl.Update () (at <290add61d8de441b8177a23fdc3c2d78>:0)
Launcher.Update () (at <290add61d8de441b8177a23fdc3c2d78>:0)
Mods: BaseStory, 2242522954 (Zedmulate), 2644124757 (Better Farmer), 2892780722 (Cheat mod), 3476974868 (Incinerator), 3138085677 (Invader Icons Color for Zedmulate), 3132820784 (Liquid and Food Color For Zedmulate), 3260978027 (SIS Auto Gear Up), 3254752584 (SIS Look For Weapons)
SweetCaptn  [author] 10 Jun, 2024 @ 1:36am 
Hey! Yeah, every character can look for weapons. You can toggle it on/off through the configuration. Go take a look at the "Settings" section to see what can be edited
Billy O'Brian 9 Jun, 2024 @ 12:51pm 
Does the AI also pick up weapons? Or does it only effect the players community?