AbbaddoN33 Posted January 18, 2016 Share Posted January 18, 2016 Hello! I'm having an issue using GETCONTAINER in npcs with prefix "ff". Here's my script condensed and simplified. This is embedded in an item distributed in some npcs through leveled lists: Scn a33script ref a33actorrefshort a33doonceshort a33doonce2 ;==================================== begin gamemode if a33doonce == 0 set a33actorref to getcontainer set a33doonce to 1 endif if (a33actorref.getdead == 1)&&(a33doonce2 == 0) set a33doonce2 to 1 dropme endif end This should detect when the npc that has it in his inventory dies, and then the item should drop of him.When I use it in npcs with prefix that it's not "ff" works perfect, but it's not that way in npcs with prefix "ff". I use SV command in the console, and script var "a33actorref" give 0000000. Do i'm missing something? Link to comment Share on other sites More sharing options...
luthienanarion Posted January 22, 2016 Share Posted January 22, 2016 GetContainer can fail when called the first frame or two after your item has been added to an inventory. scn a33script ref a33actorref int a33doonce begin gamemode if a33doonce else if a33actorref if a33actorref.getdead set a33doonce to 1 dropme endif else set a33actorref to getcontainer endif endif end ; gamemode Link to comment Share on other sites More sharing options...
AbbaddoN33 Posted January 22, 2016 Author Share Posted January 22, 2016 Thank you very much!! I'll try that! d:)> Link to comment Share on other sites More sharing options...
AbbaddoN33 Posted January 24, 2016 Author Share Posted January 24, 2016 (edited) There is no doubt that you are a master of the script. The advice you gave me worked perfectly. Many thanks Luthienanarion! :) Kudos to you! Edited January 24, 2016 by AbbaddoN33 Link to comment Share on other sites More sharing options...
Recommended Posts