If menu statement question (Solved)

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
wakagana
Veteran
Posts: 374
Joined: Mon May 14, 2012 1:27 am
Projects: Flash Q
Organization: Team Bread
Contact:

If menu statement question (Solved)

#1 Post by wakagana » Thu Jul 05, 2012 12:14 pm

I've looked over the Remembering User Choices section on the Ren'py website and I didn't find as to whether or not you could do this, but I'm trying to set up and option that would allow to do this

"I'll do this" if G_points > K_points ( But I also want it to be so that --- ) "I'll do this" if G_points = K_points

I'm taking a wild guess but would it instead be

"I'll do this" elif G_points > or = K_points

Am I close or completley wrong? Thanks for the help ahead of time.
Last edited by wakagana on Thu Jul 05, 2012 1:31 pm, edited 1 time in total.

User avatar
Showsni
Miko-Class Veteran
Posts: 563
Joined: Tue Jul 24, 2007 12:58 pm
Contact:

Re: If menu statement question

#2 Post by Showsni » Thu Jul 05, 2012 1:23 pm

The greater than or equal sign in python is >= so you'd say
"I'll do this" if G_points >= K_points:

You could also say

"I'll do this" if G_points > K_points or G_points == K_points:

if you wanted, but why make it longer when you don't have to?

User avatar
wakagana
Veteran
Posts: 374
Joined: Mon May 14, 2012 1:27 am
Projects: Flash Q
Organization: Team Bread
Contact:

Re: If menu statement question

#3 Post by wakagana » Thu Jul 05, 2012 1:31 pm

Thank you. For what ever reason I figured >= was not valid for an option. >.> -headdesk-

Post Reply

Who is online

Users browsing this forum: Bing [Bot]