How do you make animated text?
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.
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.
How do you make animated text?
I want to make animated text in my VN. The way it's animated is that it would be a random combination of characters and then change into another set of random characters in less than a second, repeating uninterruptedly. Is there a way to do that? Thanks.
-
- Veteran
- Posts: 479
- Joined: Tue Jun 05, 2012 2:01 am
- Contact:
Re: How do you make animated text?
If you're just talking about dialogue, you can use the {w} and {nw} text tags; see http://www.renpy.org/doc/html/text.html ... -text-tags . If you're using screen language, it supports timers; see http://www.renpy.org/doc/html/screens.html#timer .
If that isn't enough, please describe the effect in more detail.
If that isn't enough, please describe the effect in more detail.
- Nuxill
- Veteran
- Posts: 464
- Joined: Sat Sep 25, 2010 4:50 pm
- Projects: No Friend
- Tumblr: nuxill
- itch: nuxill
- Contact:
Re: How do you make animated text?
I think you might have to do that with images of the text and ATL http://www.renpy.org/doc/html/atl.html
I have no idea if it would be possible to do with code.
I have no idea if it would be possible to do with code.
Re: How do you make animated text?
Yeah, I'm talking about the dialogue. I found an example here: http://www.youtube.com/watch?v=0mcnEPstYTE. Skip to 1:29. It's the text that changes colours and characters.
- Nuxill
- Veteran
- Posts: 464
- Joined: Sat Sep 25, 2010 4:50 pm
- Projects: No Friend
- Tumblr: nuxill
- itch: nuxill
- Contact:
Re: How do you make animated text?
Yeah, that's the kind of thing I thought you were talking about. I still think it would be best to make a bunch of images of the text that look like how you want it to be and then animate that with ATL. You'd probably be able to do it with extra python programming but I have no idea how.Erthar wrote:Yeah, I'm talking about the dialogue. I found an example here: http://www.youtube.com/watch?v=0mcnEPstYTE. Skip to 1:29. It's the text that changes colours and characters.
-
- Veteran
- Posts: 479
- Joined: Tue Jun 05, 2012 2:01 am
- Contact:
Re: How do you make animated text?
Here's how you can do that effect:
Code: Select all
image flashingtext1:
crop (0, 0, 100, 22)
Text("{color=#f00}as{/color}{color=#0f0}df{/color}")
pause 1.0
Text("{color=#ff0}zx{/color}{color=#00f}cvvv{/color}")
pause 1.0
repeat
label start:
"This is some {image=flashingtext1} text.
Some more text to make it take up another line blah blah blah.
Some more text to make it take up another line blah blah blah."
return
Re: How do you make animated text?
Thanks apricotorange! That's exactly what I want! And thank you Nuxill for your time!
- xavimat
- Eileen-Class Veteran
- Posts: 1461
- Joined: Sat Feb 25, 2012 8:45 pm
- Completed: Yeshua, Jesus Life, Cops&Robbers
- Projects: Fear&Love
- Organization: Pilgrim Creations
- Github: xavi-mat
- itch: pilgrimcreations
- Location: Spain
- Discord: xavimat
- Contact:
Re: How do you make animated text?
For letters changing and appearing (I know, this is another effect), you can try this:
EDIT: There is a better way in the next post.
EDIT: There is a better way in the next post.
Code: Select all
image ft:
choice:
Text("{color=#f00}s{/color}")
choice:
Text("{color=#ff0}x{/color}")
choice:
Text("{color=#f00}θ{/color}")
choice:
Text("{color=#ff0}ω{/color}")
choice:
Text("{color=#f0f}שׂ{/color}")
choice:
Text("{color=#ff0}φ{/color}")
choice:
Text("{color=#00f}c{/color}")
choice:
Text("{color=#f0f}ד{/color}")
choice:
Text("{color=#f00}σ{/color}")
choice:
Text("{color=#ff0}ג{/color}")
pause .05
repeat
# The game starts here.
label start:
"{image=ft}{w=.2}{nw}"
"T{image=ft}{w=.2}{nw}"
"Th{image=ft}{w=.2}{nw}"
"Thi{image=ft}{w=.2}{nw}"
"This {image=ft}{w=.2}{nw}"
"This i{image=ft}{w=.2}{nw}"
"This is {image=ft}{w=.2}{nw}"
"This is s{image=ft}{w=.2}{nw}"
"This is so{image=ft}{w=.2}{nw}"
"This is som{image=ft}{w=.2}{nw}"
"This is some {image=ft}{w=.2}{nw}"
"This is some t{image=ft}{w=.2}{nw}"
"This is some te{image=ft}{w=.2}{nw}"
"This is some tex{image=ft}{w=.2}{nw}"
"This is some text."
Last edited by xavimat on Fri May 10, 2013 9:25 am, edited 3 times in total.
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)
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)
- xavimat
- Eileen-Class Veteran
- Posts: 1461
- Joined: Sat Feb 25, 2012 8:45 pm
- Completed: Yeshua, Jesus Life, Cops&Robbers
- Projects: Fear&Love
- Organization: Pilgrim Creations
- Github: xavi-mat
- itch: pilgrimcreations
- Location: Spain
- Discord: xavimat
- Contact:
Re: How do you make animated text?
Doing that with a function:
Put this in another ".rpy" file in your "game" directory, for example "flashtext.rpy":
Then, in your script you can use it this way:
And also with a defined character (note that the "ft()" function receives two arguments here):
What do you think? Is it working for you?
Put this in another ".rpy" file in your "game" directory, for example "flashtext.rpy":
Code: Select all
## flashtext
## (cc-by) xavimat, 2013
## based on apricotorange's code
init python:
def ft(what, who = None):
for i in range(len(what)): # A loop, letter by letter
text = what[:i]
text = "{cps=0}" + text # The {cps=0} makes the speed independent of the normal "say" statements
text += "{image=flash_text_image}{/cps}{nw}" # Add "{w=0.5}" between "{/cps}" and "{nw}" to slow down the text
renpy.say(who,text)
renpy.say(who, what + "{fast}") # The last one, with all the text
image flash_text_image:
# Change the colors as you like, or delete the color-tags, if you don't want the color changing
# Add, delete and/or change the letters as you like
choice:
Text("{color=#f00}s{/color}")
choice:
Text("{color=#ff0}x{/color}")
choice:
Text("{color=#f00}θ{/color}")
choice:
Text("{color=#ff0}ω{/color}")
choice:
Text("{color=#f0f}שׂ{/color}")
choice:
Text("{color=#ff0}φ{/color}")
choice:
Text("{color=#00f}c{/color}")
choice:
Text("{color=#f0f}ד{/color}")
choice:
Text("{color=#0f0}σ{/color}")
choice:
Text("{color=#ff0}ג{/color}")
pause .05 # This controls the speed of the changing letters, the lower, the faster
repeat
Code: Select all
label start:
"Ready?"
$ ft("Hello, I'm saying something!")
Code: Select all
define e = Character('Eileen', color="#c8ffc8")
# The game starts here.
label start:
"Ready?"
$ ft("And I'm Eileen and I say something too!", e)
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)
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)
Re: How do you make animated text?
That's a really nice effect, xavimat! I really like it. It works smoothly and without problems. I might use this. Thanks xavimat!
- xavimat
- Eileen-Class Veteran
- Posts: 1461
- Joined: Sat Feb 25, 2012 8:45 pm
- Completed: Yeshua, Jesus Life, Cops&Robbers
- Projects: Fear&Love
- Organization: Pilgrim Creations
- Github: xavi-mat
- itch: pilgrimcreations
- Location: Spain
- Discord: xavimat
- Contact:
Re: How do you make animated text?
You're welcome. Glad to be helpful.Erthar wrote:That's a really nice effect, xavimat! I really like it. It works smoothly and without problems. I might use this. Thanks xavimat!
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)
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)
Re: How do you make animated text?
Hello! I am newbie and I want to achieve the same dialogue/nvl effect - (gif - https://imgur.com/CRMpNjp)
Can this effect be achieved in a similar way? How can I do that? I searched for a long time, but didn't find the necessary information.
Can this effect be achieved in a similar way? How can I do that? I searched for a long time, but didn't find the necessary information.
Who is online
Users browsing this forum: thelastsecret