Disable menu choice?

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
iDweadith
Regular
Posts: 63
Joined: Sun Mar 01, 2020 4:15 pm
Contact:

Disable menu choice?

#1 Post by iDweadith » Thu Jun 04, 2020 10:19 am

Hello guys,

Is it possible to disable a choice of a menu?

User avatar
hell_oh_world
Veteran
Posts: 464
Joined: Fri Jul 12, 2019 5:21 am
Projects: The Button Man
Organization: NILA
Github: hell-oh-world
Location: Philippines
Contact:

Re: Disable menu choice?

#2 Post by hell_oh_world » Thu Jun 04, 2020 10:40 am

place this in any part of your script with 0 indentation.

Code: Select all

define config.menu_include_disabled = True
then just make a condition in a choice that you want to disable

Code: Select all

label start:
  menu:
    "choice 1" if False: # appears insensitive unless the condition is True, in this case, it's False. conditions can be var1 == 1, etc.
      pass

User avatar
iDweadith
Regular
Posts: 63
Joined: Sun Mar 01, 2020 4:15 pm
Contact:

Re: Disable menu choice?

#3 Post by iDweadith » Thu Jun 04, 2020 4:11 pm

Thank you sooooo much! It works perfectly

Post Reply

Who is online

Users browsing this forum: hell_oh_world