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.
I'm trying to compare the string that I'm getting from user input with a pre-determined string in order to add to the stat (intelligence) determined by the dating sim framework.
If I run $ intelligence += 30 outside of the if statement, it works, so I'm sure that's not the problem.
I think it's just not comparing "%(yourname)s" and "JOHN" the way that I want it to, which is if someone types in "JOHN," it will compare "JOHN" with "JOHN".
Last edited by xylia on Thu Oct 21, 2010 1:26 am, edited 1 time in total.
Keep in mind that string comparisons are case-sensitive in Python, so if you want to match "JOHN" with something like "John" or "john", you will need to do something like this: