diff --git a/src/js/utilsDOM.js b/src/js/utilsDOM.js index 439e15dbbf601da7f16d8d7cfdc1a357e653080d..6f50cef3864c5674bf4976392fc7df1043c1438b 100644 --- a/src/js/utilsDOM.js +++ b/src/js/utilsDOM.js @@ -276,9 +276,9 @@ App.UI.DOM.makeTextBox = function(defaultValue, onEnter, numberOnly = false) { App.UI.DOM.colorInput = function(defaultValue, onEnter) { const input = document.createElement("input"); input.type = "color"; - input.value = defaultValue; + input.value = String(defaultValue); - input.addEventListener('change', e => { onEnter(e.target.value); }); + input.addEventListener("change", e => { onEnter(e.target.value); }); return input; }; @@ -289,7 +289,7 @@ App.UI.DOM.colorInput = function(defaultValue, onEnter) { * @param {Array<Node|string>} content * @param {string} [delimiter] * @param {string} [lastDelimiter] - * @returns {DocumentFragment|string} + * @returns {Node|string} */ App.UI.DOM.arrayToList = function(content, delimiter = ", ", lastDelimiter = " and ") { if (content.length === 0) { @@ -422,6 +422,7 @@ Macro.add("includeDOM", { try { this.output.append(Scripting.evalJavaScript(this.args.full)); } catch (ex) { + // @ts-ignore return this.error(`bad evaluation: ${typeof ex === 'object' ? `${ex.name}: ${ex.message}` : ex}`, null, ex.stack); } diff --git a/src/npc/descriptions/belly/belly.js b/src/npc/descriptions/belly/belly.js index deaca53322a7ef808faecc5a37e88db527e424c9..82ea70643a3d5851b58aed1f2569bf6b64960a97 100644 --- a/src/npc/descriptions/belly/belly.js +++ b/src/npc/descriptions/belly/belly.js @@ -13000,30 +13000,30 @@ App.Desc.belly = function(slave, {market, eventDescription} = {}) { if (isBellyFluidLargest) { r.push(`${slave.slaveName}'s teddy has burst trying to contain ${his} monolithic, ${slave.inflationType}-filled belly, leaving it hanging out the hole it made.`); } else if (slave.bellyImplant > 0) { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a ridiculously swollen ${girl} and comes with a gap in the front for ${his} monolithic implant-filled belly to expand out of.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a ridiculously swollen ${girl} and comes with a gap in the front for ${his} monolithic implant-filled belly to expand out of.`); } else { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a ridiculously gravig ${girl} and comes with a gap in the front for ${his} monolithic pregnant belly to uncontrollably billow out of.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a ridiculously gravig ${girl} and comes with a gap in the front for ${his} monolithic pregnant belly to uncontrollably billow out of.`); } } else if (slave.bellyPreg >= 600000) { if (isBellyFluidLargest) { } else if (slave.bellyImplant > 0) { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a absurdly swollen ${girl} and comes with a gap in the front for ${his} titanic implant-filled belly to bulge through.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a absurdly swollen ${girl} and comes with a gap in the front for ${his} titanic implant-filled belly to bulge through.`); } else { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a absurdly gravid ${girl} and comes with a gap in the front for ${his} titanic pregnant belly to spill out of.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a absurdly gravid ${girl} and comes with a gap in the front for ${his} titanic pregnant belly to spill out of.`); } } else if (slave.belly >= 450000) { if (isBellyFluidLargest) { } else if (slave.bellyImplant > 0) { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a massively swollen ${girl} and comes with a gap in the front for ${his} gigantic implant-filled belly to bulge through.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a massively swollen ${girl} and comes with a gap in the front for ${his} gigantic implant-filled belly to bulge through.`); } else { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a massively gravid ${girl} and comes with a gap in the front for ${his} gigantic pregnant belly to bulge through.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a massively gravid ${girl} and comes with a gap in the front for ${his} gigantic pregnant belly to bulge through.`); } } else if (slave.belly >= 300000) { if (isBellyFluidLargest) { } else if (slave.bellyImplant > 0) { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a hugely swollen ${girl} and comes with a gap in the front for ${his} massive implant-filled belly to bulge through.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a hugely swollen ${girl} and comes with a gap in the front for ${his} massive implant-filled belly to bulge through.`); } else { - r.push(`${slave.slaveName}'s teddy is specially designed to accomodate such a hugely gravid ${girl} and comes with a gap in the front for ${his} massive pregnant belly to bulge through.`); + r.push(`${slave.slaveName}'s teddy is specially designed to accommodate such a hugely gravid ${girl} and comes with a gap in the front for ${his} massive pregnant belly to bulge through.`); } } else if (slave.belly >= 120000) { if (isBellyFluidLargest) { diff --git a/src/uncategorized/resFailure.tw b/src/uncategorized/resFailure.tw index 92f1306eff3c53d92af004ecb61a2238913ec1a6..5929c62df5c863509be967a9d08de8f3e315b4ab 100644 --- a/src/uncategorized/resFailure.tw +++ b/src/uncategorized/resFailure.tw @@ -3,6 +3,7 @@ <<set $nextButton = "Continue", $nextLink = "Scheduled Event", $returnTo = "Scheduled Event">> <<set $RESFailure = App.Utils.schoolFailure()>> +<<set _SCH = App.Data.misc.schools.get($RESFailure)>> <<run repX(-200, "event")>> <<set $arcologies[0].prosperity -= 2>> @@ -700,16 +701,16 @@ </p> <<else>> <p> - You receive a personal call from a senior representative of <<print App.Data.misc.schools.get($RESFailure).title>> as you've been expecting since their second missed rent payment. "I apologize," _he says with some embarrassment, "but it seems our expansion into your arcology was a mistake. It's strange — the business climate seemed excellent, and other corporations are doing well." - _He sighs "Nevertheless, nothing ever seemed to go as planned. We'll be shutting our <<print App.Data.misc.schools.get($RESFailure).branchName>> down immediately. In fact, it should be shut down within the hour. + You receive a personal call from a senior representative of _SCH.title as you've been expecting since their second missed rent payment. "I apologize," _he says with some embarrassment, "but it seems our expansion into your arcology was a mistake. It's strange — the business climate seemed excellent, and other corporations are doing well." + _He sighs "Nevertheless, nothing ever seemed to go as planned. We'll be shutting our _SCH.branchName down immediately. In fact, it should be shut down within the hour. <<if $RESFailure == "TCR">> - However, we lack the funds to remove some of our finest cattle and since we still owe you a little... We'd like to you to have them; we'll even have them delivered to your penthouse with the last of our credits." + However, we lack the funds to remove some of our finest _SCH.slaveNoun and since we still owe you a little... We'd like to you to have them; we'll even have them delivered to your penthouse with the last of our credits." <<else>> I regret to add," _he says nervously, "that we're experiencing continued difficulty finding the liquidity to pay what we owe you. <<if $RESFailure == "GRI">> - The lab we're closing has five solid test subjects. + The lab we're closing has five solid _SCH.slaveNoun. <<else>> - The branch campus we're closing has five recent graduates. + The branch campus we're closing has five recent _SCH.slaveNoun. <</if>> We'd like to transfer them to you in lieu of payment." _He hurriedly end the call.