This commit is contained in:
Olivier Gagnon 2021-11-09 23:57:44 -05:00
commit 7cc2a1b49a
5 changed files with 17 additions and 10 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -312,7 +312,6 @@ function loadGame(saveString: string): boolean {
try {
const ver = JSON.parse(saveObj.VersionSave, Reviver);
evaluateVersionCompatibility(ver);
if (window.location.href.toLowerCase().includes("bitburner-beta")) {
// Beta branch, always show changes
createBetaUpdateText();
@ -328,15 +327,22 @@ function loadGame(saveString: string): boolean {
createNewUpdateText();
}
createNewUpdateText();
createNewUpdateText();
createNewUpdateText();
return true;
}
function createNewUpdateText(): void {
setTimeout(
() =>
dialogBoxCreate(
"New update!<br>" +
"Please report any bugs/issues through the github repository " +
"or the Bitburner subreddit (reddit.com/r/bitburner).<br><br>" +
CONSTANTS.LatestUpdate,
),
1000,
);
}

@ -354,7 +354,7 @@ export function Root(props: IProps): React.ReactElement {
.find((l: any) => l.id === "javascript")
.loader();
l.language.tokenizer.root.unshift(["ns", { token: "ns" }]);
for (const symbol of symbols) l.language.tokenizer.root.unshift(["\\." + symbol, { token: "netscriptfunction" }]);
for (const symbol of symbols) l.language.tokenizer.root.unshift([symbol, { token: "netscriptfunction" }]);
const otherKeywords = ["let", "const", "var", "function"];
const otherKeyvars = ["true", "false", "null", "undefined"];
otherKeywords.forEach((k) => l.language.tokenizer.root.unshift([k, { token: "otherkeywords" }]));

@ -7,5 +7,6 @@ export function dialogBoxCreate(txt: string | JSX.Element): void {
AlertEvents.emit(txt);
} else {
AlertEvents.emit(<span dangerouslySetInnerHTML={{ __html: txt }} />);
console.log('emit"');
}
}