Error message prevOpt is undefined

“PrevOption is undefined” - I do not see what the problem is in comparison to other scenes? Any insight as to the cause for this error message?

If you want help you’re going to have to provide more information. What is PrevOption? Where do you use it in your code?

I don’t use that lingo at all. I’m running the random test on my game and that came up as an error message. Also, is there a way to skip a scene altogether if a permanent variable doesn’t apply?

Without a sample of the code that’s causing the problem it’s impossible for me to tell what the problem is. It’s possible that someone with more knowledge of randomtest will be able to assist.

And yes.

*if variable
    *goto_scene 1_FirstScene
*if not (variable)
    *goto_scene 2_AfterFirstScene

or whatever your files are called.

RANDOMTEST FAILED

prevOption is undefined

I’ve written out the whole game with the program but now trying to make sure it works correctly.

That is not code. That is an error message.

Now, I can make a guess as to what’s causing it. But I, personally, don’t use random test. I instead played through every single piece of my code and ensured it’d work separately. I plugged it into CJW’s IDE when I was having issues and would tweak things until it did work.

For instance, perhaps you have options that are not defined somewhere, That would involve going over your actual code, looking at every single *choice, making sure you’ve done them right. But is that the problem? I’ve no idea.

You’ve done something wrong. I can’t tell you what you’ve done wrong if I can’t actually see the game.

I just tried using the IDE and it’s not doing anything, I copied and pasted each scene and saved each individually but it’s not running the game

That’s weird. To be sure, are your scene files defined in startup?

Listen, no one can help you if you don’t show us the code. The ACTUAL code. Without it, we’re troubleshooting blind.

2 Likes

there is no code on the random test, only what i’ve said

Not the randomtest results. The actual source code that you wrote in ChoiceScript.

Also, what are you getting from quicktest?

@EasyE

We’ve repeatedly told you to post your game code. You’ve repeatedly refused.

We cannot help you fix your problem if you do not post the code that you, yourself, typed up.

If your next post on this thread is not an actual copy of your code so we can help you troubleshoot your problem I am locking this thread.

3 Likes