Jump to content

Recommended Posts

Posted

I am thinking about making a mod that will allow the NPC to make a comment about the player wearing a hat (specifically inside buildings). How difficult would this be?

Posted

Probably not too difficult. There are already conditions you can use (IsInInterior and GetEquipped) to check if the player is indoors while wearing a hat. May be a bit trickier to check for mod-added hats, though. Perhaps NVSE has some scripting for that? Otherwise you'd have to use GetEquipped and check for all the different pieces of headgear in the vanilla game.

Posted

GetEquippedObject from NVSE is what you want. More specifically:

If NPC.GetEquippedObject 0
    ; do your spells and incantations here
EndIf

0 is the equip slot ID for the head. You can see a full list of IDs here.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...