for the 'Ask' function, the game creates a variable called 'result' where it saves your input. You can use this to pull the response for your if/else function.
It should look something like this
Ask ("Are you sure you would like to lie down? You are sure to fall asleep; and by the atmosphere of a lucid dream about this place, there is no guarantee you'll ever find it again.") {
if(result){
msg("You fall asleep.")
esle{
undo
}
}
Selecting 'Yes' sets result to true, and 'No' sets it to false, but you don't need an ifelse(false) because if it's not true, then it has to be false. Also in the case of result somehow not being either true or false, it still defaults to not ending the game, which in this case is probably desirable.
The problem with your code is you weren't checking a variable, you were just asking the game "is true = true?" which is always the case so it always goes with your first block of code. What you wanted to ask is "is the players answer = yes?". The part you missed was actually referencing the players answer.