Hi, I'm trying to make my first game with quest and I'm having a problem creating a tutorial for some features of the game.
I made a function called tutorial that you can call from anywhere in the game. I placed a list of topics in a menu list, offered the menu to the player and tried to put it in a switch to respond to every case, that's where things seems to go wrong.
Error running script: Error compiling expression 'souls': Unknown object or variable 'souls'
I have tried to put a message with the + result before the switch and the choice is displayed correctly, still I cannot use that in a switch to give the appropriate answer to each case
here is the code of the function
<function name="tutorial">
menulist = NewStringList()
list add (menulist, "souls")
list add (menulist, "brimstones")
list add (menulist, "prestige")
list add (menulist, "surface")
list add (menulist, "improving")
list add (menulist, "thrall")
list add (menulist, "end")
ShowMenu ("choose a topic", menulist, false) {
ClearScreen
switch (result) {
case (souls) {
msg ("bla bla bla souls bla bla")
tutorial
}
}
}
</function>
what am i doing wrong?
also, there is a way to show the description of the room you are in as if you just entered? I would like to clean the screen and rewrite it when the tutorial ends