null

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
Kiyo
Newbie
Posts: 10
Joined: Fri Jan 31, 2020 11:43 pm

null

#1 Post by Kiyo » Tue Mar 31, 2020 12:01 am

null
Attachments
bar.png
(5.34 KiB) Not downloaded yet
Last edited by Kiyo on Sat Jun 13, 2020 11:53 pm, edited 1 time in total.

User avatar
Per K Grok
Miko-Class Veteran
Posts: 882
Joined: Fri May 18, 2018 1:02 am
Completed: the Ghost Pilot, Sea of Lost Ships, Bubbles and the Pterodactyls, Defenders of Adacan Part 1-3, the Phantom Flyer
itch: per-k-grok
Location: Sverige
Contact:

Re: Vertical Bar

#2 Post by Per K Grok » Tue Mar 31, 2020 1:40 am

Kiyo wrote:
Tue Mar 31, 2020 12:01 am
Hello, how do I make this bar to appear in vertical? I tried ways to make it but it doesn't do any good. Hope you can help me with itbar.png
The way I do stuff like health bars is like this (possibly a bit unorthodox in a renpy game). It is a red bar on white background.

Code: Select all

    fixed:
        pos (0, 0)
        
        fixed:
            pos (20, 30)
            xysize (104,34)
            add Solid("#fff") pos (0, 0)
            
            fixed:
                pos (2, 2)
                xysize (MBhealth,30)
                if MBhealth>0:
                    add Solid("#f00") pos (0, 0)
MBhealth being the health value of one character. Full health being 100.
To make it vertical just switch place off the x and y values of xysize for both the white box and the red.

User avatar
xavimat
Eileen-Class Veteran
Posts: 1458
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: pilgrimcreations
Location: Spain
Contact:

Re: Vertical Bar

#3 Post by xavimat » Tue Mar 31, 2020 2:39 pm

Comunidad Ren'Py en español: ¡Únete a nuestro Discord!
Rhaier Kingdom A Ren'Py Multiplayer Adventure Visual Novel.
Cops&Robbers A two-player experiment | Fear&Love Why can't we say I love you?
Honest Critique (Avatar made with Chibi Maker by ~gen8)

Post Reply

Who is online

Users browsing this forum: No registered users