diff --git a/src/facilities/nursery/nurseryDatatypeCleanup.js b/src/facilities/nursery/nurseryDatatypeCleanup.js index e3236ee1081781123a314e66804b18ea3fa1a405..f31cc2872b98fe6e6379824a1d2e8c438f138745 100644 --- a/src/facilities/nursery/nurseryDatatypeCleanup.js +++ b/src/facilities/nursery/nurseryDatatypeCleanup.js @@ -290,9 +290,18 @@ App.Facilities.Nursery.ChildDatatypeCleanup = function(child) { if (typeof child.eyewear !== "string") { child.eyewear = "none"; } - child.brand = Math.clamp(+child.brand, 0, 1) || 0; - if (typeof child.brandLocation !== "string") { - child.brandLocation = 0; + if (typeof child.brand !== "object") { + let brand = {}; + if (child.brand !== 0) { + brand["left buttock"] = child.brand; + } + child.brand = brand; + } else if (typeof child.brand === "object") { // Make sure key and value are strings + for (let [key, value] of Object.entries(child.brand)) { + if (typeof key !== "string" || typeof value !== "string") { + delete child.brand[key]; + } + } } if (typeof child.markings !== "string") { child.markings = "none"; diff --git a/src/facilities/nursery/nurseryWidgets.js b/src/facilities/nursery/nurseryWidgets.js index 071a07f48499de42393a910ffb9849b435e8d709..234999f7013d7c9bfbf443cba228d986a901da42 100644 --- a/src/facilities/nursery/nurseryWidgets.js +++ b/src/facilities/nursery/nurseryWidgets.js @@ -2555,7 +2555,7 @@ App.Facilities.Nursery.ChildSummary = function(child) { longImplants(child); longLactation(child); // longMods(child); - if (child.brand !== 0) { + if (!jQuery.isEmptyObject(child.brand)) { r += `Branded. `; } r += `</span> `; @@ -4741,7 +4741,7 @@ App.Facilities.Nursery.ChildSummary = function(child) { // } else { // r += `Mods`; // } - // if (child.brand !== 0) { + // if (!jQuery.isEmptyObject(child.brand)) { // r += `Br`; // } // } @@ -9143,10 +9143,9 @@ App.Facilities.Nursery.LongChildDescription = function(child) { if (V.showBodyMods) { r += tats.dick(child); r += piercings.dick(child); - r += App.Desc.brand(child, "penis"); - r += App.Desc.brand(child, "left testicle"); - r += App.Desc.brand(child, "right testicle"); } + r += App.Desc.brand(child, "penis"); + r += App.Desc.brand(child, "testicle"); return r; } @@ -11523,15 +11522,10 @@ App.Facilities.Nursery.LongChildDescription = function(child) { } } - r += App.Desc.brand(child, "right upper arm"); - r += App.Desc.brand(child, "right lower arm"); - r += App.Desc.brand(child, "right hand"); - r += App.Desc.brand(child, "right wrist"); - - r += App.Desc.brand(child, "left upper arm"); - r += App.Desc.brand(child, "left lower arm"); - r += App.Desc.brand(child, "left wrist"); - r += App.Desc.brand(child, "left hand"); + r += App.Desc.brand(child, "upper arm"); + r += App.Desc.brand(child, "lower arm"); + r += App.Desc.brand(child, "hand"); + r += App.Desc.brand(child, "wrist"); return r; } @@ -11693,9 +11687,6 @@ App.Facilities.Nursery.LongChildDescription = function(child) { } } - // r += App.Desc.brand(child, "left breast"); - // r += App.Desc.brand(child, "right breast"); - return r; } @@ -11764,8 +11755,7 @@ App.Facilities.Nursery.LongChildDescription = function(child) { } } - r += App.Desc.brand(child, "left buttock"); - r += App.Desc.brand(child, "right buttock"); + r += App.Desc.brand(child, "buttock"); return r; } @@ -11962,8 +11952,7 @@ App.Facilities.Nursery.LongChildDescription = function(child) { } } - r += App.Desc.brand(child, "left shoulder"); - r += App.Desc.brand(child, "right shoulder"); + r += App.Desc.brand(child, "shoulder"); return r; } @@ -12505,9 +12494,7 @@ App.Facilities.Nursery.LongChildDescription = function(child) { } } - if (V.showBodyMods) { - r += App.Desc.brand(child, "pubic mound"); - } + r += App.Desc.brand(child, "pubic mound"); if (!child.dick) { if (child.clit > 0) { @@ -14164,11 +14151,9 @@ App.Facilities.Nursery.LongChildDescription = function(child) { } } - if (V.showBodyMods) { - if (["cheeks", "ears", "left cheek", "left ears", "neck", "right cheek", "right ears"].includes(child.brandLocation)) { - App.Desc.brand(child); - } - } + r += App.Desc.brand(child, "cheek"); + r += App.Desc.brand(child, "ear"); + r += App.Desc.brand(child, "neck"); /* OPEN FAMILY */ @@ -15111,11 +15096,10 @@ App.Facilities.Nursery.LongChildDescription = function(child) { r += heel(child); - if (V.showBodyMods) { - if (["ankles", "back", "calves", "chest", "feet", "hands", "left ankle", "left calf", "left foot", "left hand", "left lower arm", "left shoulder", "left upper arm", "left wrist", "lower arms", "lower back", "right ankle", "right calf", "right foot", "right hand", "right lower arm", "right shoulder", "right upper arm", "right wrist", "shoulders", "upper arms", "wrists"].includes(child.brandLocation)) { - r += App.Desc.brand(child); - } - } + r += App.Desc.brand(child, "feet"); + r += App.Desc.brand(child, "calf"); + r += App.Desc.brand(child, "ankle"); + r += App.Desc.brand(child, "extra"); r += skin(child); @@ -15282,10 +15266,8 @@ App.Facilities.Nursery.LongChildDescription = function(child) { if (V.showBodyMods) { r += tats.boobs(child); } - if (["left breast", "right breast"].includes(child.brandLocation)) { - r += App.Desc.brand(child, "breast"); - } - r += App.Desc.brand(child); + r += App.Desc.brand(child, "chest"); + r += App.Desc.brand(child, "breast"); r += shoulders(child); r += App.Desc.nipples(child); if (V.showBodyMods) { @@ -15600,8 +15582,7 @@ App.Facilities.Nursery.infantToChild = function infantToChild(child) { child.boobsImplant = 0, child.boobsImplantType = 0, child.boobsTat = 0, - child.brand = 0, - child.brandLocation = 0, + child.brand = {}, child.breastMesh = 0, child.breedingMark = 0, child.butt = jsRandom(0, 3),