Skip to content
Snippets Groups Projects
Commit 75158f9f authored by Vrelnir's avatar Vrelnir
Browse files

Merge branch 'various-fixes' into 'dev'

NPC and General Fixes

See merge request Vrelnir/degrees-of-lewdity!1911
parents 83b6ccb0 9d2fcd41
No related branches found
No related tags found
No related merge requests found
......@@ -30,7 +30,7 @@
<div @class="'stat ' + _mobileColor">
<mouse class="tooltip-centertop">I<span>Innocence: <<print $innocencestate.toFixed(2)>></span></mouse>
</div>
<<elseif Number.isFinite(trauma) and ($options.sidebarStats is "all" or $trauma gt $traumamax / 2)>>
<<elseif Number.isFinite($trauma) and ($options.sidebarStats is "all" or $trauma gt $traumamax / 2)>>
<<mobileStatsColor "trauma">>
<div @class="'stat ' + _mobileColor">
<mouse class="tooltip-centertop">T<span>Trauma: <<print $trauma.toFixed(2)>></span></mouse>
......
......@@ -644,7 +644,7 @@
<<if $NPCNameList.includes(_args[0])>>
<<set $pronoun to $NPCName[$NPCNameList.indexOf(_args[0])].pronoun>>
<<else>>
<<if Number.isInteger(_args[0]) and between(_args[0],1,6)>>
<<if Number.isInteger(_args[0]) and between(_args[0],0,5)>>
<<personselect _args[0]>>
<</if>>
<</if>>
......
......@@ -252,7 +252,6 @@ You nod. "Alright," Doren says. <<He>> doesn't sound convinced.
:: English Read Passage
<<set $outside to 0>><<set $location to "school">><<schooleffects>><<effects>>
<<npc Doren>><<person1>>
<<if $phase is 0>> /* Tell Doren */
<<if $NPCName[$NPCNameList.indexOf("Doren")].love gte 10>>
Doren shakes <<his>> head, and passes you <<his>> copy of the book.<br>
......
......@@ -6,9 +6,7 @@
let resp = "";
try {
// eslint-disable-next-line no-eval
eval(
"const tdTest = { 'name': 'Bob', 'age': 5 };const tfTest2 = { 'hair': 'blonde', ...tdTest };"
);
eval("const tdTest = { 'name': 'Bob', 'age': 5 };const tfTest2 = { 'hair': 'blonde', ...tdTest };");
} catch (e) {
hasErrored = true;
resp += "Destructuring is not supported for your browser.\n";
......@@ -20,9 +18,7 @@
const chromeTest = segments.findIndex(s => s.startsWith("Chrome"));
const firefoxTest = segments.findIndex(s => s.startsWith("Firefox"));
if (androidTest >= 0) {
resp +=
"\nUpdate your Android WebView System app.\nVersion: " +
segments[androidTest].slice(8);
resp += "\nUpdate your Android WebView System app.\nVersion: " + segments[androidTest].slice(8);
} else if (chromeTest >= 0) {
resp += "\nUpdate your Chrome browser.\nVersion: " + segments[chromeTest].slice(7);
} else if (firefoxTest >= 0) {
......@@ -36,11 +32,16 @@
})();
/* Implement hasOwn function interception for old versions of JS. */
(function (hasOwn) {
Object.hasOwn = function () {
if (typeof hasOwn !== "function") {
return this.prototype.hasOwnProperty.call(...arguments);
}
return hasOwn.apply(this, arguments);
};
})(Object.hasOwn);
if (!Object.hasOwn) {
Object.defineProperty(Object, "hasOwn", {
value(object, property) {
if (object == null) {
throw new TypeError("Cannot convert undefined or null to object");
}
return Object.prototype.hasOwnProperty.call(Object(object), property);
},
configurable: true,
enumerable: false,
writable: true,
});
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment