Choice body error HELP

You know that in case your original plan failed, you could try again if you had enough. But looking into your savings you only had 1.50$
“You got to be kidding me” you mentally kicked yourself and frowned.You debated on whether or not you should steal from your parents they wouldn’t mind they get 2$ a day from the village that’s a lot considering the what the other villagers get.
*choice
#steal from your parents.
*if time > 0
You naughty thang.

*goto Chapter1
*set wealth +51.50
*set agility +5

*else
your out of time

*goto Checkpoint

#Work with what you got

*set wealth +1.50
*goto Chapter1

I can’t see whats wrong can someone help

What is the error you are getting?

And could you use the code formatting so we can see what your indentation is?

You know that in case your original plan failed, you could try again if you had enough. But looking into your savings you only had 1.50$
“You got to be kidding me” you mentally kicked yourself and frowned.You debated on whether or not you should steal from your parents they wouldn’t mind they get 2$ a day from the village that’s a lot considering the what the other villagers get.
*choice
   #steal from your parents.
*if time > 0
You naughty thang.
*else
your out of time
    *goto Checkpoint

   #Work with what you got

    *set wealth +1.50
    *goto Chapter1

Your indentation is incomplete for the first #option. It should look more like this:

*choice
    #steal from your parents.
        *if time > 0
            You naughty thang.
        *else
            You're out of time.
        *goto Checkpoint

There are some other issues with your code samples, but this should be enough to get you started and make the error message go away.

1 Like

I believe you also need a *goto after the *if statement:

  *choice
    #steal from your parents.
        *if time > 0
            You naughty thang.
            *goto Checkpoint
        *else
            You're out of time.
            *goto Checkpoint

You can also delete the line break between #Work with what you got and the *set wealth +1.50

now it says line 262 is wrong

*label food

Starvation wasn't an option if you wanted to last as long as you hoped.
*choice
   #steal food (15 agility)
*if agility > 15
     You did'nt get caught! Quietly you walked into the kitchen and grabbed some water, canned food, raw meat and cereal.you then walked over and got a grocery bag from the cabinet and put the food into the bag. And then as silently as you could went to your room tied the bag, and put it into a side pocket of the bag.
    *set intelligence +15
    *set has_food true
    *goto Chapter1
*else
     You get caught.
    *set intelligence -15
    *goto Checkpoint

   #I cant risk it

    *set time +1
    *set leadership +15
    *goto Chapter1

line 262 is ‘*if agility > 15’

Same as before, your indentation is incomplete.

Think of the *choice as the ground, and the rest as a set of stairs.

*choice is the ground, #option is the first step.

*choice
   #steal food (15 agility)

The result(s) of that #option are the second step. In this case, that’s *if and *else

*choice
   #steal food (agility 15)
      *if agility > 15
      *else

The results of the *if and *else are the third step.

*choice
   #steal food (agility 15)
      *if agility > 15
         You didn't get caught! Quietly you walked...
         *set intelligence +15
         *set has_food true
         *goto Chapter1
      *else
         You get caught.
         *set intelligence -15
         *goto checkpoint

the ifs ought to go under the choice

*label food

Starvation wasn't an option if you wanted to last as long as you hoped.
*choice
   #steal food (15 agility)
      *if agility > 15
         You did'nt get caught! Quietly you walked into the kitchen and grabbed some water, canned food, raw meat and cereal.you then walked over and got a grocery bag from the cabinet and put the food into the bag. And then as silently as you could went to your room tied the bag, and put it into a side pocket of the bag.
         *set intelligence +15
         *set has_food true
         *goto Chapter1
      *else
         You get caught.
         *set intelligence -15
         *goto Checkpoint
   #I cant risk it
      *set time +1
      *set leadership +15
      *goto Chapter1

ok that problems fixed but now it says expected at least one line in 'if true block?

what now?

could you copy the code again? sounds like another indent error

Starvation wasn't an option if you wanted to last as long as you hoped.
*choice
   #steal food (15 agility)
      *if agility > 15
     You did'nt get caught! Quietly you walked into the kitchen and grabbed some water, canned food, raw meat and cereal.you then walked over and got a grocery bag from the cabinet and put the food into the bag. And then as silently as you could went to your room tied the bag, and put it into a side pocket of the bag.
    *set intelligence +15
    *set has_food true
    *goto Chapter1
      *else
     You get caught.
    *set intelligence -15
    *goto Checkpoint

   #I cant risk it

    *set time +1
    *set leadership +15
    *goto Chapter1

thats the rvised version

copy minnow or my code.

sorry that it took so long but it says the same thing I tried both of your codes

Going by how the code you copied looks your indents are suddenly all over the place.
Did you copy the codes with the right indentation or elsewise?

I fixed it my *if statements from earlier had 5 spaces
ya’lls had 6 just had to fix that

1 Like

Ahhh

1 Like