Display Chapter Label to player

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
Tox
Newbie
Posts: 9
Joined: Sat Jan 27, 2018 10:48 pm
Contact:

Display Chapter Label to player

#1 Post by Tox »

How does Katawa Shoujo display this information at the bottom?
Screen Shot 2018-02-19 at 17.45.58.png

User avatar
Hijiri
Eileen-Class Veteran
Posts: 1519
Joined: Sun Mar 25, 2012 6:35 pm
Completed: Death Rule:lost code Overdrive Edition, Where the White Doves Rest-Tsumihanseishi
Projects: Death Rule: Killing System
Organization: MESI Games
IRC Nick: Hizi
Tumblr: mesigames
Skype: kurotezuka
itch: hijiri
Location: Los Angeles
Contact:

Re: Display Chapter Label to player

#2 Post by Hijiri »

You just make a new screen and set a few values. Here's an example I posted before:

Code: Select all

define gamedays = {
        "default" : ["chap/day 0.png"],
        "D-0" : ["chap/day 0.png"],
        "D-1" : ["chap/day 1.png"],
        "D-2" : ["chap/day 2.png"],
        "D-3" : ["chap/day 3.png"],
        "D-4" : ["chap/day 4.png"],
        "D-5" : ["chap/day 5.png"],
        "D-6" : ["chap/day 6.png"],.
        }
define gamechapter = {
        "default" : ["chap/ch 0.png"],
        "CH-0" : ["chap/ch 0.png"],
        "CH-1_1" : ["chap/ch 1_1.png"],
        "CH-1_2" : ["chap/ch 1_2.png"],
        "CH-1_3" : ["chap/ch 1_3.png"],
        "CH-1_4" : ["chap/ch 1_4.png"],
        "CH-1_5" : ["chap/ch 1_5.png"],
        "CH-1_6" : ["chap/ch 1_6.png"],
        "CH-1_7" : ["chap/ch 1_7.png"],
        "CH-0_u" : ["chap/ch 0_u.png"],
        }
screen daychap:
    add "chap/chapbase.png" xalign 1.0 yalign 0
    #The part on top is a background
    for d in current_gameday:
        add d:
            pos (0, 0)
    for d in current_gamechapter:
        add d:
            pos (217, 0)
##This part below is in your script, where you set the initial values.
$ current_gameday = gamedays["D-0"]
$ current_gamechapter = gamechapter["CH-0"]
##You can then use this screen in your navigation screen
screen navigation:
    #Here goes all that nav code
    use screen daychap
Image Image
"Perfection goal that always changes. Can pursue, cannot obtain."

Post Reply

Who is online

Users browsing this forum: Google [Bot], Majestic-12 [Bot]