mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-05-02 05:47:14 +02:00
FEATURE: Add "Recent Errors" tab and improved error modal (#2169)
This commit is contained in:
committed by
GitHub
parent
cf72937faf
commit
18f84396e2
@@ -3,8 +3,13 @@ import { OptionSwitch } from "../../ui/React/OptionSwitch";
|
||||
import { Settings } from "../../Settings/Settings";
|
||||
import { GameOptionsPage } from "./GameOptionsPage";
|
||||
import { Player } from "@player";
|
||||
import { toggleSuppressErrorModals } from "../../ErrorHandling/ErrorState";
|
||||
|
||||
export const GameplayPage = (): React.ReactElement => {
|
||||
const toggleSuppressErrorModalsSetting = (newValue: boolean): void => {
|
||||
Settings.SuppressErrorModals = newValue;
|
||||
toggleSuppressErrorModals(newValue, true);
|
||||
};
|
||||
return (
|
||||
<GameOptionsPage title="Gameplay">
|
||||
<OptionSwitch
|
||||
@@ -52,6 +57,17 @@ export const GameplayPage = (): React.ReactElement => {
|
||||
text="Suppress TIX messages"
|
||||
tooltip={<>If this is set, the stock market will never create any popup.</>}
|
||||
/>
|
||||
<OptionSwitch
|
||||
checked={Settings.SuppressErrorModals}
|
||||
onChange={toggleSuppressErrorModalsSetting}
|
||||
text="Suppress error modals"
|
||||
tooltip={
|
||||
<>
|
||||
If this is set, script errors will never create any popups. The errors can still be seen on the "Recent
|
||||
Errors" tab in the Active Scripts page.
|
||||
</>
|
||||
}
|
||||
/>
|
||||
{Player.bladeburner && (
|
||||
<OptionSwitch
|
||||
checked={Settings.SuppressBladeburnerPopup}
|
||||
|
||||
Reference in New Issue
Block a user