xsize command not functioning

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
Guy110
Newbie
Posts: 10
Joined: Thu Oct 22, 2015 7:29 pm
Contact:

xsize command not functioning

#1 Post by Guy110 »

I must be missing something very obvious here, because this seems very strange to me. I'm in the process of adding a biography menu to my game, and all I'm trying to do is get the text to wrap around a frame's maximum size. My code is as follows:

Code: Select all

screen ryan_bio1:
    tag menu
    
    add "images/01/ln.png" xalign .10 yalign .50
    
    frame:
    
        xalign .75
        yalign .25
        xsize 10
        
        vbox:
            box_wrap "true"
            xsize 10
            text "Name: Ryan Maguire"
            text "Birthdate: May 1, 1997"
            text "Age: 16 years old"
            text "Hometown: n/a"
            text "Home Planet: Earth"
            text "ttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttt"
        
    vbox:
        xalign .98
        yalign .98
        
        textbutton _("Return") action ShowMenu("bio") xalign 0.5
The repeating "t"s is a test to ensure that the singular text command wraps around successfully, which it does not, as seen here: Image
Any help establishing a consistent frame or vbox width (and by extension, height) is very much appreciated.

User avatar
Guy110
Newbie
Posts: 10
Joined: Thu Oct 22, 2015 7:29 pm
Contact:

Re: xsize command not functioning

#2 Post by Guy110 »

Update: This is caused by my test line being one word. The xsize command works properly if everything is properly spaced.

Post Reply

Who is online

Users browsing this forum: Google [Bot]