Hi everyone! There's probably a simple work-around to this that I'm not seeing, but I'd like to know how I can have a party member doff an item in the middle of combat and have that item be deleted from their inventory. Imagine someone having their sword break mid-combat or their armor smashed to pieces, for example.
I first tried the built-in "Change Equipment" feature and have the specific item set to "None". This unequipped the item, but it returns the item to the inventory allowing it to be re-equipped later.
Next I figured you could just replace the equipment with a script. I am not too familiar with scripting or Ruby, but I was able to come across something like this and attempted it:
But calling this does the same as the built in "Change Equipment" feature I tried before!
Unless there's something more obvious that I don't know about, I think this might require some parameter to record what the equipped item is, then unequip it, and then remove it. Any advice on how I'd go about doing that? Or is there a simpler solution and I'm just nuking it?
Just to be clear, I'd like for this to be flexible, so that it can be used against the player no matter what it is they have equipped. Designing it around a specific item that I know the player would have equipped would be easy enough, but I want it to work on whatever they might have at that moment.
Thank you for your time!
I first tried the built-in "Change Equipment" feature and have the specific item set to "None". This unequipped the item, but it returns the item to the inventory allowing it to be re-equipped later.
Next I figured you could just replace the equipment with a script. I am not too familiar with scripting or Ruby, but I was able to come across something like this and attempted it:
!$game_actors[1].change_equip(1, nil)But calling this does the same as the built in "Change Equipment" feature I tried before!
Unless there's something more obvious that I don't know about, I think this might require some parameter to record what the equipped item is, then unequip it, and then remove it. Any advice on how I'd go about doing that? Or is there a simpler solution and I'm just nuking it?
Just to be clear, I'd like for this to be flexible, so that it can be used against the player no matter what it is they have equipped. Designing it around a specific item that I know the player would have equipped would be easy enough, but I want it to work on whatever they might have at that moment.
Thank you for your time!