Add dissolve to specific character positions.

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
Kokoro
Newbie
Posts: 11
Joined: Sat Jul 15, 2017 10:06 pm
Contact:

Add dissolve to specific character positions.

#1 Post by Kokoro »

Hi!
I'm having a bit of trouble, so I'm trying to have characters appear on the screen with four different locations. This is the code I use:

Code: Select all

init:
    $ position2 = Position(xpos=0.25, xanchor=0.5, ypos=0.5, yanchor=0.5)
    
init:
    $ position1 = Position(xpos=0.13, xanchor=0.5, ypos=0.5, yanchor=0.5)
    
init:
    $ position3 = Position(xpos=0.75, xanchor=0.5, ypos=0.5, yanchor=0.5)
    
init:
    $ position4 = Position(xpos=0.87, xanchor=0.5, ypos=0.5, yanchor=0.5)
I would write out script like this:

Code: Select all

show des at position1
with dissolve
This puts the characters where I want them, but it stops my dissolve command, making them just snap into place.

I'm doing my head in over something I think might be pretty simple! I'm really new to renpy so any help is needed! Thanks!!

User avatar
Remix
Eileen-Class Veteran
Posts: 1628
Joined: Tue May 30, 2017 6:10 am
Completed: None... yet (as I'm still looking for an artist)
Projects: An un-named anime based trainer game
Contact:

Re: Add dissolve to specific character positions.

#2 Post by Remix »

ATL time...

Code: Select all

transform pos1d:
    pos (0.25, 0.5)
    align (0.5, 0.5)
    on show:
         dissolve

show des at pos1d

would then use dissolve when doing show... you could add on hide too etc

typed on the fly, may need tweaking
Frameworks & Scriptlets:

User avatar
Kokoro
Newbie
Posts: 11
Joined: Sat Jul 15, 2017 10:06 pm
Contact:

Re: Add dissolve to specific character positions.

#3 Post by Kokoro »

Thanks for the reply! Unfortunately the code doesn't seem to work. I get the error:

Exception: Not a displayable: <curry <class 'renpy.display.transition.Dissolve'> (0.5,) {}>

Not too sure what it means...

User avatar
Remix
Eileen-Class Veteran
Posts: 1628
Joined: Tue May 30, 2017 6:10 am
Completed: None... yet (as I'm still looking for an artist)
Projects: An un-named anime based trainer game
Contact:

Re: Add dissolve to specific character positions.

#4 Post by Remix »

You might have to change the word 'dissolve' for something like 'with Dissolve(0.5)' similar to:

this link

Late here now and working tomorrow. Might have a play after that though and find what works
Frameworks & Scriptlets:

User avatar
Kokoro
Newbie
Posts: 11
Joined: Sat Jul 15, 2017 10:06 pm
Contact:

Re: Add dissolve to specific character positions.

#5 Post by Kokoro »

Thanks for all your help! I managed to get it working n_n;

Post Reply

Who is online

Users browsing this forum: Semrush [Bot]