diff --git a/www.eng/js/plugins/VND_ONSControls.js b/www.eng/js/plugins/VND_ONSControls.js index 7c5832e..779dc37 100644 --- a/www.eng/js/plugins/VND_ONSControls.js +++ b/www.eng/js/plugins/VND_ONSControls.js @@ -1001,6 +1001,58 @@ Window_OmoMenuOptionsONSControls.prototype.add = function () { this.createCommandWindow(); this.createExitPromptWindow(); }; + Scene_OmoMenuOptions.prototype.createSystemOptionsWindow = function () { + // Create System Option Window + this._systemOptionsWindow = new Window_OmoMenuOptionsSystem(); + this._systemOptionsWindow.x = 10; + this._systemOptionsWindow.y = 10; + this._systemOptionsWindow.setHandler('cancel', this.onOptionWindowCancel.bind(this)); + this._systemOptionsWindow.setHandler('restoreConfig', () => { + ConfigManager.restoreDefaultConfig(); + this._controlOptionsWindow.makeOptionsList() + this._generalOptionsWindow.makeOptionsList(); + this._audioOptionsWindow.makeOptionsList(); + this._onscontrolsOptionsWindow.makeOptionsList(); + + this._controlOptionsWindow.refresh() + this._controlOptionsWindow.select(0); + this._generalOptionsWindow.refresh(); + this._generalOptionsWindow.select(0); + this._audioOptionsWindow.refresh(); + this._onscontrolsOptionsWindow.refresh(); + this._systemOptionsWindow.refresh(); + this._systemOptionsWindow.activate(); + Input.clear(); + }); + this._systemOptionsWindow.setHandler('load', this.goToLoad.bind(this)); + this._systemOptionsWindow.setHandler('toTitleScreen', this.startExitPrompt.bind(this, 1)); + this._systemOptionsWindow.setHandler('exit', this.startExitPrompt.bind(this, 0)); + this.addChild(this._systemOptionsWindow); + }; + Scene_OmoriTitleScreen.prototype.createSystemOptionsWindow = function () { + // Create System Option Window + this._systemOptionsWindow = new Window_OmoMenuOptionsSystem(); + this._systemOptionsWindow.setHandler('restoreConfig', () => { + ConfigManager.restoreDefaultConfig(); + this._controlOptionsWindow.makeOptionsList() + this._generalOptionsWindow.makeOptionsList(); + this._audioOptionsWindow.makeOptionsList(); + this._onscontrolsOptionsWindow.makeOptionsList(); + + this._controlOptionsWindow.refresh() + this._controlOptionsWindow.select(0); + this._generalOptionsWindow.refresh(); + this._generalOptionsWindow.select(0); + this._audioOptionsWindow.refresh(); + this._onscontrolsOptionsWindow.refresh(); + this._systemOptionsWindow.refresh(); + this._systemOptionsWindow.activate(); + Input.clear(); + }); + this._systemOptionsWindow.setHandler('cancel', this.onOptionWindowCancel.bind(this)); + this._systemOptionsWindow.setHandler('exit', this.startExitPrompt.bind(this)); + this._optionsWindowsContainer.addChild(this._systemOptionsWindow); + }; Window_OmoMenuOptionsCategory.prototype.standardPadding = function () { return 7; } Window_OmoMenuOptionsCategory.prototype.maxCols = function () { return 5; }; Window_OmoMenuOptionsCategory.prototype.makeCommandList = function () { diff --git a/www.rus/js/plugins/VND_ONSControls.js b/www.rus/js/plugins/VND_ONSControls.js index 1dc394f..8c804dd 100644 --- a/www.rus/js/plugins/VND_ONSControls.js +++ b/www.rus/js/plugins/VND_ONSControls.js @@ -1001,6 +1001,58 @@ Window_OmoMenuOptionsONSControls.prototype.add = function () { this.createCommandWindow(); this.createExitPromptWindow(); }; + Scene_OmoMenuOptions.prototype.createSystemOptionsWindow = function () { + // Create System Option Window + this._systemOptionsWindow = new Window_OmoMenuOptionsSystem(); + this._systemOptionsWindow.x = 10; + this._systemOptionsWindow.y = 10; + this._systemOptionsWindow.setHandler('cancel', this.onOptionWindowCancel.bind(this)); + this._systemOptionsWindow.setHandler('restoreConfig', () => { + ConfigManager.restoreDefaultConfig(); + this._controlOptionsWindow.makeOptionsList() + this._generalOptionsWindow.makeOptionsList(); + this._audioOptionsWindow.makeOptionsList(); + this._onscontrolsOptionsWindow.makeOptionsList(); + + this._controlOptionsWindow.refresh() + this._controlOptionsWindow.select(0); + this._generalOptionsWindow.refresh(); + this._generalOptionsWindow.select(0); + this._audioOptionsWindow.refresh(); + this._onscontrolsOptionsWindow.refresh(); + this._systemOptionsWindow.refresh(); + this._systemOptionsWindow.activate(); + Input.clear(); + }); + this._systemOptionsWindow.setHandler('load', this.goToLoad.bind(this)); + this._systemOptionsWindow.setHandler('toTitleScreen', this.startExitPrompt.bind(this, 1)); + this._systemOptionsWindow.setHandler('exit', this.startExitPrompt.bind(this, 0)); + this.addChild(this._systemOptionsWindow); + }; + Scene_OmoriTitleScreen.prototype.createSystemOptionsWindow = function () { + // Create System Option Window + this._systemOptionsWindow = new Window_OmoMenuOptionsSystem(); + this._systemOptionsWindow.setHandler('restoreConfig', () => { + ConfigManager.restoreDefaultConfig(); + this._controlOptionsWindow.makeOptionsList() + this._generalOptionsWindow.makeOptionsList(); + this._audioOptionsWindow.makeOptionsList(); + this._onscontrolsOptionsWindow.makeOptionsList(); + + this._controlOptionsWindow.refresh() + this._controlOptionsWindow.select(0); + this._generalOptionsWindow.refresh(); + this._generalOptionsWindow.select(0); + this._audioOptionsWindow.refresh(); + this._onscontrolsOptionsWindow.refresh(); + this._systemOptionsWindow.refresh(); + this._systemOptionsWindow.activate(); + Input.clear(); + }); + this._systemOptionsWindow.setHandler('cancel', this.onOptionWindowCancel.bind(this)); + this._systemOptionsWindow.setHandler('exit', this.startExitPrompt.bind(this)); + this._optionsWindowsContainer.addChild(this._systemOptionsWindow); + }; Window_OmoMenuOptionsCategory.prototype.standardPadding = function () { return 7; } Window_OmoMenuOptionsCategory.prototype.maxCols = function () { return 5; }; Window_OmoMenuOptionsCategory.prototype.makeCommandList = function () {