**Describe the bug**
If a weapon using enemy happens to have the weapon they are currently using run out of condition and break, they will switch to using their hands, over changing to any other non-broken weapons they currently have in their inventory. While this is a pretty unlikely thing to happen in normal Vanilla gameplay (likely impossible in most situations), this does show some issues with how enemies interact with their inventory.
**To Reproduce**
Steps to reproduce the behavior:
-This was discovered while playing around with a mod that alters how much condition damage items take from being hit, so this is somewhat difficult to reproduce in Vanilla.
-Best bet is to figure out a quick way to reduce an enemies weapon condition down to 0, probably using a mod that overrides the "ApplyConditionDamageThroughPhysicalHit" method of FormulaHelper.cs and massively increase the numbers to make weapons break like nothing. (I can upload a .dfmod that helps with this if somebody needs that to reproduce.)
**Expected behavior**
No clue what the Classic behavior with this is supposed to be, probably never worked in Classic honestly. Logically speaking though, I would assume the enemy would change to whatever their next best weapon they have in their inventory if their main weapon breaks.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Desktop (please complete the following information):**
- OS: Windows
- Version: alpha 0.10.21
**Additional context**
This may have similar origin to this other bug as well, where enemies will keep trying to use ineffective weapons against enemies, instead of switching to their fists, or a higher material weapon to actually be able to damage something like a werewolf player or anything else immune to lesser materials. viewtopic.php?f=22&t=3474&start=10#p40810
[0.10.21] If Weapon Enemy Is Using Breaks, They Will Prefer Unarmed, Over Switching To Spare Weapons
- Magicono43
- Posts: 1141
- Joined: Tue Nov 06, 2018 7:06 am
- Hazelnut
- Posts: 3016
- Joined: Sat Aug 26, 2017 2:46 pm
- Contact:
Re: [0.10.21] If Weapon Enemy Is Using Breaks, They Will Prefer Unarmed, Over Switching To Spare Weapons
There's really no conceivable way enemies should break their primary weapons in a single fight, and I very much doubt this is handled in classic. Doesn't seem like a bug to me.
See my mod code for examples of how to change various aspects of DFU: https://github.com/ajrb/dfunity-mods
- Magicono43
- Posts: 1141
- Joined: Tue Nov 06, 2018 7:06 am
Re: [0.10.21] If Weapon Enemy Is Using Breaks, They Will Prefer Unarmed, Over Switching To Spare Weapons
Maybe i'll just have to make a module for specific case that forces enemies to ignore broken items in their inventory or something. If had my equipment damage altering mod along side with the "Loot Realism" mod, with the module that spawns enemies with already worn equipment, I think this behavior could feasibly happen. But yeah, I would also assume this would never happen in Classic since weapons take so long to break as is, and they normally spawn brand-new.