I'm still not too familiar with the built-in scripts and etc of quest, and I've been confused with the 'open~close' and 'unlocked~locked' features in quest too when I was working with the GUI~Editor long ago, but I'll give it a go regardless, lol:
here's what it's generally (an example, it's a bit more expansive~complex though) like in code:
<function name="question_function">
msg ("What is your choice?")
msg ("(1) red or (2) blue")
get input {
if (IsInt (result) = true)) {
if (ToInt (result) = 1) {
Object.Exit.Locked = false
Object.Exit.IsOpen = true
msg ("You unlock and open the door")
} else if (ToInt (result) = 2) {
msg ("Sorry, you chose the wrong answer, and die a gruesome death.")
msg ("GAME OVER")
finish
} else {
msg ("Wrong input, try again.")
question_function
}
} else {
msg ("Wrong input, try again.")
question_function
}
}
</function>
if you need help figuring out what scripts to add via using the GUI~Editor, let me know and I'll help you.
--------------
Code ~~~ GUI~Editor (run as a script -> add a script -> see below)
msg ("XXX") ~~~ Output -> Print a message -> [MESSAGE] for just text, OR: [EXPRESSION] for variable usage + text
if (XXX) { scripts } else if (XXX) { scripts } else { scripts } ~~~ Scripts -> if -> [EXPRESSION] as this allows you to type in what you want, then (script), else if (script), then (script), else (script)
'question_function' ~~~ Output or Scripts (can't remember which category it is under, lol) -> call function -> Name: 'question_function', Parameters: (leave blank, unless you know what are params and how to use them)
etc etc etc