Made a skin color screen [Solved] See her new 6 shades

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.
Message
Author
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: Help! I need to make a skin color screen/dress-up screen [Help! unsolved]

#16 Post by Per K Grok »

beastcarving wrote: Wed Nov 06, 2019 11:01 pm
-------


Every time I try to show the "sad" image I always get an error. Here is what I've been typing.

Code: Select all

    label starting:
       show screen dressup_button
       show screen dressup
       $ dressup_button_show = True
       $ dressup_show = False
    show sad 
    "hello. I'm sad"  
There is no connection between
show sad
and the screen.

show sad
looks for an image named i.e. sad.png
or an image defined as
image sad="qwerty.png"
When no such image can be found you get an error.
beastcarving wrote: Wed Nov 06, 2019 11:01 pm -----

Code: Select all

        if girl==1:
            add "skin1.png"
            if girl=="sad":
                #show skinsadl
                add "skinsadl.png"
            elif girl=="m":
                add "skinsadl.png"
            elif girl=="s":
                add "skinsadl.png"
 
----
Here "girl" is a variable. It can only hold one value at a time. If girl==1, it cannot also be "sad", "m" or "s" at the same time.

How about just trying the code I suggested earlier without trying to customize it? Once you got the code running you can start customizing it, in small steps so you can see where it goes wrong.

User avatar
beastcarving
Regular
Posts: 139
Joined: Mon May 13, 2019 5:03 pm
Completed: Pulse Cage https://beastcarving.itch.io/pulse-cage-the-full-series
Projects: Your Brother's Religion
Organization: BeastCarving Studio
IRC Nick: BeastCarving
Tumblr: beastcarving
Deviantart: beastcarving
Github: beastcarving
itch: beastcarving
Contact:

Re: Help! I need to make a skin color screen/dress-up screen [Help! unsolved]

#17 Post by beastcarving »

Code: Select all

    image bg gray="#777"

    default skinNumber=1
    default face='h'

    screen papperdoll():

        if skinNumber==1:
            add "skin1.png"
            if face== 's':
                image = "skinsadl.png"

        elif skinNumber==2:
            add "skin2.png"
            if face== 's':
                image = "skinsadm.png"
        elif skinNumber==3:
            add "skin3.png"
            if face== 's':
                image = "skinsadd.png"

        textbutton "1" action SetVariable("skinNumber", 1) pos (10, 50)
        textbutton "2" action SetVariable("skinNumber", 2) pos (10, 70)
        textbutton "3" action SetVariable("skinNumber", 3) pos (10, 90)

    label starts:
        scene bg gray
        show screen papperdoll

        $ renpy.pause(hard=True) 
        "I'm sad."
        show face=='s'
Okay so I went back and took all the other customizes out. I'm trying to figure out how to make the paperdoll's sad expression show, then I'll add happy and mad when I get one of them to work. I'm trying to show it like this:

Code: Select all

show face 's'
I've also tried putting this:

Code: Select all

show 'f'
Neither are working so far. I'd like to know how I can get the paperdoll to remain customized and change expressions as the story goes on.
Image Pulse Cage (full game)Image Your Brother's Religion (Demo)
PLAY HERE: https://beastcarving.itch.io/
Love my work: https://www.patreon.com/beastcarving

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: Help! I need to make a skin color screen/dress-up screen [Help! unsolved]

#18 Post by Per K Grok »

beastcarving wrote: Thu Nov 07, 2019 10:02 pm

Code: Select all

    image bg gray="#777"

    default skinNumber=1
    default face='h'

    screen papperdoll():

        if skinNumber==1:
            add "skin1.png"
            if face== 's':
                image = "skinsadl.png"

        elif skinNumber==2:
            add "skin2.png"
            if face== 's':
                image = "skinsadm.png"
        elif skinNumber==3:
            add "skin3.png"
            if face== 's':
                image = "skinsadd.png"

        textbutton "1" action SetVariable("skinNumber", 1) pos (10, 50)
        textbutton "2" action SetVariable("skinNumber", 2) pos (10, 70)
        textbutton "3" action SetVariable("skinNumber", 3) pos (10, 90)

    label starts:
        scene bg gray
        show screen papperdoll

        $ renpy.pause(hard=True) 
        "I'm sad."
        show face=='s'
Okay so I went back and took all the other customizes out. I'm trying to figure out how to make the paperdoll's sad expression show, then I'll add happy and mad when I get one of them to work. I'm trying to show it like this:

Code: Select all

show face 's'
I've also tried putting this:

Code: Select all

show 'f'
Neither are working so far. I'd like to know how I can get the paperdoll to remain customized and change expressions as the story goes on.

That is not the code I wrote. There was no "show face=='s'" or show anything at all in it.

'show' is for images in a label. I can now see that that is what you are looking for when you say "change expressions as the story goes on".
You need something different. Layeredimages is more in line with what you now are talking about. try this, without changing anything.

Code: Select all


layeredimage girl:

    group skin:
        attribute skin1 default:
            "skin1"
        attribute skin2:
            "skin2"
        attribute skin3:
            "skin3"


    group face:

        attribute happy1:
            "happy1"

        attribute mad1:
            "mad1"

        attribute sad1:
            "sad1"

        attribute happy2:
            "happy2"

        attribute mad2:
            "mad2"

        attribute sad2:
            "sad2"

        attribute happy3:
            "happy3"

        attribute mad3:
            "mad3"

        attribute sad3:
            "sad3"


    group outfit:

        attribute dress default:
            "dress"



default pickgirl=1

screen picker():
    vbox:
        style_prefix "radio"

        textbutton _("Girl 1") action SetVariable("pickgirl", 1), Jump ("start")
        textbutton _("Girl 2") action SetVariable("pickgirl", 2), Jump ("start")
        textbutton _("Girl 3") action SetVariable("pickgirl", 3), Jump ("start")



label start:
    show screen picker

    if pickgirl==1:
        show girl skin1 sad1

    elif pickgirl==2:
        show girl skin2 sad2

    elif pickgirl==3:
        show girl skin3 sad3

    "Hello. I'm sad."
    pause


User avatar
beastcarving
Regular
Posts: 139
Joined: Mon May 13, 2019 5:03 pm
Completed: Pulse Cage https://beastcarving.itch.io/pulse-cage-the-full-series
Projects: Your Brother's Religion
Organization: BeastCarving Studio
IRC Nick: BeastCarving
Tumblr: beastcarving
Deviantart: beastcarving
Github: beastcarving
itch: beastcarving
Contact:

Re: Help! I need to make a skin color screen/dress-up screen [Help! unsolved]

#19 Post by beastcarving »

Everything works as I wanted it to. Thanks for helping me make this possible.

Image

I'd like to quickly express why I wanted to make this screen and what to expect. MC number 1 now comes with 6 new looks. I am still thinking of making 2 MCs, but now both MCs will have customizable skin colors. Some VNs only have 3 or sometimes 4 skin colors.

Usually, the mediums and very fair complexions aren't included. Sometimes only mediums are included so they all look pretty much the same. So far I have 6 shades with slightly different features. I'm open to suggestions if I left out any features you'd like to see or other shades. I wanted MC number 1 to look like the same person so I only changed a few things that would better fit each shade, her hair color being one of them, so I made her makeup and hair color look flattering to each shade.

Some VNs don't do that. They would usually change the color and not alter the features or the color of the features. Have you ever changed the color of a character with light skin only to have really dark lips, or changed a character to dark skin and they would have really pale lips? I'm one that plays all shades of characters, so I've seen both. I think I've done a good job of matching the lips, hair color, and makeup to suit each shade because I want everyone to have a pretty MC. Remember, let me know what you think, and I can't wait to show this new feature in the next update.
Image Pulse Cage (full game)Image Your Brother's Religion (Demo)
PLAY HERE: https://beastcarving.itch.io/
Love my work: https://www.patreon.com/beastcarving

Post Reply

Who is online

Users browsing this forum: No registered users