- Joined
- Aug 9, 2022
- Messages
- 89
- Reaction score
- 19
- First Language
- English
- Primarily Uses
- RMMZ
Hi, I find this code works fine if the options for the multiple choice are not too long. Is there any way to increase the maximum width that will display correctly? Here is my code:
Code:
function askMcQn() {
$gameMessage.add($gameVariables.value(45)); // Question
$gameMessage.setChoices([$gameVariables.value(46), $gameVariables.value(47), $gameVariables.value(48), $gameVariables.value(49)], 0, -1);
// Set background: Dim
$gameMessage.setChoiceBackground(1);
// Set position: Center
$gameMessage.setChoicePositionType(0);
// Bottom
$gameMessage.setPositionType(0);
// On choice, set variable #1 equal to the selected index
$gameMessage.setChoiceCallback(n => {
var letterChoice;
if (n === 0) letterChoice = 'A'
else if (n === 1) letterChoice = 'B'
else if (n === 2) letterChoice = 'C'
else if (n === 3) letterChoice = 'D';
$gameVariables.setValue(5, letterChoice);
});
// Wait for a choice to be selected
// this.setWaitMode("message");
// console.log($gameVariables.value(5));
}