I am using SumRndmDde's CCEX and DynamicActors plugins. My goal is to associate each clothing and accessory option with a specific armor in the data using the <Force Clothing Piece: Clothing (x)> notetag. Setting this up after opening the Character Creator is relatively simple with a conditional branch. Here's the script for reference:
If
$gameCharacterCreations.getInfo(ActorID).Clothing.file == 'Clothing (x)'
then
Change Armors: [[Armor type]] +1
Change Equipment: (ActorID), [[Armor type]]
However, I also want to implement an unequip feature. When a piece of clothing or accessory is removed, I want another event to occur. In this event, the default clothing (underwear) should be shown or the accessory should not be replaced with the appearance the player had chosen for their character. Now, I'm aware that there's a fix involving a plugin that prevents unequipping a slot, and I could have an Underwear key item for each game actor. I might have to stick with clothing options only during character creation, in that case, because the analogous fix would be to have an item called 'None' for accessories, which doesn't seem right.
With all that being said, is there a way to check to see if an item, such as armor, is being unequipped, and further, is there a way to change the Info(ActorID).Clothing.file or AccessoryA/B.file on the fly so that a more elegant solution can be scripted?
If
$gameCharacterCreations.getInfo(ActorID).Clothing.file == 'Clothing (x)'
then
Change Armors: [[Armor type]] +1
Change Equipment: (ActorID), [[Armor type]]
However, I also want to implement an unequip feature. When a piece of clothing or accessory is removed, I want another event to occur. In this event, the default clothing (underwear) should be shown or the accessory should not be replaced with the appearance the player had chosen for their character. Now, I'm aware that there's a fix involving a plugin that prevents unequipping a slot, and I could have an Underwear key item for each game actor. I might have to stick with clothing options only during character creation, in that case, because the analogous fix would be to have an item called 'None' for accessories, which doesn't seem right.
With all that being said, is there a way to check to see if an item, such as armor, is being unequipped, and further, is there a way to change the Info(ActorID).Clothing.file or AccessoryA/B.file on the fly so that a more elegant solution can be scripted?