Keeping track of menu choice then changing menu box?

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
wonderland
Regular
Posts: 70
Joined: Mon Dec 31, 2012 12:22 am
Projects: Fairy Tale Stupor [GxB] [Fantasy] [Adventure]
Contact:

Keeping track of menu choice then changing menu box?

#1 Post by wonderland »

Hello! I was just wondering how to do the coding for when you click a choice then replay the game, there's like a little fade or a distinct difference between a choice you've already made and the choice you've already made.

For example if the script was:

Code: Select all

menu:
        
        "Leave.":
           blah blah blah...
        "Continue to yell.":
            blah blah blah
And the first time around you clicked "Leave" and you played the game around but this time "leave" is a little grayed out to keep track of the choices you make through the game.(or that you clicked it before) Is this possible, and if so could you help me?

Thank you SO much! :D
"Keep your head up princess, if not the crown falls.."
Image

SundownKid
Lemma-Class Veteran
Posts: 2299
Joined: Mon Feb 06, 2012 9:50 pm
Completed: Icebound, Selenon Rising Ep. 1-2
Projects: Selenon Rising Ep. 3-4
Organization: Fastermind Games
Deviantart: sundownkid
Location: NYC
Contact:

Re: Keeping track of menu choice then changing menu box?

#2 Post by SundownKid »

You would have to make a persistent variable for each choice, and two versions of each choice with a different color.

Code: Select all

menu:
        if persistent.choice_1_1 == False:
           "Leave.":
           $ persistent.choice_1_1 = True
        else:
           "{color=#808080}Leave.{/color}":
               blah blah blah...
        "Continue to yell.":
            blah blah blah
At least I think it would work, haven't tested it.

Post Reply

Who is online

Users browsing this forum: geoWaffle, Google [Bot]