[SOLVED] CG Gallery help?

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
rusicaria
Regular
Posts: 84
Joined: Sat Mar 28, 2020 12:26 am
Projects: VivaCity (VN)
Tumblr: rusicariaGAMES
itch: rusicariaGAMES
Contact:

[SOLVED] CG Gallery help?

#1 Post by rusicaria »

Hello!

I've got a few things that I need help with, if anyone knows anything about making a cg gallery? Before, when clicking on the cg button to open up the art scene, it would show the art scene PLUS a smaller size of it at the bottom of the screen.
Screenshot 2021-05-03 19.42.40.png
I'd really like to get rid of this, but I don't know how.
Also, when I was adjusting the placement of the cg buttons when I went to click on the cg, it now shows just a black screen? And the little cg is still at the bottom.
Screenshot 2021-05-05 17.39.31.png
Here's the code that I have for this screen:

Code: Select all

init python:
    g = Gallery()

    g.button("thielart1")
    g.condition("persistent.thielart1")
    g.image("thielart1.jpg")

    g.button("jaylaart1")
    g.condition("persistent.jaylaart1")
    g.image("jaylaart1.jpg")

    g.button("crisart1")
    g.condition("persistent.crisart1")
    g.image("crisart1.jpg")

    g.button("eliorart1")
    g.condition("persistent.eliorart1")
    g.image("eliorart1.jpg")

screen gallery2:

    tag menu

    add "game_menu.jpg"

    grid 4 4:
        add Null()
        add Null()
        add Null()
        add Null()
        add Null()
        add g.make_button("thielart1","thielart1.jpg", locked = "lock.png", xalign=0.5, yalign=0.17)  # I adjusted the yalign to fit, and since then it's come up with a black screen.
        add g.make_button("jaylaart1", "jaylaart1.jpg", locked = "lock.png", xalign=0.5, yalign=0.17)  # 2
        add Null()
        add Null()
        add g.make_button("crisart1", "crisart1.jpg", locked = "lock.png", xalign=0.5, yalign=0.5)  # 3
        add g.make_button("eliorart1", "eliortart1.jpg", locked = "lock.png", xalign=0.5, yalign=0.5)  #4
        add Null()
        add Null()
        add Null()
        textbutton "Next" action ShowMenu("gallery3") xalign 1.6 yalign -2.3
        textbutton "Return" action Return() xalign 0.05 yalign -2.1
Any and all help is greatly appreciated! I've been trying to sort this out for a long time and I really don't want to have to give up on making a cg gallery for my game :cry:
Last edited by rusicaria on Sun May 15, 2022 12:33 pm, edited 1 time in total.

User avatar
mavyxdawn
Regular
Posts: 72
Joined: Sun Dec 20, 2015 6:18 pm
Github: mavyxdawn
itch: zeillearnings
Discord: _zeil
Contact:

Re: CG Gallery help?

#2 Post by mavyxdawn »

Hi! I'd like to help you finish with your CG Gallery. I'd volunteer to do it for you since I have free time and I've done it before.
Or if you want to do it yourself, it would be easier for me to help you if you upload the images as well. (You can add watermark if you don't feel comfortable uploading it)
YouTube: Zeil Learnings
itch.io: Zeil Learnings

Image

User avatar
rusicaria
Regular
Posts: 84
Joined: Sat Mar 28, 2020 12:26 am
Projects: VivaCity (VN)
Tumblr: rusicariaGAMES
itch: rusicariaGAMES
Contact:

Re: CG Gallery help?

#3 Post by rusicaria »

mavyxdawn wrote: Wed May 05, 2021 6:45 pm Hi! I'd like to help you finish with your CG Gallery. I'd volunteer to do it for you since I have free time and I've done it before.
Or if you want to do it yourself, it would be easier for me to help you if you upload the images as well. (You can add watermark if you don't feel comfortable uploading it)
Oh my gosh, you would be an absolute life saver!!

User avatar
mavyxdawn
Regular
Posts: 72
Joined: Sun Dec 20, 2015 6:18 pm
Github: mavyxdawn
itch: zeillearnings
Discord: _zeil
Contact:

Re: CG Gallery help?

#4 Post by mavyxdawn »

For anyone curious, here's the result of the code:
Image

Code: Select all

init python:
    g = Gallery()

    g.button("thielart1")
    # g.condition("persistent.thielart1")
    g.image("thielart1.jpg")

    g.button("jaylaart1")
    # g.condition("persistent.jaylaart1")
    g.image("jaylaart1.jpg")

    g.button("crisart1")
    # g.condition("persistent.crisart1")
    g.image("crisart1.jpg")

    g.button("eliorart1")
    # g.condition("persistent.eliorart1")
    g.image("eliorart1.jpg")

screen gallery2:
    tag menu
    add "background/game_menu.jpg"

    hbox:
        yalign 0.5
        xalign 0.5
        grid 2 2:
            xspacing 25
            yspacing 70
            add g.make_button("thielart1","thielart1_small.jpg", locked = "lock.png")
            add g.make_button("jaylaart1", "jaylaart1_small.jpg", locked = "lock.png")

            add g.make_button("crisart1", "crisart1_small.jpg", locked = "lock.png")
            add g.make_button("eliorart1", "eliorart1_small.jpg", locked = "lock.png")
        vbox:
            xoffset 20 ##this is the space between the gridbox and the "Next" and "Return" button
            textbutton "Next" action ShowMenu("gallery3") 
            textbutton "Return" action Return() 
YouTube: Zeil Learnings
itch.io: Zeil Learnings

Image

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Baidu [Spider], konimyun