Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Marquee for Ren'Py

Create scrolling effects for text and other content larger than its container. · By Feniks

Need Support? Post here! Sticky

A topic by Feniks created Jan 13, 2024 Views: 794 Replies: 22
Viewing posts 1 to 7
Developer

If you're having trouble or run into any bugs with the code, post a comment here! I will try to get back to you within a few days.

I am not the most experienced when it comes to programming... how can I apply this to artist names and track titles with your Extended Music Room code? 

Developer

No worries! I included an example in the devlog for the music room when I released the marquee - you can find it here: https://feniksdev.itch.io/extended-music-room-for-renpy/devlog/665746/new-featur...

Let me know if that answers your question!

Can we use this package inside imagebuttons somehow? cause i tried doing so and and i cant use marquee: inside imageButtons.

image.png

Developer

You are correct that you cannot use the marquee inside an imagebutton directly, as imagebuttons do not have children. However, you can replicate that look via a button which has the text (and image if desired) inside the marquee container, with your white button background.

Hello! I really liked your asset with a running line and would like to add it to my game as a complementary element of the dialog box. However, I ran into difficulties, I can't combine the line with the window. Is it even possible to do this?

Developer

Hello! It's possible to add the marquee anywhere, really, but I can't help unless you share code of what you tried and outline what you want it to look like.

(1 edit)

Thank you for answering me!

I have sent you an archive with all the necessary data. This is the code of the novel itself, your file "01_marquee", an example of what the running lines should look like, and, just in case, the dialog box itself.

https://dropmefiles.com/vMUMQ
https://dropmefiles.com/vMUMQ
https://dropmefiles.com/vMUMQ

Developer

Please copy in the lines you're using to show the marquee + send an image directly in the comments. I won't be downloading files from sites I'm unfamiliar with, and it shouldn't require posting much code to show what the issue is.

Good Morning.  My goal is to show this as an overlay to the rest of my scene.  However, as it stands now, it simply exists on the screen, and does not allow the story to advance unless you utilize the separate "return" button.  Is there a way to simply have this as a news overlay while still allowing the story script itself to run?

Developer

Show the screen instead of calling it, and make sure there's nothing on the screen blocking progress (including modal True). See this article for details on the difference: https://feniksdev.com/renpy-screen-language-basics-declaring-and-showing-a-scree...

so simple.  now i feel stupid.  thanks :D

[i do mean that as a legit thanks too.  i just feel silly for not realizing it :D ]

(10 edits)

Hello! Thank you so much for the tool. I’ve been fiddling around to use this in our music room, and I was wondering if there was a way to make the animation reset when I click between two different song names that require the marquee. In the gif above, when switching between “I’ve Seen Something I Shouldn’t Have//Sign”​ and “I’ve Seen Something I Shouldn’t Have//Noir”​, the position in the marquee is saved between the two, which makes the song title harder to read when it’s first clicked on. I noticed this animation resets when clicking on a shorter name that doesn’t require marquee and then the longer name, and that’s the ideal behavior we’d like for switching between any songs.

Thank you!

​

marquee:
    xsize 800 ysize 60
    animation marquee_pan(30.0)
    always_animate False
    text "{font=gui/fonts/EBGaramond-Medium.ttf}[song_name]{/font}":
    layout 'nobreak'
transform marquee_pan(t, delay=0.5):
    xpan 0 subpixel True
    pause delay
    linear t xpan 360
    repeat
Developer(+1)

No problem! The solution here is actually to just set it to text song_name as opposed to text "[song_name]" (and you can add the font as a property i.e. text song_name font "gui/fonts/EBGaramond-Medium.ttf"), since that will mean that the "child" is different when the text updates (vs when it's just text "[song_name]", although the substitution means that song_name is changing, to the marquee, it's still the same object). Hope that does what you want!

Thank you so much! This worked perfectly!!

Hi, this code works fantastically - just wanted to ask, though, is there a way to make it so the autoscroll on the marquee_pan transformation doesn't reset on every click/line of new dialogue? I've been looking through the code but I'm not totally sure if it's something I can adjust for, or it's just kind of how ren'py works.

Developer

Hey there! Could you share the code you're using for this so I can try to recreate it?

Sure!

The marquee_conf screen that's called here is a modified version of the default marquee script from the examples.rpy with all code comments intact; I just tweaked the text and the coordinates of the frame to make it show up in a different place.


Developer

Unfortunately I'm unable to recreate this on Ren'Py 8.5.3. Showing a marquee with dialogue, NVL or regular ADV, does not cause the animation to reset for me. I suspect you may have something going on in your NVL screen? If you can recreate the problem in a default project, let me know the Ren'Py version you're using and the code.

Oh that's...extremely interesting news! :') Thank you for taking the time to test it out, I will go looking around in the NVL screen to see if I can fix this problem. And thank you again for making this code! 

Oh my god okay I fixed it. I'm replying here just because I thought you'd like to know, but literally the only reason it reset on every click because the screen marquee_conf was not screen marquee_conf():  Literally a difference of two brackets ;_;

Developer

Oh interesting, thanks for reporting back! Yeah the parentheses for screens improves prediction since it indicates the screen will not receive arguments, though this is an interesting side effect of that also. I appreciate the investigation!