diff --git a/js/003-data/gameVariableData.js b/js/003-data/gameVariableData.js index ae3c8f9efb2a65dd092c3192a8db45b2399a3512..77854e982ad0a54bd4b81558fee78ffe1129e132 100644 --- a/js/003-data/gameVariableData.js +++ b/js/003-data/gameVariableData.js @@ -1040,8 +1040,7 @@ App.Data.resetOnNGPlus = { Bodyguard: 0, /** @type {FC.SlaveStateOrZero} */ Madam: 0, - /** @type {FC.SlaveStateOrZero} */ - DJ: 0, + djID: 0, /** @type {FC.SlaveStateOrZero} */ Milkmaid: 0, milkmaidImpregnates: 0, diff --git a/js/003-data/policiesData.js b/js/003-data/policiesData.js index de749cfe5e10be7c2214bd6f346a965719c9f51c..e5be2e88b0319cee5ad61244fd044c3367071b55 100644 --- a/js/003-data/policiesData.js +++ b/js/003-data/policiesData.js @@ -497,12 +497,12 @@ App.Data.Policies.Selection = { } } ], - "mercenariesHelpCorp": [ + "policies.raidingMercenaries": [ { title: "Raiding Mercenaries", text: "you will allow your mercenaries to occasionally conduct a raid directly for your benefit.", activatedText: "you are allowing your mercenaries to occasionally raid for your direct benefit.", - requirements: function() { return (V.mercenaries > 0); }, + requirements: function() { return (V.mercenaries > 0) && (V.mercenariesHelpCorp > 0); }, get note() { return `Will cost ${cashFormat(policies.cost())} weekly to maintain`; } } ], diff --git a/src/002-config/fc-version.js b/src/002-config/fc-version.js index c798b23d14ca5076fcdb3b97021d744dd78d1410..95c56fcc0df620841bf4063ade116cdcc98f4d10 100644 --- a/src/002-config/fc-version.js +++ b/src/002-config/fc-version.js @@ -2,5 +2,5 @@ App.Version = { base: "0.10.7.1", // The vanilla version the mod is based off of, this should never be changed. pmod: "3.5.4", commitHash: null, - release: 1075 + release: 1076 }; diff --git a/src/004-base/specialSlavesProxy.js b/src/004-base/specialSlavesProxy.js index 64b2870e0ac6680fbdcc7be2c58a61a8919d78b1..92622b4efbf40a734577d4532cc4fc371868ca8d 100644 --- a/src/004-base/specialSlavesProxy.js +++ b/src/004-base/specialSlavesProxy.js @@ -12,7 +12,7 @@ App.SpecialSlavesProxy = class SpecialSlavesProxy { return V.Concubine; } get DJ() { - return V.DJ; + return slaveStateById(V.djID); } get Farmer() { return V.Farmer; diff --git a/src/data/backwardsCompatibility/datatypeCleanup.js b/src/data/backwardsCompatibility/datatypeCleanup.js index 79d17e6b4fef8df67fbceb4607de100ae1c73b8f..4564df3e1027f97c63cd859987bea7823421d2c2 100644 --- a/src/data/backwardsCompatibility/datatypeCleanup.js +++ b/src/data/backwardsCompatibility/datatypeCleanup.js @@ -1659,7 +1659,7 @@ globalThis.FacilityDatatypeCleanup = (function() { V.club = Math.max(+V.club, 0) || 0; V.clubUpgradePDAs = Math.clamp(+V.clubUpgradePDAs, 0, 1) || 0; /* madam */ - V.DJ = V.slaves.find(s => s.assignment === Job.DJ) || 0; + V.djID = findSlaveId(s => s.assignment === Job.DJ); V.DJignoresFlaws = Math.clamp(+V.DJignoresFlaws, 0, 1) || 0; } diff --git a/src/endWeek/endWeek.js b/src/endWeek/endWeek.js index c949a7664ca7e789fa2768a3ca17a2e1a296f9e9..e905a4a5fd2eb3dd55c60f8510de9c84504744c6 100644 --- a/src/endWeek/endWeek.js +++ b/src/endWeek/endWeek.js @@ -292,9 +292,7 @@ globalThis.endWeek = (function() { V.unMadam = 0; V.madamCashBonus = 0; V.whorePriceAdjustment = {}; - V.DJ = 0; V.unDJ = 0; - V.DJRepBonus = 0; V.Milkmaid = 0; V.Farmer = 0; V.Concubine = 0; diff --git a/src/endWeek/healthFunctions.js b/src/endWeek/healthFunctions.js index b8252954db6506ee1b98fb09d045d24e7d8d5556..6b013a041e06b7b387094a7ae8ce2d69bae0d93e 100644 --- a/src/endWeek/healthFunctions.js +++ b/src/endWeek/healthFunctions.js @@ -342,7 +342,7 @@ globalThis.willWorkToDeath = function(slave) { return true; } else if (V.Madam !== 0 && (slave.assignment === Job.BROTHEL || (slave.assignment === Job.WHORE && V.brothel > 0 && V.universalRulesFacilityWork === 1 && V.brothelSpots > 0))) { return true; - } else if (V.DJ !== 0 && (slave.assignment === Job.CLUB || (slave.assignment === Job.PUBLIC && V.club > 0 && V.universalRulesFacilityWork === 1 && V.clubSpots > 0))) { + } else if (S.DJ && (slave.assignment === Job.CLUB || (slave.assignment === Job.PUBLIC && V.club > 0 && V.universalRulesFacilityWork === 1 && V.clubSpots > 0))) { return true; } return false; diff --git a/src/endWeek/saServeThePublic.js b/src/endWeek/saServeThePublic.js index 43a8ed4fe5390045911d3b0b5582a603e3e3c19a..0ba7049fd4e6f60cc534eb59b12ddcef99ea34e0 100644 --- a/src/endWeek/saServeThePublic.js +++ b/src/endWeek/saServeThePublic.js @@ -142,36 +142,36 @@ App.SlaveAssignment.serveThePublic = (function() { if ((slave.hears === -1 && slave.earwear !== "hearing aids") || (slave.hears === 0 && slave.earwear === "muffling ear plugs") || (slave.hears === -2)) { r += ` ${His} inability to move to the rhythm of the music is very off putting to those looking to party.`; } - if (V.DJ !== 0) { - const DJpronouns = getPronouns(V.DJ); - if (V.DJRepBonus > 0) { + if (S.DJ) { + const DJpronouns = getPronouns(S.DJ); + if (DJRepBonus() > 0) { if (slave.assignment === Job.PUBLIC) { r += ` Working`; } else { r += ` Living and working`; } - r += ` out of the club, ${he} comes under ${SlaveFullName(V.DJ)}'s `; - if (V.DJRepBonus < 0.1) { + r += ` out of the club, ${he} comes under ${SlaveFullName(S.DJ)}'s `; + if (DJRepBonus() < 0.1) { r += `completely inept`; - } else if (V.DJRepBonus < 0.2) { + } else if (DJRepBonus() < 0.2) { r += `unskilled`; - } else if (V.DJRepBonus < 0.3) { + } else if (DJRepBonus() < 0.3) { r += `skillful`; } else { r += `masterful`; } r += ` leadership.`; - if (V.DJ.face > 40 && (V.DJ.intelligence + V.DJ.intelligenceImplant > 50)) { + if (S.DJ.face > 40 && (S.DJ.intelligence + S.DJ.intelligenceImplant > 50)) { if (slave.devotion > 20) { r += ` The DJ is such a gorgeous diva that ${he}'s swept along by ${DJpronouns.possessive} charisma, and does ${his} best to be a worthy part of ${DJpronouns.possessive} entourage.`; } } if (V.DJignoresFlaws !== 1) { if (!["abusive", "anal addict", "attention whore", "breast growth", "breeder", "cum addict", "malicious", "neglectful", "none", "self hating"].includes(slave.sexualFlaw) && jsRandom(1, 100) > 90) { - r += ` ${SlaveFullName(V.DJ)} manages to <span class="flaw break">break</span> ${slave.slaveName} of ${his} sexual flaws.`; + r += ` ${SlaveFullName(S.DJ)} manages to <span class="flaw break">break</span> ${slave.slaveName} of ${his} sexual flaws.`; slave.sexualFlaw = "none"; } else if (slave.behavioralFlaw !== "none" && jsRandom(1, 100) > 90) { - r += ` ${SlaveFullName(V.DJ)} manages to <span class="flaw break">break</span> ${slave.slaveName} of ${his} flaws.`; + r += ` ${SlaveFullName(S.DJ)} manages to <span class="flaw break">break</span> ${slave.slaveName} of ${his} flaws.`; slave.behavioralFlaw = "none"; } } @@ -311,8 +311,8 @@ App.SlaveAssignment.serveThePublic = (function() { r += ` ${He} spends reduced hours working the floor in ${V.clubName} in order to <span class="green">offset ${his} lack of rest.</span>`; } else if (slave.health.tired + 15 >= 90 && !willWorkToDeath(slave)) { r += ` ${He} attempts to turn down citizens due to ${his} exhaustion, but can do little to stop it or the resulting `; - if (V.DJ !== 0) { - r += `<span class="trust dec">severe punishment</span> by ${V.DJ.slaveName}. ${His} <span class="devotion dec">reluctance</span> is worked around by your watchful DJ, preventing citizens from ever realizing ${his} intent.`; + if (S.DJ) { + r += `<span class="trust dec">severe punishment</span> by ${S.DJ.slaveName}. ${His} <span class="devotion dec">reluctance</span> is worked around by your watchful DJ, preventing citizens from ever realizing ${his} intent.`; } else { r += `<span class="trust dec">severe punishment.</span> ${He} <span class="devotion dec">purposefully underperforms,</span> choosing ${his} overall well-being over the consequences, <span class="reputation dec">aggravating citizens and damaging the establishment's image.</span>`; repX(forceNeg(50), "disobedience", slave); @@ -334,8 +334,8 @@ App.SlaveAssignment.serveThePublic = (function() { r += ` ${He} spends reduced hours serving in order to <span class="green">offset ${his} lack of rest.</span>`; } else if (slave.health.tired + 15 >= 90 && !willWorkToDeath(slave)) { r += ` ${He} attempts to turn down citizens due to ${his} exhaustion, but can do little to avoid it or the resulting `; - if (V.club > 0 && V.universalRulesFacilityWork === 1 && V.clubSpots > 0 && V.DJ !== 0) { - r += `<span class="trust dec">severe punishment</span> by ${V.DJ.slaveName}. ${His} <span class="devotion dec">reluctance</span> is worked around by your watchful DJ, preventing citizens from ever realizing ${his} intent.`; + if (V.club > 0 && V.universalRulesFacilityWork === 1 && V.clubSpots > 0 && S.DJ) { + r += `<span class="trust dec">severe punishment</span> by ${S.DJ.slaveName}. ${His} <span class="devotion dec">reluctance</span> is worked around by your watchful DJ, preventing citizens from ever realizing ${his} intent.`; } else { r += `<span class="trust dec">severe punishment.</span> ${He} <span class="devotion dec">purposefully underperforms,</span> choosing ${his} overall well-being over the consequences, <span class="reputation dec">causing a scene and damaging the image of your public servants.</span>`; repX(forceNeg(100), "disobedience", slave); diff --git a/src/endWeek/slaveAssignmentReport.js b/src/endWeek/slaveAssignmentReport.js index 9ff7803af55461ccb7253aa3a636654ce99045b8..4fa4fce42e4cebccf09fdc6c7a370406c61fa905 100644 --- a/src/endWeek/slaveAssignmentReport.js +++ b/src/endWeek/slaveAssignmentReport.js @@ -515,7 +515,7 @@ App.EndWeek.slaveAssignmentReport = function() { } else if (V.unDJ === 5) { _printSlaveUnassignedNote(slave, "can no longer hear"); } - if (V.DJ === 0) { + if (V.djID === 0) { removeJob(slave, Job.DJ); } break; diff --git a/src/events/reRelativeRecruiter.js b/src/events/reRelativeRecruiter.js index 18469448a5525b9578299418306adae2412efdc8..07957119502fbeff4b069c7b23e37d87c4cefca6 100644 --- a/src/events/reRelativeRecruiter.js +++ b/src/events/reRelativeRecruiter.js @@ -285,7 +285,7 @@ App.Events.RERelativeRecruiter = class RERelativeRecruiter extends App.Events.Ba App.Events.addParagraph(frag, t); t = []; - t.push(`You look up the ${_this.params.relative}. ${He2} costs ${cashFormat(cost)}, a bargain, but you won't be able to inspect ${him2} beyond his likely resemblance to ${eventSlave.slaveName}.`); + t.push(`You look up the ${_this.params.relative}. ${He2} costs ${cashFormat(cost)}, a bargain, but you won't be able to inspect ${him2} beyond ${his2} likely resemblance to ${eventSlave.slaveName}.`); t.push(_this._getBackgroundDescription(V.activeSlave, _this.params.background)); App.Events.addParagraph(frag, t); @@ -561,7 +561,8 @@ App.Events.RERelativeRecruiter = class RERelativeRecruiter extends App.Events.Ba } const origSlave = BaseSlave(); - const genepoolRec = App.Entity.Utils.GenePoolRecordCleanup(V.genePool.find(s => s.ID === _this.actors[0])); + const genepoolRec = V.genePool.find(s => s.ID === _this.actors[0]); + App.Entity.Utils.GenePoolRecordCleanup(genepoolRec); Object.assign(origSlave, genepoolRec); const newSlave = generateRelatedSlave(origSlave, _this.params.relative); diff --git a/src/js/assayJS.js b/src/js/assayJS.js index dd9544d81470e8ed762d1baa45e3853b85ac5fe0..5be576962ca5afce0b39732b498a65cd20d8935b 100644 --- a/src/js/assayJS.js +++ b/src/js/assayJS.js @@ -78,7 +78,7 @@ globalThis.inferiorRaceP = function(slave) { */ globalThis.isLeaderP = function(slave) { /** @type {FC.SlaveStateOrZero[]} */ - const leaders = [V.HeadGirl, V.Bodyguard, V.Recruiter, V.Concubine, S.Nurse, S.Attendant, V.Matron, V.Madam, V.DJ, V.Milkmaid, V.Farmer, S.Stewardess, S.Schoolteacher, S.Wardeness]; + const leaders = [V.HeadGirl, V.Bodyguard, V.Recruiter, V.Concubine, S.Nurse, S.Attendant, V.Matron, V.Madam, S.DJ, V.Milkmaid, V.Farmer, S.Stewardess, S.Schoolteacher, S.Wardeness]; return leaders.some(leader => leader && leader.ID && leader.ID === slave.ID); }; diff --git a/src/js/assignJS.js b/src/js/assignJS.js index 3924410b8a0dc7acb5bd03625d95034d2d997257..c21f0bf8a8d75a7e3dd21dffec468cc1f8cda2dc 100644 --- a/src/js/assignJS.js +++ b/src/js/assignJS.js @@ -508,8 +508,8 @@ globalThis.removeJob = function(slave, assignment, saveRecord = false) { V.Bodyguard = 0; } else if (V.Madam !== 0 && slave.ID === V.Madam.ID) { V.Madam = 0; - } else if (V.DJ !== 0 && slave.ID === V.DJ.ID) { - V.DJ = 0; + } else if (V.djID === slave.ID) { + V.djID = 0; } else if (V.Milkmaid !== 0 && slave.ID === V.Milkmaid.ID) { V.Milkmaid = 0; } else if (V.Farmer !== 0 && slave.ID === V.Farmer.ID) { diff --git a/src/js/economyJS.js b/src/js/economyJS.js index 5a1c2afdc3711f96811f7e0f639e82eba9f526c0..034448782ce4e313258b8bafe87304f72a471a41 100644 --- a/src/js/economyJS.js +++ b/src/js/economyJS.js @@ -1,3 +1,48 @@ +globalThis.DJRepBonus = function() { + let value = 0; + const djIntel = S.DJ.intelligence + S.DJ.intelligenceImplant; + if (S.DJ.relationship === -3 && S.DJ.devotion > 50) { + value += 0.1; + // $He tries $his best to be your energetic, cheerful $wife. + } + if (!canSee(S.DJ)) { + value += 0.15; + } + if ( S.DJ.skill.entertainment > 10 && S.DJ.skill.entertainment <= 30) { + value += 0.05; + // $DJ.slaveName's basic skills marginally <span class="green">improve</span> the atmosphere in $clubName. + } else if (S.DJ.skill.entertainment <= 60) { + value += 0.1; + // $DJ.slaveName's skills <span class="green">improve</span> the atmosphere in $clubName. + } else if (S.DJ.skill.entertainment < 100) { + value += 0.15; + // $DJ.slaveName's skills greatly <span class="green">improve</span> the atmosphere in $clubName. + } else if (S.DJ.skill.entertainment >= 100) { + value += 0.20; + // $DJ.slaveName's mastery immensely <span class="green">;improves</span> the atmosphere in $clubName. + } + if (S.DJ.muscles > 5 && S.DJ.muscles <= 95) { + value += 0.05; + // $His toned body helps $him lead $his fellow club sluts by letting $him dance all night. + } + if (djIntel > 15) { + value += 0.05 * Math.floor((-0.00008 * djIntel * djIntel) + (0.0337 * djIntel) + 0.5); + // $He's smart enough to make an actual contribution to the music, greatly enhancing the entire experience. + } + if (S.DJ.face > 95) { + value += 0.05; + // $His great beauty is a further draw, even when $he's in $his DJ booth, but especially when $he comes out to dance. + } + if (setup.DJCareers.includes(S.DJ.career)) { + value += 0.05; + // $He has musical experience from $his life before $he was a slave, a grounding that gives $his tracks actual depth. + } else if (S.DJ.skill.DJ >= V.masteredXP) { + value += 0.05; + // $He has musical experience from working for you, giving $his tracks actual depth. + } + return value; +}; + globalThis.CategoryAssociatedGroup = Object.freeze({ PENTHOUSE: [ 'slaveAssignmentRest', @@ -1424,72 +1469,27 @@ globalThis.slaveJobValues = function(lowerClassSexDemandRef, middleClassSexDeman } // Accounting for the DJ. - V.DJ = V.slaves.find(s => { - return s.assignment === Job.DJ; - }); - if (V.DJ !== 0) { - if (!canTalk(V.DJ)) { - V.DJ = 0; + if (S.DJ) { + if (!canTalk(S.DJ)) { + V.djID = 0; V.unDJ = 1; - } else if (V.DJ.preg > 37 && V.DJ.broodmother === 2) { - V.DJ = 0; + } else if (S.DJ.preg > 37 && S.DJ.broodmother === 2) { + V.djID = 0; V.unDJ = 2; - } else if (V.DJ.fetish === "mindbroken") { - V.DJ = 0; + } else if (S.DJ.fetish === "mindbroken") { + V.djID = 0; V.unDJ = 3; - } else if (!canWalk(V.DJ)) { - V.DJ = 0; + } else if (!canWalk(S.DJ)) { + V.djID = 0; V.unDJ = 4; - } else if (!canHear(V.DJ)) { - V.DJ = 0; + } else if (!canHear(S.DJ)) { + V.djID = 0; V.unDJ = 5; } } - if (V.DJ !== 0) { - const djIntel = V.DJ.intelligence + V.DJ.intelligenceImplant; - V.DJRepBonus = 0; - if (V.DJ.relationship === -3 && V.DJ.devotion > 50) { - V.DJRepBonus += 0.1; - // $He tries $his best to be your energetic, cheerful $wife. - } - if (!canSee(V.DJ)) { - V.DJRepBonus += 0.15; - } - if ( V.DJ.skill.entertainment > 10 && V.DJ.skill.entertainment <= 30) { - V.DJRepBonus += 0.05; - // $DJ.slaveName's basic skills marginally <span class="green">improve</span> the atmosphere in $clubName. - } else if (V.DJ.skill.entertainment <= 60) { - V.DJRepBonus += 0.1; - // $DJ.slaveName's skills <span class="green">improve</span> the atmosphere in $clubName. - } else if (V.DJ.skill.entertainment < 100) { - V.DJRepBonus += 0.15; - // $DJ.slaveName's skills greatly <span class="green">improve</span> the atmosphere in $clubName. - } else if (V.DJ.skill.entertainment >= 100) { - V.DJRepBonus += 0.20; - // $DJ.slaveName's mastery immensely <span class="green">;improves</span> the atmosphere in $clubName. - } - if (V.DJ.muscles > 5 && V.DJ.muscles <= 95) { - V.DJRepBonus += 0.05; - // $His toned body helps $him lead $his fellow club sluts by letting $him dance all night. - } - if (djIntel > 15) { - V.DJRepBonus += 0.05 * Math.floor((-0.00008 * djIntel * djIntel) + (0.0337 * djIntel) + 0.5); - // $He's smart enough to make an actual contribution to the music, greatly enhancing the entire experience. - } - if (V.DJ.face > 95) { - V.DJRepBonus += 0.05; - // $His great beauty is a further draw, even when $he's in $his DJ booth, but especially when $he comes out to dance. - } - if (setup.DJCareers.includes(V.DJ.career)) { - V.DJRepBonus += 0.05; - // $He has musical experience from $his life before $he was a slave, a grounding that gives $his tracks actual depth. - } else if (V.DJ.skill.DJ >= V.masteredXP) { - V.DJRepBonus += 0.05; - // $He has musical experience from working for you, giving $his tracks actual depth. - } - + if (S.DJ) { // The DJ adding to 'club' - SJVClub(V.slaves[V.slaveIndices[V.DJ.ID]]); + SJVClub(S.DJ); } // Checking for space in the club @@ -1675,7 +1675,7 @@ globalThis.slaveJobValues = function(lowerClassSexDemandRef, middleClassSexDeman } } if (s.assignment === Job.CLUB || toTheClub === 1) { - beautyMultiplier += V.DJRepBonus; + beautyMultiplier += DJRepBonus(); if (canHear(s) === false) { beautyMultiplier -= 0.65; // $His inability to move to the rhythm of the music is very off putting to those looking to party. diff --git a/src/npc/descriptions/style/clothing.js b/src/npc/descriptions/style/clothing.js index 8ef339077f185d7ba19c8cfb57c2c68f57dc1e0e..21b118bd427eeab4fa4fbcb16a98663710f18ad6 100644 --- a/src/npc/descriptions/style/clothing.js +++ b/src/npc/descriptions/style/clothing.js @@ -787,7 +787,7 @@ App.Desc.clothing = function(slave, {market, eventDescription} = {}) { r.push(`${His} uniform is pinned with the`); if (slave.ID === V.Bodyguard.ID || slave.ID === V.HeadGirl.ID || slave.ID === V.Recruiter.ID || slave.ID === V.Concubine.ID) { r.push(`golden whip and manacles insignia of a senior slave officer,`); - } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.DJ.ID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { + } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.djID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { r.push(`golden manacles insignia of a junior slave officer,`); } else if ((slave.skill.combat > 0) && getLimbCount(slave, 105) > 0) { r.push(`silver spear and manacles insignia of an augmented slave soldier,`); @@ -809,7 +809,7 @@ App.Desc.clothing = function(slave, {market, eventDescription} = {}) { r.push(`${His} uniform is pinned with the`); if (slave.ID === V.Bodyguard.ID || slave.ID === V.HeadGirl.ID || slave.ID === V.Recruiter.ID || slave.ID === V.Concubine.ID) { r.push(`golden whip and manacles insignia of a senior slave officer,`); - } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.DJ.ID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { + } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.djID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { r.push(`golden manacles insignia of a junior slave officer,`); } else if ((slave.skill.combat > 0) && getLimbCount(slave, 105)) { r.push(`silver spear and manacles insignia of an augmented slave soldier,`); @@ -831,7 +831,7 @@ App.Desc.clothing = function(slave, {market, eventDescription} = {}) { r.push(`${His} uniform is pinned with the`); if ((slave.ID === V.Bodyguard.ID) || (slave.ID === V.HeadGirl.ID) || (slave.ID === V.Recruiter.ID) || (slave.ID === V.Concubine.ID)) { r.push(`golden whip and manacles insignia of a senior slave officer,`); - } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.DJ.ID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { + } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.djID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { r.push(`golden manacles insignia of a junior slave officer,`); } else if ((slave.skill.combat > 0) && getLimbCount(slave, 105)) { r.push(`silver spear and manacles insignia of an augmented slave soldier,`); @@ -853,7 +853,7 @@ App.Desc.clothing = function(slave, {market, eventDescription} = {}) { r.push(`${His} uniform is pinned with the`); if ((slave.ID === V.Bodyguard.ID) || (slave.ID === V.HeadGirl.ID) || (slave.ID === V.Recruiter.ID) || (slave.ID === V.Concubine.ID)) { r.push(`golden whip and manacles insignia of a senior slave officer,`); - } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.DJ.ID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { + } else if ((slave.ID === V.Madam.ID) || (slave.ID === V.NurseID) || (slave.ID === V.AttendantID) || (slave.ID === V.Matron.ID) || (slave.ID === V.djID) || (slave.ID === V.Milkmaid.ID) || (slave.ID === V.Farmer.ID) || (slave.ID === V.StewardessID) || (slave.ID === V.SchoolteacherID) || (slave.ID === V.WardenessID)) { r.push(`golden manacles insignia of a junior slave officer,`); } else if ((slave.skill.combat > 0) && getLimbCount(slave, 105)) { r.push(`silver spear and manacles insignia of an augmented slave soldier,`); diff --git a/src/uncategorized/PESS.tw b/src/uncategorized/PESS.tw index f369a72f3c1cef8d77b4d4da4e268ed40c2e15c2..6c3762e4ba3e20be09c6d6b62e3c4f9f7a322d19 100644 --- a/src/uncategorized/PESS.tw +++ b/src/uncategorized/PESS.tw @@ -46,7 +46,7 @@ <<case "madam strategy">> <<set $activeSlave = getSlave($Madam.ID)>> <<case "DJ publicity">> - <<set $activeSlave = getSlave($DJ.ID)>> + <<set $activeSlave = getSlave($djID)>> <<case "tired milkmaid" "tired collectrix">> <<set $activeSlave = getSlave($Milkmaid.ID)>> <<case "loving concubine">> diff --git a/src/uncategorized/RESS.tw b/src/uncategorized/RESS.tw index 92b5101f0b6c23ebf3fa9eb8132874f56c182ff7..08136f0578b437d766014341087575a220b29d26 100644 --- a/src/uncategorized/RESS.tw +++ b/src/uncategorized/RESS.tw @@ -3080,7 +3080,7 @@ As you pass by the area of the penthouse where slaves sleep one morning, you're <br><br> -You recognize the tune: it's one of <<if $DJ != 0>>$DJ.slaveName's most popular tracks<<elseif $club != 0>>the most popular tracks in $clubName<<else>>the most popular house tracks in the Free City<</if>>, and it's made for sexy dancing. Shaking $his +You recognize the tune: it's one of <<if _S.DJ>>_S.DJ.slaveName's most popular tracks<<elseif $club != 0>>the most popular tracks in $clubName<<else>>the most popular house tracks in the Free City<</if>>, and it's made for sexy dancing. Shaking $his <<if $activeSlave.hips > 2>> <<if $activeSlave.weight > 30>> awe inspiring, soft diff --git a/src/uncategorized/club.tw b/src/uncategorized/club.tw index 74fe3887039bebc101bcab61b9c8f4e59a3b3bce..2595248737fa5521982e80daea7032a1845820b2 100644 --- a/src/uncategorized/club.tw +++ b/src/uncategorized/club.tw @@ -140,9 +140,9 @@ $clubNameCaps is dotted with pretty, flirtatious slaves, stripping on stages, serving drinks, and dancing. They're very willing to suck patrons off in the open or give a public handjob, and there are little private rooms for them to use when engaging in heavier intercourse. <<elseif _CL > 0>> There are a few pretty, flirtatious slaves, stripping on stages, serving drinks, and dancing. They're very willing to suck patrons off in the open or give a public handjob, and there are little private rooms for them to use when engaging in heavier intercourse. - <<elseif $DJ != 0>> - <<setLocalPronouns $DJ>> - $clubNameCaps is doing business normally, without a complement of sex slaves to spice things up. $DJ.slaveName is alone in $clubName, and can accomplish little by $himself. + <<elseif _S.DJ>> + <<setLocalPronouns _S.DJ>> + $clubNameCaps is doing business normally, without a complement of sex slaves to spice things up. _S.DJ.slaveName is alone in $clubName, and can accomplish little by $himself. <<else>> $clubNameCaps is doing business normally, without a complement of sex slaves to spice things up. <div class="choices" style="font-style:normal"> @@ -257,12 +257,12 @@ </div> <div> - <<if $DJ != 0>> - <<if $DJignoresFlaws != 1>> - $DJ.slaveName will attempt to fix flaws in <<print $clubName>>'s sluts. + <<if _S.DJ>> + <<if _S.DJignoresFlaws != 1>> + _S.DJ.slaveName will attempt to fix flaws in <<print $clubName>>'s sluts. [[Ignore flaws|Club][$DJignoresFlaws = 1]] <<else>> - $DJ.slaveName has been instructed to ignore flaws in <<print $clubName>>'s sluts. + _S.DJ.slaveName has been instructed to ignore flaws in <<print $clubName>>'s sluts. [[Fix flaws|Club][$DJignoresFlaws = 0]] <</if>> <</if>> diff --git a/src/uncategorized/clubReport.tw b/src/uncategorized/clubReport.tw index 96f2a61ae0acc1a872b7f97a0460d4db7b6336d7..86815abbe5cc6cae26a35875306c3ed78986111e 100644 --- a/src/uncategorized/clubReport.tw +++ b/src/uncategorized/clubReport.tw @@ -10,44 +10,41 @@ <!-- Statistics gathering; income is rep boosts in numbers, and profit will be rep per cash unit, or cash unit per rep --> <<set $facility = $facility || {}, $facility.club = initFacilityStatistics($facility.club)>> -<<if $DJ != 0>> - <<set _FLs = $slaveIndices[$DJ.ID]>> - - <<if ($slaves[_FLs].health.condition < -80)>> - <<run improveCondition($slaves[_FLs], 20)>> - <<elseif $slaves[_FLs].health.condition < -40>> - <<run improveCondition($slaves[_FLs], 15)>> - <<elseif $slaves[_FLs].health.condition < 0>> - <<run improveCondition($slaves[_FLs], 10)>> - <<elseif $slaves[_FLs].health.condition < 90>> - <<run improveCondition($slaves[_FLs], 7)>> +<<if _S.DJ>> + <<if (_S.DJ.health.condition < -80)>> + <<run improveCondition(_S.DJ, 20)>> + <<elseif _S.DJ.health.condition < -40>> + <<run improveCondition(_S.DJ, 15)>> + <<elseif _S.DJ.health.condition < 0>> + <<run improveCondition(_S.DJ, 10)>> + <<elseif _S.DJ.health.condition < 90>> + <<run improveCondition(_S.DJ, 7)>> <</if>> - <<if $slaves[_FLs].devotion <= 60>> - <<set $slaves[_FLs].devotion += 5>> + <<if _S.DJ.devotion <= 60>> + <<set _S.DJ.devotion += 5>> <</if>> - <<if $slaves[_FLs].trust < 60>> - <<set $slaves[_FLs].trust += 3>> + <<if _S.DJ.trust < 60>> + <<set _S.DJ.trust += 3>> <</if>> - <<if $slaves[_FLs].fetishStrength <= 95>> - <<if $slaves[_FLs].fetish != "humiliation">> - <<if fetishChangeChance($slaves[_FLs]) > random(0,100)>> - <<set _FLsFetish = 1, $slaves[_FLs].fetishKnown = 1, $slaves[_FLs].fetish = "humiliation">> + <<if _S.DJ.fetishStrength <= 95>> + <<if _S.DJ.fetish != "humiliation">> + <<if fetishChangeChance(_S.DJ) > random(0,100)>> + <<set _FLsFetish = 1, _S.DJ.fetishKnown = 1, _S.DJ.fetish = "humiliation">> <</if>> - <<elseif $slaves[_FLs].fetishKnown == 0>> - <<set _FLsFetish = 1, $slaves[_FLs].fetishKnown = 1>> + <<elseif _S.DJ.fetishKnown == 0>> + <<set _FLsFetish = 1, _S.DJ.fetishKnown = 1>> <<else>> - <<set _FLsFetish = 2, $slaves[_FLs].fetishStrength += 4>> + <<set _FLsFetish = 2, _S.DJ.fetishStrength += 4>> <</if>> <</if>> - <<if $slaves[_FLs].rules.living != "luxurious">> - <<set $slaves[_FLs].rules.living = "luxurious">> + <<if _S.DJ.rules.living != "luxurious">> + <<set _S.DJ.rules.living = "luxurious">> <</if>> /% Make sure we have registered living expenses as for any other slave %/ - <<run getSlaveStatisticData($DJ, $facility.club)>> - <<set $DJ = $slaves[_FLs]>> - <<setLocalPronouns $DJ>> - <<= SlaveFullName($DJ)>> is performing as the DJ. - <<if $DJ.relationship == -3 && $DJ.devotion > 50>> + <<run getSlaveStatisticData(_S.DJ, $facility.club)>> + <<setLocalPronouns _S.DJ>> + <<= SlaveFullName(_S.DJ)>> is performing as the DJ. + <<if _S.DJ.relationship == -3 && _S.DJ.devotion > 50>> $He tries $his best to be your energetic, cheerful $wife. <</if>> <<if (_FLsFetish == 1)>> @@ -55,40 +52,40 @@ <<elseif (_FLsFetish == 2)>> Every day $he gets to enjoy hundreds of stares on $his skin, and @@.lightsalmon;becomes more of an exhibitionist.@@ <</if>> - <<if getBestVision($DJ) === 0>> + <<if getBestVision(_S.DJ) === 0>> $His lack of eyesight doesn't slow $him down; rather, it strengthens $his other senses. $His tracks have a distinct sound, since $he experiences noise as $his sight. <</if>> - <<if ($DJ.skill.entertainment <= 10)>> - Though $DJ.slaveName does $his best to lead on the club, with $his lack of skill $he can do little. - <<elseif ($DJ.skill.entertainment <= 30)>> - $DJ.slaveName's basic skills marginally @@.green;improve@@ the atmosphere in $clubName. - <<elseif ($DJ.skill.entertainment <= 60)>> - $DJ.slaveName's skills @@.green;improve@@ the atmosphere in $clubName. - <<elseif ($DJ.skill.entertainment < 100)>> - $DJ.slaveName's skills greatly @@.green;improve@@ the atmosphere in $clubName. - <<elseif ($DJ.skill.entertainment >= 100)>> - $DJ.slaveName's mastery immensely @@.green;improves@@ the atmosphere in $clubName. + <<if (_S.DJ.skill.entertainment <= 10)>> + Though _S.DJ.slaveName does $his best to lead on the club, with $his lack of skill $he can do little. + <<elseif (_S.DJ.skill.entertainment <= 30)>> + _S.DJ.slaveName's basic skills marginally @@.green;improve@@ the atmosphere in $clubName. + <<elseif (_S.DJ.skill.entertainment <= 60)>> + _S.DJ.slaveName's skills @@.green;improve@@ the atmosphere in $clubName. + <<elseif (_S.DJ.skill.entertainment < 100)>> + _S.DJ.slaveName's skills greatly @@.green;improve@@ the atmosphere in $clubName. + <<elseif (_S.DJ.skill.entertainment >= 100)>> + _S.DJ.slaveName's mastery immensely @@.green;improves@@ the atmosphere in $clubName. <</if>> - <<if ($DJ.muscles > 5) && ($DJ.muscles <= 95)>> + <<if (_S.DJ.muscles > 5) && (_S.DJ.muscles <= 95)>> $His toned body helps $him lead $his fellow club sluts by letting $him dance all night. <</if>> - <<if ($DJ.intelligence+$DJ.intelligenceImplant > 15)>> + <<if (_S.DJ.intelligence+_S.DJ.intelligenceImplant > 15)>> $He's smart enough to make an actual contribution to the music, greatly enhancing the entire experience. <</if>> - <<if ($DJ.face > 95)>> + <<if (_S.DJ.face > 95)>> $His great beauty is a further draw, even when $he's in $his DJ booth, but especially when $he comes out to dance. <</if>> - <<if setup.DJCareers.includes($DJ.career)>> + <<if setup.DJCareers.includes(_S.DJ.career)>> $He has musical experience from $his life before $he was a slave, a grounding that gives $his tracks actual depth. - <<elseif $DJ.skill.DJ >= $masteredXP>> + <<elseif _S.DJ.skill.DJ >= $masteredXP>> $He has musical experience from working for you, giving $his tracks actual depth. <<else>> - <<set $slaves[_FLs].skill.DJ += random(1,Math.ceil(($DJ.intelligence+$DJ.intelligenceImplant)/15) + 8)>> + <<set _S.DJ.skill.DJ += random(1,Math.ceil((_S.DJ.intelligence+_S.DJ.intelligenceImplant)/15) + 8)>> <</if>> <<if (_DL + $clubSlavesGettingHelp < 10)>> <<set $i = _FLs>> /* apply following SA passages to facility leader */ - <<if ($legendaryEntertainerID == 0) && ($slaves[_FLs].prestige == 0) && ($slaves[_FLs].skill.entertainment >= 100) && ($slaves[_FLs].devotion > 50)>> - <<set $legendaryEntertainerID = $slaves[_FLs].ID>> + <<if ($legendaryEntertainerID == 0) && (_S.DJ.prestige == 0) && (_S.DJ.skill.entertainment >= 100) && (_S.DJ.devotion > 50)>> + <<set $legendaryEntertainerID = _S.DJ.ID>> <</if>> <br> Since $he doesn't have enough sluts in $clubName to make it worthwhile for $him to be on stage 24/7, $he spends $his extra time slutting it up $himself. $He has sex with $slaves[$i].sexAmount citizens, @@.green;pleasing them immensely,@@ since it's more appealing to fuck the DJ than some club slut. <<if $showEWD != 0>> @@ -105,18 +102,18 @@ <<if (_DL != 1)>>''The _DL slaves pleasing citizens in $clubName''<<else>>''The one slave pleasing citizens in $clubName''<</if>> worked hard to @@.green;increase your reputation@@ this week. <</if>> -<<if ($DJ != 0)>> +<<if _S.DJ>> <<set $i = _FLs>> /* apply following SA passages to facility leader */ <<if $showEWD != 0>> <br><br> /* 000-250-006 */ <<if $seeImages && $seeReportImages>> <div class="imageRef tinyImg"> - <<= SlaveArt($slaves[_FLs], 0, 0)>> + <<= SlaveArt(_S.DJ, 0, 0)>> </div> <</if>> /* 000-250-006 */ - <span class='slave-name'><<= SlaveFullName($slaves[_FLs])>></span> is performing as the DJ in $clubName. + <span class='slave-name'><<= SlaveFullName(_S.DJ)>></span> is performing as the DJ in $clubName. <br> <<= App.SlaveAssignment.choosesOwnClothes($slaves[$i])>> <<run tired($slaves[$i])>> @@ -140,7 +137,6 @@ <<include "SA devotion">> <</silently>> <</if>> - <<set $DJ = $slaves[_FLs]>> <</if>> <<if (_DL > 0)>> @@ -257,6 +253,6 @@ <</timed>> <</if>> -<<if _DL > 0 || $DJ != 0>> +<<if _DL > 0 || _S.DJ>> <br><br> <</if>> diff --git a/src/uncategorized/djSelect.tw b/src/uncategorized/djSelect.tw index a2c43a88d432afeb1590a8ca20cb3a21d21638a3..721284c8b0bf9be71ef29ac835897be55e377d5c 100644 --- a/src/uncategorized/djSelect.tw +++ b/src/uncategorized/djSelect.tw @@ -1,15 +1,14 @@ :: DJ Select [nobr jump-to-safe jump-hidden jump-from-safe] <<set $nextButton = "Back", $nextLink = "Club", $encyclopedia = "DJ">> -<<if ($DJ != 0)>> - <<set $DJ = getSlave($DJ.ID)>> - <<setLocalPronouns $DJ>> - <span class='slave-name'><<= SlaveFullName($DJ)>></span> is serving as your DJ.<br><br>$He will headline entertainment in $clubName. +<<if (_S.DJ)>> + <<setLocalPronouns _S.DJ>> + <span class='slave-name'><<= SlaveFullName(_S.DJ)>></span> is serving as your DJ.<br><br>$He will headline entertainment in $clubName. <<else>> You have not selected a DJ. <</if>> <br><br>''Appoint a DJ from your devoted slaves:'' -<br><br>[[None|Club][removeJob($DJ, "be the DJ")]] +<br><br>[[None|Club][removeJob(_S.DJ, "be the DJ")]] <br><br> <<print App.UI.SlaveList.facilityManagerSelection(App.Entity.facilities.club, "Club")>> diff --git a/src/uncategorized/randomNonindividualEvent.tw b/src/uncategorized/randomNonindividualEvent.tw index 92be7400d7536e8ec6225009174cee4887cccf52..fe1403fdd8e2953f137c2b85076c5be249e88c39 100644 --- a/src/uncategorized/randomNonindividualEvent.tw +++ b/src/uncategorized/randomNonindividualEvent.tw @@ -423,7 +423,7 @@ <<set $PESSevent.push("madam strategy")>> <</if>> - <<if ($DJ != 0) && (_L.club >= 5) && ($DJ.face > 95) && ($DJ.skill.entertainment >= 100)>> + <<if _S.DJ && (_L.club >= 5) && (_S.DJ.face > 95) && (_S.DJ.skill.entertainment >= 100)>> <<set $PESSevent.push("DJ publicity")>> <</if>> @@ -439,7 +439,7 @@ <<set $PETSevent.push("comforting attendant")>> <</if>> - <<if _S.Nurse && (_L.clinic > 0) && (_S.Nurse.energy > 95) || ((_S.Nurse.fetishStrength > 60) && (_S.Nurse.fetish == "sadist" || _S.Nurse.fetish == "dom"))>> + <<if _S.Nurse && (_L.clinic > 0) && (_S.Nurse.energy > 95 || (_S.Nurse.fetishStrength > 60 && (_S.Nurse.fetish == "sadist" || _S.Nurse.fetish == "dom")))>> <<set $subSlave = $slaves.find(function(s) { return s.anus != 0 && s.assignment == "get treatment in the clinic"; })>> <<if (def $subSlave)>> <<set $PETSevent.push("nurse molestation")>> diff --git a/src/uncategorized/reNickname.tw b/src/uncategorized/reNickname.tw index 99a131e73debfe0dfb59c5f579a011669feadeff..71426e5e0846d12ecfc05562564736d0ab81ea1e 100644 --- a/src/uncategorized/reNickname.tw +++ b/src/uncategorized/reNickname.tw @@ -122,7 +122,7 @@ <<if ($activeSlave.ID == $Madam.ID)>> <<set _qualifiedNicknames.push("Madam")>> <</if>> -<<if ($activeSlave.ID == $DJ.ID)>> +<<if ($activeSlave.ID == $djID)>> <<set _qualifiedNicknames.push("DJ")>> <</if>> <<if ($activeSlave.ID == $Recruiter.ID)>> diff --git a/src/uncategorized/saRelationships.tw b/src/uncategorized/saRelationships.tw index 49822c11a94849c8c3ac457dbf4f8856be044b7b..455f0ed014784845f43423d1ec317bb6b5af5b15 100644 --- a/src/uncategorized/saRelationships.tw +++ b/src/uncategorized/saRelationships.tw @@ -86,7 +86,7 @@ <<set _SlaveI.trust -= 4>> <</if>> <</if>> - <<elseif (_SlaveJ.ID == $DJ.ID) && (_SlaveI.assignment == "serve in the club")>> + <<elseif (_SlaveJ.ID == $djID) && (_SlaveI.assignment == "serve in the club")>> <<if _SlaveJ.rules.relationship != "restrictive">> _SlaveI.slaveName manages to ingratiate $himself with the DJ, _SlaveJ.slaveName. The two slaves have @@.lightgreen;struck up a friendship.@@ <<set _SlaveJ.relationship = 1, _SlaveJ.relationshipTarget = _SlaveI.ID, _SlaveI.relationship = 1, _SlaveI.relationshipTarget = _SlaveJ.ID>>