20 lines
485 B
Plaintext
20 lines
485 B
Plaintext
|
|
void main()
|
|
{
|
|
//First line of the item customization script
|
|
object oPlayer = GetPCSpeaker();
|
|
int iSlot = GetLocalInt( OBJECT_SELF, "iSlot");
|
|
object oItem = GetItemInSlot( iSlot, oPlayer);
|
|
|
|
object oNewItem = CopyItemAndModify( oItem, ITEM_APPR_TYPE_ARMOR_MODEL, ITEM_APPR_ARMOR_MODEL_ROBE, 0, TRUE);
|
|
|
|
if( GetIsObjectValid( oNewItem))
|
|
{
|
|
AssignCommand( oPlayer, ActionEquipItem( oNewItem, iSlot));
|
|
DestroyObject( oItem);
|
|
}
|
|
else
|
|
DestroyObject( oNewItem);
|
|
|
|
}
|