SFML community forums
Help => Graphics => Topic started by: Dark254 on October 05, 2020, 07:23:28 pm
-
Hello everyone!
I want to implement creeping line like in visual novels. I tried to tie the output to the time, created additional lines, tried to draw the output by characters, but nothing helped.
Can you help me please? How can i do it with SFML? :)
-
I think, you may need to be a bit more specific what "creeping line" is exactly.
A lot of effects you see in games, are often just textures rendered on top of things or some shaders.
-
I was not familiar with this term but it seems you want a simple text "scroller" or "marquee"?
Normally you can achieve this by animating the entire text's position (probably towards the left). If you want them cropped, the simplest way is to draw over the area they shouldn't appear although you could use a form of clipping to do it too.
Another way would be to draw it to a render texture and then animate the texture rectangle to move (probably to the right) but keep its size. Then draw that texture to the window using a sprite or rectangle.
-
Ok, thank you guys. I solved this!