ModernUO/Projects/UOContent/Mobiles
Kamron Batman 410a964789
fix: NPC outfits no longer stack two items on one layer (#2715)
Companion to #2712, which covers HireRanger's refused `EquipItem`. A sweep that built every constructible Mobile 2,000 times under each expansion found these other outfits that put two items on one layer. They don't leak, because `AddItem` skips `CheckEquip`, but the NPC wears both items and the client draws only one.

| NPC | Conflict |
|---|---|
| Miner, Ranger, Thief | Own shirt/pants/ThighBoots added on top of the random `BaseVendor.InitOutfit` (shoes doubled on every spawn) |
| MasterTheophilus | Shoes + Robe added over `EvilMageLord`'s Sandals + Robe |
| Merchant | Shirt + FancyShirt, or PlainDress + FancyDress |
| IronWorker | Bandana/JesterHat + Bascinet |
| MeerCaptain | One-handed sword + Crossbow |
| BakeKitsune | `BodyMod` isn't saved, so after a restart `RemoveDisguise` bailed and the next `Disguise()` stacked a second robe and pair of shoes |

## Changes
- `BaseCreature.ReplaceEquipment(item)` equips an item in place of whatever an inherited outfit put on its layer, and deletes the item if it still can't be equipped.
- Miner, Ranger, Thief, MasterTheophilus: their own pieces replace the inherited ones.
- Merchant and IronWorker: dropped the duplicate roll. Each kept the item the client was already drawing, which is the last one sent: the fancy set and the Bascinet.
- MeerCaptain: the sword goes into its pack as loot. **Behavior change:** `Mobile.Weapon` checks the one-handed layer first, so it was fighting with the sword despite its archer AI, its Archery skill and the bolts in its pack. It now uses the crossbow.
- BakeKitsune: `RemoveDisguise` strips the disguise without checking `IsBodyMod`.

## Testing
- I re-ran the sweep (local diagnostic, not committed; needs client tiledata) at 500 rolls × 12 expansions. Only HireRanger (#2712) and LordOaks (separate fix coming) remain.
- UOContent.Tests: 1218 passed, 2 skipped.
2026-10-17 16:17:11 -07:00
..
Abilities refactor: master views over BaseCreature's one master reference (#2674) 2026-09-24 22:45:24 -07:00
AI fix(ai): swap GetDelay bounds so min is the lower one (#2711) 2026-10-17 13:58:04 -07:00
Animals refactor: master views over BaseCreature's one master reference (#2674) 2026-09-24 22:45:24 -07:00
Familiars refactor: master views over BaseCreature's one master reference (#2674) 2026-09-24 22:45:24 -07:00
Guards feat: Adjusts fame and karma system with era gates for OSI accuracy (#2389) 2026-04-25 11:19:57 -07:00
Healers feat: Adds Mobile.Murderer virtual property, consolidates kill-threshold checks (#2355) 2026-03-06 08:36:41 -08:00
Hireables fix: male rangers no longer leak StuddedLegs (#2712) 2026-10-17 15:17:46 -07:00
Monsters fix: NPC outfits no longer stack two items on one layer (#2715) 2026-10-17 16:17:11 -07:00
Special perf: keep damage entries in an inline intrusive list (#2605) 2026-09-01 23:25:14 -07:00
Townfolk fix: NPC outfits no longer stack two items on one layer (#2715) 2026-10-17 16:17:11 -07:00
Vendors fix: NPC outfits no longer stack two items on one layer (#2715) 2026-10-17 16:17:11 -07:00
BaseCreature.cs fix: NPC outfits no longer stack two items on one layer (#2715) 2026-10-17 16:17:11 -07:00
CreatureEvents.cs refactor: Changes BaseCreature to the SerializationGenerator (delta save requirement) (#2611) 2026-09-06 14:11:51 -07:00
NPCSpeeds.cs refactor: Changes BaseCreature to the SerializationGenerator (delta save requirement) (#2611) 2026-09-06 14:11:51 -07:00
PlayerMobile.cs fix: a deleted character's followers, and familiars that never unregistered (#2675) 2026-09-24 23:01:40 -07:00
VirtualMountItem.cs fix: Fixes mount stamina, adds Pub46+ Ethereal stamina (#1716) 2024-04-05 21:05:16 -07:00