- Joined
- Nov 9, 2015
- Messages
- 45
- Reaction score
- 1
- First Language
- German
Hey people,
so what I'd like to do is to show a few choices while in battle and run code depending on the users choice.
I managed to show these choices, but I don't know how to handle the outcome. I am btw useing the <After Eval> function of Yanfly's skill core.
Till now, I found this piece of code:
<After Eval>
choices = [];
params = [];
$gameMessage.setChoices(choices, 0);
choices.push("yo1");
choices.push("yo2");
choices.push("yo3");
choices.push("yo4");
choices.push("yo5");
choices.push("yo6");
params.push();
</After Eval>
The choices yo1-yo6 show up just as intended but I don't exactly know what and where the outcome of the choice is stored.
If I knew it, I would continue makeing if-sequences to run different code like "if(choice === 1)\n {mycode};". I also don't know what the params-Array is used for, maybe the answer is stored inside there?
Thanks in advance,
romepizza
so what I'd like to do is to show a few choices while in battle and run code depending on the users choice.
I managed to show these choices, but I don't know how to handle the outcome. I am btw useing the <After Eval> function of Yanfly's skill core.
Till now, I found this piece of code:
<After Eval>
choices = [];
params = [];
$gameMessage.setChoices(choices, 0);
choices.push("yo1");
choices.push("yo2");
choices.push("yo3");
choices.push("yo4");
choices.push("yo5");
choices.push("yo6");
params.push();
</After Eval>
The choices yo1-yo6 show up just as intended but I don't exactly know what and where the outcome of the choice is stored.
If I knew it, I would continue makeing if-sequences to run different code like "if(choice === 1)\n {mycode};". I also don't know what the params-Array is used for, maybe the answer is stored inside there?
Thanks in advance,
romepizza
