diff --git a/src/interaction/wardrobeUse.js b/src/interaction/wardrobeUse.js index ed249dadbac321db8fb066a8af86812328ab3bf7..0cef5bc29b8bd1a15a6b555ff038bd91e7d00d08 100644 --- a/src/interaction/wardrobeUse.js +++ b/src/interaction/wardrobeUse.js @@ -277,7 +277,7 @@ App.UI.Wardrobe.armAccessory = function(slave) { } let el = document.createElement('div'); - // <<armwearDescription>> + // <<App.Desc.armwear($activeSlave)>> let label = document.createElement('div'); label.append(`Arm accessory: `); diff --git a/src/npc/descriptions/style/armwear.js b/src/npc/descriptions/style/armwear.js new file mode 100644 index 0000000000000000000000000000000000000000..fa1fbc29ce7230b220b391dcda84c58bfe12d521 --- /dev/null +++ b/src/npc/descriptions/style/armwear.js @@ -0,0 +1,44 @@ +/** + * @param {App.Entity.SlaveState} slave + * @returns {string} + */ +App.Desc.armwear = function(slave) { + const r = []; + const { + his, He + } = getPronouns(slave); + // TODO: check clothing descriptions for glove references + if (hasAnyArms(slave)) { + switch (slave.armAccessory) { + case "hand gloves": + r.push(`${He} is wearing a pair of simple gloves that covers ${his}`); + if (hasBothArms(slave)) { + r.push(`hands`); + } else { + r.push(`hand`); + } + r.push(`up to ${his}`); + if (hasBothArms(slave)) { + r.push(`wrists.`); + } else { + r.push(`wrist.`); + } + break; + case "elbow gloves": + r.push(`${He} is wearing a pair of long gloves that covers ${his}`); + if (hasBothArms(slave)) { + r.push(`arms`); + } else { + r.push(`arm`); + } + r.push(`until just past ${his}`); + if (hasBothArms(slave)) { + r.push(`elbows.`); + } else { + r.push(`elbow.`); + } + } + } + + return r.join(" "); +}; diff --git a/src/uncategorized/longSlaveDescription.tw b/src/uncategorized/longSlaveDescription.tw index bcb8415400947af71b7a41ac986777af78a7ea2e..8796e272d82e215301ce3bb04eb220b2824ce351 100644 --- a/src/uncategorized/longSlaveDescription.tw +++ b/src/uncategorized/longSlaveDescription.tw @@ -1478,6 +1478,7 @@ is <<= App.Desc.limbs($activeSlave)>> <<= App.Desc.clothing($activeSlave)>> +<<= App.Desc.armwear($activeSlave)>> <<if $showBodyMods == 1>> <<clothingCorsetDescription>> <</if>> diff --git a/src/utility/descriptionWidgetsStyle.tw b/src/utility/descriptionWidgetsStyle.tw index 626dc4abdd3cac43671a7ca01fd97723ca642199..9e8fb06780c4b33724c41f7ba417bd63deb852f8 100644 --- a/src/utility/descriptionWidgetsStyle.tw +++ b/src/utility/descriptionWidgetsStyle.tw @@ -1,19 +1,5 @@ :: clothing description widgets [widget nobr] -<<widget "armwearDescription">> -/* check clothing descriptions from above for glove references */ -<<if (hasAnyArms($activeSlave))>> - <<switch $activeSlave.armAccessory>> - <<case "hand gloves">> - $He is wearing a pair of simple gloves that covers $his hand<<if hasBothArms($activeSlave)>>s<</if>> up to $his wrist<<if hasBothArms($activeSlave)>>s<</if>>. - - <<case "elbow gloves">> - $He is wearing a pair of long gloves that covers $his arm<<if hasBothArms($activeSlave)>>s<</if>> until just past $his elbow<<if hasBothArms($activeSlave)>>s<</if>>. - - <</switch>> -<</if>> -<</widget>> - <<widget "clothingCorsetDescription">> <<switch $activeSlave.clothes>> <<case "a Fuckdoll suit">>