Help with Renpy Notifcations

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
JustAlexander
Newbie
Posts: 21
Joined: Sun Mar 03, 2019 9:27 am
Contact:

Help with Renpy Notifcations

#1 Post by JustAlexander »

So... It's my second time posting here, and I have another problem.
I wonder if you can format the text you show by using renpy.notify for example making one word bigger, or make it red, or bold.
I tried doing it myself but instead of changing the text it displayed the code.
For example instead of:

Test Of Strentgh

it was

Code: Select all

{b}Test of Strenght{/b}
Is there any way to fix it? Or I should just give up on formating notifications?

strayerror
Regular
Posts: 159
Joined: Fri Jan 04, 2019 3:44 pm
Contact:

Re: Help with Renpy Notifcations

#2 Post by strayerror »

You can customise how notifications are displayed by editing screen notify(message): in screens.rpy. By finding the following section within it and removing the q qualifier formatting will be permitted:

Code: Select all

    frame at notify_appear:
        text "[message!tq]" # remove the q here to allow formatting

JustAlexander
Newbie
Posts: 21
Joined: Sun Mar 03, 2019 9:27 am
Contact:

Re: Help with Renpy Notifcations

#3 Post by JustAlexander »

Thanks for help! I tried to remove the q, but if found a new problem:
For some reason, the game has problem with the line 906 (Which is weird, because this is NOT the line where the notify screen was)
The line 906 looks like this:

Code: Select all

                    label h.who:
                        style "history_name"
                        substitute False
And the message it appears says line 906: u"substitute is not a keyword, argument or valid child for that label statement.
substitute -> False"

I don't understand it... Should I change "False" to "True" or remove that line completly?

JustAlexander
Newbie
Posts: 21
Joined: Sun Mar 03, 2019 9:27 am
Contact:

Re: Help with Renpy Notifcations

#4 Post by JustAlexander »

Thanks for help! I tried to remove the q, but if found a new problem:
For some reason, the game has problem with the line 906 (Which is weird, because this is NOT the line where the notify screen was)
The line 906 looks like this:

Code: Select all

                    label h.who:
                        style "history_name"
                        substitute False
And the message it appears says line 906: u"substitute is not a keyword, argument or valid child for that label statement.
substitute -> False"

I don't understand it... Should I change "False" to "True" or remove that line completly?

strayerror
Regular
Posts: 159
Joined: Fri Jan 04, 2019 3:44 pm
Contact:

Re: Help with Renpy Notifcations

#5 Post by strayerror »

I vaguely recall seeing that error when switching between versions of Ren'Py, so I suspect that editing screens.rpy probably triggered a recompile which is now failing due to the version of Ren'Py you're using not being the same as the version that generated screens.rpy orginally.

JustAlexander
Newbie
Posts: 21
Joined: Sun Mar 03, 2019 9:27 am
Contact:

Re: Help with Renpy Notifcations

#6 Post by JustAlexander »

So, how can I fix that?
From what you're saying it kinda sounds like I should rewrite the whole screens.rpy

User avatar
Imperf3kt
Lemma-Class Veteran
Posts: 3794
Joined: Mon Dec 14, 2015 5:05 am
itch: Imperf3kt
Location: Your monitor
Contact:

Re: Help with Renpy Notifcations

#7 Post by Imperf3kt »

Perhaps attach your screens.rpy file so we can check it over.
Sometimes the error screen reports the wrong line because that's when the error was detected, but not necessarily when the error took place.
Warning: May contain trace amounts of gratuitous plot.
pro·gram·mer (noun) An organism capable of converting caffeine into code.

Current project: GGD Mentor

Twitter

JustAlexander
Newbie
Posts: 21
Joined: Sun Mar 03, 2019 9:27 am
Contact:

Re: Help with Renpy Notifcations

#8 Post by JustAlexander »

That sounds like a great idea!
I try. Sorry if I do something wrong, I'm still new to all this.
Attachments
screens.rpy
I think this is it.
(40.19 KiB) Downloaded 27 times

strayerror
Regular
Posts: 159
Joined: Fri Jan 04, 2019 3:44 pm
Contact:

Re: Help with Renpy Notifcations

#9 Post by strayerror »

I can recreate by trying to recompile that screens.rpy in Ren'Py <= 7.1.0, while 7.1.1+ seems fine. So I suspect you've created/opened a project generated with a newer version of Ren'Py in an order version, which is why it doesn't understand the substitute keyword.

JustAlexander
Newbie
Posts: 21
Joined: Sun Mar 03, 2019 9:27 am
Contact:

Re: Help with Renpy Notifcations

#10 Post by JustAlexander »

so... what should I do?
I thought I was using the most recent version!
EDIT:
So, funny story. Actually it turns up that I have TWO versions of renpy installed on my computer, one is the newer one, which I downloaded like two weeks ago, and another one is much more older, that's been sitting in my computer for quite some time.
It turns up that I mixed them up, so when I though I was using the newer version I was actually using the older one.
I just had to update my ren'py (Also, it handy to know you can update your ren'py whenever they drop a new update, so you don't have to re-download it).
So this problem is officialy SOLVED!!!

Thank all of you guys for help!
Everything is working now!

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot]