Help Making Choices


#1

How can I make a choice available due to a choice that was made.

for example

*choice
   #Eat ice cream
      You eat ice cream
      *finish
   #Drop ice cream
      You drop ice cream
      *finish

This is where i would screw up…
*selectable_if (Eat ice cream) #finish ice cream??? halp


#2

You don’t have a variable for when you eat ice cream.

*choice
 #Eat ice cream
  You eat ice cream.
  *temp ice_cream true
  *finish

.
So if your making a choice based off of whether someone ate ice cream you need to make a variable that stores whether or not someone ate ice cream.
If you want to make a choice that uses decisions from a previous choice you need to make a variable


#3

How to format your code so it can be seen on the forum.

Paste code into window.
Highlight all of the code.
Click the preformatted text button. (It looks like </> and is next to the quote one and on the same bar as the other formatting and smilies choice.)
Click reply.


#4

Oh okay

I was formatting right but I guess it shows up different once its posted.


#5

Choicescript can only store information as variables so if you want to store information you need to make a variable to record it.


#6

Alternatively, if you don’t need an icecream variable later, you could just add a choice immediately after your choice to eat the ice cream:

*choice
   #Eat ice cream
      You eat ice cream
      *choice
        #Finish ice cream
          Yum.
          *finish
        #Share ice cream
          You made a friend!
          *finish
   #Drop ice cream
      You drop ice cream
      *finish

If you want to use *selectable_if for that nice ghosted-out look, though, you need to *create a variable which changes depending on your choice to eat or drop the ice cream. *selectable_if only works with a variable after it.