diff --git a/src/interaction/siWork.js b/src/interaction/siWork.js index 48a03c0bf4db8c1cc1765efd8a61f630232bcf8a..e55b40b2910de64f2135741787a2460679889aac 100644 --- a/src/interaction/siWork.js +++ b/src/interaction/siWork.js @@ -105,14 +105,16 @@ App.UI.SlaveInteract.work = function(slave, refresh) { span.append(`Transfer to: `); span.appendChild(App.UI.jobLinks.transfersFragment(slave.ID)); } - - div = document.createElement('div'); - div.id = "fucktoy-pref"; - div.append(fucktoyPref()); - span.appendChild(div); } el.append(span); + if (slave.assignment === Job.FUCKTOY || slave.assignment === Job.MASTERSUITE || slave.assignment === Job.CONCUBINE) { + div = document.createElement('div'); + div.id = "fucktoy-pref"; + div.append(fucktoyPref()); + el.append(div); + } + if (slave.assignment === Job.WHORE || slave.assignment === Job.BROTHEL) { div = document.createElement('div'); div.textContent = `Whoring Target: `; @@ -786,7 +788,7 @@ App.UI.SlaveInteract.work = function(slave, refresh) { } function fucktoyPref() { - const el = document.createElement('div'); + const el = new DocumentFragment(); let links = []; function appendLink(text, toyHole, enabled, disabledText) { @@ -799,24 +801,22 @@ App.UI.SlaveInteract.work = function(slave, refresh) { links.push(link); } - if ((slave.assignment === App.Data.Facilities.penthouse.jobs.fucktoy.assignment) || (slave.assignment === App.Data.Facilities.masterSuite.jobs.fucktoy.assignment) || (slave.assignment === App.Data.Facilities.masterSuite.manager.assignment)) { - App.UI.DOM.appendNewElement("span", el, "Fucktoy use preference:", "story-label"); - el.append(` `); + App.UI.DOM.appendNewElement("span", el, "Fucktoy use preference:"); + el.append(` `); - const hole = App.UI.DOM.appendNewElement('span', el, `${slave.toyHole}. `); - hole.style.fontWeight = "bold"; + const hole = App.UI.DOM.appendNewElement('span', el, `${slave.toyHole}. `); + hole.style.fontWeight = "bold"; - appendLink('Mouth', 'mouth', true); - appendLink('Tits', 'boobs', true); - if (slave.vagina >= 0) { - appendLink('Pussy', 'pussy', slave.vagina > 0 && canDoVaginal(slave), `Take ${his} virginity before giving ${his} pussy special attention`); - } - appendLink('Ass', 'ass', (slave.anus > 0) && canDoAnal(slave), `Take ${his} anal virginity before giving ${his} ass special attention`); - if (slave.dick > 0 && canPenetrate(slave)) { - appendLink('Dick', 'dick', true); - } - appendLink('No Preference', "all her holes", true); + appendLink('Mouth', 'mouth', true); + appendLink('Tits', 'boobs', true); + if (slave.vagina >= 0) { + appendLink('Pussy', 'pussy', slave.vagina > 0 && canDoVaginal(slave), `Take ${his} virginity before giving ${his} pussy special attention`); + } + appendLink('Ass', 'ass', (slave.anus > 0) && canDoAnal(slave), `Take ${his} anal virginity before giving ${his} ass special attention`); + if (slave.dick > 0 && canPenetrate(slave)) { + appendLink('Dick', 'dick', true); } + appendLink('No Preference', "all her holes", true); function generateLink(linkDesc) { const span = document.createElement("span");