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.
-
Kia
- Eileen-Class Veteran
- Posts: 1011
- Joined: Fri Aug 01, 2014 7:49 am
- Deviantart: KiaAzad
- Discord: Kia#6810
-
Contact:
#1
Post
by Kia » Sat Jan 23, 2016 12:03 pm
I'm solving a little problem for showing a different navigation menu when the player goes to the load screen from the main menu.
I tried to pass name of the navigation menu to the screen as argument but looks like the "use" statement don't take variables.
the next solution was having two load screen is too attached to its name
Code: Select all
screen load1():
# This ensures that any other menu screen is replaced.
tag menu
use navigation1
use file_picker
any suggestions?
Last edited by
Kia on Sun Jan 24, 2016 7:18 am, edited 1 time in total.
-
ringonoki-ua
- Newbie
- Posts: 15
- Joined: Thu Mar 19, 2015 11:48 am
- Projects: Rozumnyk/Sofia
- Deviantart: ringonoki
- Skype: ringonoki-ua
- Location: Kyiv, Ukraine
-
Contact:
#2
Post
by ringonoki-ua » Sun Jan 24, 2016 5:31 am
Is it even possible?
-
chocojax
- Miko-Class Veteran
- Posts: 702
- Joined: Sun Oct 25, 2009 11:27 am
- Completed: http://art.jphi.me/projects
- Projects: Umbra, Familiarity, Maleficent Justice
- Organization: spaceNote
- Tumblr: chocojax
- Github: jenniferphi
- Location: California
-
Contact:
#3
Post
by chocojax » Sun Jan 24, 2016 5:51 am
If you want to pass a variable to a screen, you'll have to give it a name when defining the screen. A simple solution could be passing in an int value:
Code: Select all
screen load1(navi):
if navi is 0:
use navigation
else:
use navigation1
-
Kia
- Eileen-Class Veteran
- Posts: 1011
- Joined: Fri Aug 01, 2014 7:49 am
- Deviantart: KiaAzad
- Discord: Kia#6810
-
Contact:
#4
Post
by Kia » Sun Jan 24, 2016 6:01 am
thanks chocojax ^_^ I wonder why I didn't think about that.
Users browsing this forum: Bing [Bot]