Replacing an inventory item via dialog
Greener
Member Posts: 430
I've run into a problem, currently an NPC has a sword that is restricted to them, upon their death I'd like anyone to be able to use the item
Thus I was attempting to create an exact copy without the restrict item (319) effect
I'm trying to implement it via dialog (seen below) with the TakePartyItem("OAGinawa") DestroyItem("OAGinawa") GiveItemCreate("OAKatana",OAGinaw,1,0,0) but it doesn't seem to work, can anyone offer a fix?
IF ~~ THEN
BEGIN Enemy
SAY ~A foolish choice, you will most certainly pay with your life……KIE!~
IF ~~ THEN DO ~Enemy() TakePartyItem("OAGinawa") DestroyItem("OAGinawa") GiveItemCreate("OAKatana",OAGinaw,1,0,0)~
EXIT
END
Thus I was attempting to create an exact copy without the restrict item (319) effect
I'm trying to implement it via dialog (seen below) with the TakePartyItem("OAGinawa") DestroyItem("OAGinawa") GiveItemCreate("OAKatana",OAGinaw,1,0,0) but it doesn't seem to work, can anyone offer a fix?
IF ~~ THEN
BEGIN Enemy
SAY ~A foolish choice, you will most certainly pay with your life……KIE!~
IF ~~ THEN DO ~Enemy() TakePartyItem("OAGinawa") DestroyItem("OAGinawa") GiveItemCreate("OAKatana",OAGinaw,1,0,0)~
EXIT
END
0
Comments
GiveItemCreate("OAKatana","OAGinaw",1,0,0)
It creates said item, but places it in the creatures inventory, is there a way to equip the newly created item?
I tried:
IF ~~ THEN DO ~Enemy() TakePartyItem("OAGinawa") DestroyItem("OAGinawa") GiveItemCreate("OAKatana","OAGinaw",1,0,0, IDENTIFIED, WEAPON1, EQUIP)~
but the yields the following error
[action list near line 39, column 145 of Ginawa/Dialogue/OAGinawJ.d] PARSE WARNING at line 39 column 1-128
Near Text: )
Too many arguments to [GiveItemCreate]. Recovering.
I've made the original item with the restrict item (319) code and made is undroppable
Now this creates the new version of the sword without the restrict item effect (319)
IF ~~ THEN DO ~GiveItemCreate("OAKatana","OAGinaw",1,0,0,)
And upon killing the NPC the created item is what is dropped