[SOLVED] what_prefix showing during dialogue box transitions

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
hassohappa
Regular
Posts: 33
Joined: Thu Oct 22, 2015 8:51 pm
Tumblr: me-patra
Contact:

[SOLVED] what_prefix showing during dialogue box transitions

#1 Post by hassohappa » Sat Jan 23, 2016 6:41 pm

My game's narration puts a ">" symbol before every line like in Persona games, like: ">You ate grass. "
To avoid having to manually type a ">" before every sentence, I set my narrator's what_prefix to ">". This works great, except the ">" now gets included in dialogue box transitions...

For example, if the window was hidden and I put "window show dissolve", the ">" will fade in with the window before the rest of the text.
And if I do "window show dissolve", the ">" dissolves along with the window instead of disappearing with the rest of the text.

Is there any way around this without deleting the what_prefix?
Last edited by hassohappa on Sun Jan 24, 2016 4:30 am, edited 1 time in total.

User avatar
PyTom
Ren'Py Creator
Posts: 15893
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: what_prefix showing during dialogue box transitions

#2 Post by PyTom » Sun Jan 24, 2016 3:29 am

Code: Select all

init python:
    ewc = Character(None)

    def my_empty_window():
         ewc("", interact=False)

    config.empty_window = my_empty_window
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

User avatar
hassohappa
Regular
Posts: 33
Joined: Thu Oct 22, 2015 8:51 pm
Tumblr: me-patra
Contact:

Re: what_prefix showing during dialogue box transitions

#3 Post by hassohappa » Sun Jan 24, 2016 4:30 am

This solved my problem! Thanks so much, Tom!!

Post Reply

Who is online

Users browsing this forum: Bing [Bot], span4ev