Best way to jump to a label from the main menu?

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
richycapy
Regular
Posts: 35
Joined: Mon May 27, 2019 8:53 pm
Organization: EN Productions
Location: Mexico
Contact:

Best way to jump to a label from the main menu?

#1 Post by richycapy » Sat Oct 26, 2019 7:24 pm

Hi

Im creating a gallery for my game, however, since there will be images and movies, I cant use the BG Gallery from the forum
I already created a simple "screen" to see an image

Code: Select all

screen verfoto(pic=False):
    modal True zorder 10
    add 'images/splash/gi/'+pic+'.png'
    button background None action Hide('verfoto')
    
imagebutton auto "images/gui/galeria/thumbs/chloe-imagen-01_%s.png" action Show("verfoto", dissolve, "chloe-imagen-01")
But I dont know how to jump to a lable to see a complete scene... let say the ending, from my gallery page, I would like to "jump" to a label, so it would be something like this:

Code: Select all

screen vervideo(labelname):
    $ replayscene = True
    jump labelname

imagebutton auto "images/gui/galeria/thumbs/chloe-imagen-01_%s.png" action Show("vervideo", dissolve, "labelending")

Code: Select all

label labelending:
    scene black

	.... play somenthing ...
    
    if replayscene:
        $ replayscene = False
        return
        
    jump creditsandending
I would apreciate a lot the help with this :D

User avatar
rayminator
Veteran
Posts: 271
Joined: Fri Feb 09, 2018 12:05 am
Projects: Redoing games to fix spelling mistakes other companys that don't care
Location: Canada
Contact:

Re: Best way to jump to a label from the main menu?

#2 Post by rayminator » Sat Oct 26, 2019 8:42 pm

do this use a jump or call just make sure the first letter are in capital's

Code: Select all

imagebutton auto "images/gui/galeria/thumbs/chloe-imagen-01_%s.png" action Jump("vervideo", dissolve, "labelending")

or 

imagebutton auto "images/gui/galeria/thumbs/chloe-imagen-01_%s.png" action Call("vervideo", dissolve, "labelending")

User avatar
xavimat
Eileen-Class Veteran
Posts: 1433
Joined: Sat Feb 25, 2012 8:45 pm
Completed: Yeshua, Jesus Life, Cops&Robbers
Projects: Fear&Love, unknown
Organization: Pilgrim Creations
Github: xavi-mat
itch: xavimat
Location: Italy
Contact:

Re: Best way to jump to a label from the main menu?

#3 Post by xavimat » Sun Oct 27, 2019 3:35 am

Comunidad Ren'Py en español: ¡Únete a nuestro Discord!
Cops&Robbers A two-player experiment
Fear&Love Why can’t we simply express our feelings? Why am I afraid to say ‘I love you’?
Honest Critique (Avatar made with Chibi Maker by ~gen8)

User avatar
isobellesophia
Miko-Class Veteran
Posts: 714
Joined: Mon Jan 07, 2019 2:55 am
Projects: Maddox's Everyday Talk! (13+ Unreal version), Maddox Everyday Talk! (3+ Real-Friendly version)(Upcoming 2020)
Organization: Friendly Teachers series
itch: .......
Location: Philippines, Mindanao
Contact:

Re: Best way to jump to a label from the main menu?

#4 Post by isobellesophia » Sun Oct 27, 2019 5:20 am

You can also use Jump() at any labels.
I am a friendly user, please respect and have a good day..


Working on a talking simulation game for everyone, except children.

Maddox Everyday Talk!
Is my very very main project, not contain 13 below.

Main project here viewtopic.php?f=43&t=56564
Image

Post Reply

Who is online

Users browsing this forum: No registered users