JosefGrey Posted January 30, 2012 Posted January 30, 2012 Hey everyone. I'm taking a stab at learning Oblivion's scripting language and am working on a mod in which I have to get a reference for an NPC's equipped armor, then use it to compare to the formIDs in a list of custom armors to see which one the NPC is wearing. So far all I've gotten accomplished is becoming frustrated. Here's a brief example of what I'm trying to use to do this: ref who ref armorid ;get a reference for NPC armor in upper body, lower body, ;hand, foot slot set armorid to who.GetEquippedObject 20 if armorid.GetIsID "FormIDGoesHere" ;do something endif From what I understand the GetIsID function should return a 1 if the reference belongs to the base object that the FormID represents. When the script runs in game however, it simply stops at the if statement (I'm assuming I'm using the GetIsID function incorrectly, but it looks valid based on the documentation on the construction set wiki). Can anyone please offer an alternative method or perhaps let me know what I'm doing wrong here? Thanks!
Recommended Posts
Archived
This topic is now archived and is closed to further replies.