Skip to content

Prevent merchant equipping breaks on lights

Synergetic mentioned that a merchant in Andothren had equipped a helmet they sold her on the TR server last Sunday. I figured it was probably some Lua mod doing it, but then I noticed the same thing with one of the Sadrith Mora merchants.

MWMechanics::updateEquippedLight calls MWWorld::InventoryStore::autoEquip to unequip torches when it gets light. This then causes the actor to re-evaluate everything they're wearing, leading to them equipping items the player sold them even though the prevent merchant equipping setting should prevent that.

Note that the MCP's version of this setting isn't quite perfect either. It will equip shields sold by the player in the same scenario. It won't equip items into other slots, though.

Doesn't appear to be a regression as it happens on 0.47 and 0.48 as well.