Page 1 of 1

Choice menuitem expects a non-empty block.

Posted: Wed Feb 22, 2017 12:43 am
by notanautomaton
I'm pretty new to coding anything, and I got the title text when trying to run my game. My current script looks like this:

Code: Select all


    menu:
        
        "Jamelia Belltower, Veteran Agent":
        
        jump jameliabelltower
        
label jameliabelltower:
(Edit: It has the correct indentation, but it's not showing up on the forum and I don't know how to make it do it."

What does it mean, and how do I fix it?

Also, sorry if this isn't the correct forum, I'm pretty new here.

Edit: Yeah, this should have gone in Questions and Announcements probably. Sorry.

Re: Choice menuitem expects a non-empty block.

Posted: Wed Feb 22, 2017 12:50 am
by Scribbles
use the [.code] and [./code] (without the "."s)

Re: Choice menuitem expects a non-empty block.

Posted: Wed Feb 22, 2017 12:55 am
by notanautomaton
Scribbles wrote:use the [.code] and [./code] (without the "."s)
Thanks. I'll probably be asking a lot of these, sorry for the trouble.

Re: Choice menuitem expects a non-empty block.

Posted: Wed Feb 22, 2017 1:30 am
by notanautomaton
Okay, I figured it out. My indentation was off. jump jameliabelltower should have had one more indent.

Re: Choice menuitem expects a non-empty block.

Posted: Wed Feb 22, 2017 5:31 am
by Imperf3kt
Didn't get a chance to reply earlier.
As you noticed, you needed one more indent of four spaces.

Any time you add a colon (:), you need to indent the next line by four spaces.

Remember to break out of this if you add multiple items to your menu, ex:

Code: Select all

    menu:
        "Jamelia Belltower, Veteran Agent":
            jump jameliabelltower
        "Bob Dole, Some Dude":
            jump bobdole

label jameliabelltower: