I think it’s perfectly viable to make a button in the inventory, right on the info box for the selected weapon. If the button is pressed then it ought switch to an “unset as favourite” version so that the attribute can be deleted, thus allowing the auto-equip to function as normal.
This works just fine from the console, it quite happily switched from another gun to the musketoon...
Code:
aref tempFavGun
makearef(tempFavGun,MainChar.FavGun)
MainChar.FavGun = "pistolmtoon"
string weapon = MainChar.FavGun
EquipCharacterByItem(&MainChar, weapon)
Now, I have absolutely no idea where all the code is which controls the number keys. I put in a few random traces and none them were called when I used the hot-keys, so I wasn’t looking in the right places. I even changed the text for “You have equipped” where I found it, and it still didn’t do anything.
I reckon it’s just a matter of checking the attribute and throwing a
return if the check passes, otherwise it continues with what it was doing.
Also... items already have the
skipequip attribute available. What about a button setting this flag which would therefore allow the player to explicitly filter weapons as they find them? It’s not as easy as selecting a favourite, but it would certainly be easier to code.
@Pieter - So I’ve put a toggle in place on my inventory which flips skipequip on a per-item basis (it doesn’t care what the item is at the moment). However, the auto-equip hot-keys are completely ignoring it because the best gear is still being equipped. I know it’s in place properly because the button says “No” (as in do not auto-equip) when my trusty fists are highlighted and then it will change to “Yes” when I scroll along. If I exit the interface and go back in then I can see that it has kept any status I changed. But it equips my musketoon, rapier and golden cuirass regardless.