diff --git a/noname/library/element/content.js b/noname/library/element/content.js index 9ce2bc139..83fb76409 100644 --- a/noname/library/element/content.js +++ b/noname/library/element/content.js @@ -3151,6 +3151,7 @@ export const Content = { next.set('ai', info.chooseButton.check || function () { return 1; }); next.set('filterButton', info.chooseButton.filter || function () { return true; }); next.set('selectButton', info.chooseButton.select || 1); + next.set('complexSelect', info.chooseButton.complexSelect !== false); next.set('filterOk', info.chooseButton.filterOk || (() => true)); if (event.id) next._parent_id = event.id; next.type = 'chooseToUse_button'; @@ -4546,7 +4547,7 @@ export const Content = { event.dialog.style.display = ''; event.dialog.open(); } - if (['chooseCharacter', 'chooseButtonOL'].includes(event.getParent().name)) event.complexSelect = true; + // if (['chooseCharacter', 'chooseButtonOL'].includes(event.getParent().name)) event.complexSelect = true; var filterButton = event.filterButton || function () { return true; }; var selectButton = get.select(event.selectButton); var buttons = event.dialog.buttons; diff --git a/noname/library/element/player.js b/noname/library/element/player.js index ca64ccef2..2800ed4fc 100644 --- a/noname/library/element/player.js +++ b/noname/library/element/player.js @@ -4267,7 +4267,8 @@ export class Player extends HTMLDivElement { var next = game.createEvent('chooseButton'); for (var i = 0; i < arguments.length; i++) { if (typeof arguments[i] == 'boolean') { - next.forced = arguments[i]; + if (!next.forced) next.forced = arguments[i]; + else next.complexSelect = arguments[i]; } else if (get.itemtype(arguments[i]) == 'dialog') { next.dialog = arguments[i]; @@ -4293,6 +4294,7 @@ export class Player extends HTMLDivElement { if (next.filterButton == undefined) next.filterButton = lib.filter.filterButton; if (next.selectButton == undefined) next.selectButton = [1, 1]; if (next.ai == undefined) next.ai = function () { return 1; }; + if (next.complexSelect !== false) next.complexSelect = true; next.setContent('chooseButton'); next._args = Array.from(arguments); next.forceDie = true;