hi there^^
I'd like to know if there is a way to prevent the user from clicking.
I used "pause", "show screen" and "show text" etc to "animate" my credits ike a cutscene, but if the player wuld click a button he would skip the whole thing.
Is there a way to prevent it? Like telling renpy: do not accept a mouse/button-click until a certain point?
I hope you can help me out^^
prevent skipping for credits?
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.
- Mirrowdothack
- Regular
- Posts: 146
- Joined: Tue Nov 05, 2013 7:37 am
- Completed: The Iron Heart Witch
- Projects: Y;N, Crime•Scene
- Location: Germany
- Contact:
Re: prevent skipping for credits?
More context please, disabling buttons is not the simplest thing to do in Ren'Py...
If you're using screen language for the credits (which would be a very smart thing to do), you could simply do something like:
screen credits:
modal True
zorder 100
timer (duration of credits) action Hide("credits")
And you're set. Or locking the screen and ui interact in a while loop might also work but would be more awkward. I am not 100% sure on how to disable narrator or say behavior on clicks of the top of my head if you're not using screens other than remapping keys.
If you're using screen language for the credits (which would be a very smart thing to do), you could simply do something like:
screen credits:
modal True
zorder 100
timer (duration of credits) action Hide("credits")
And you're set. Or locking the screen and ui interact in a while loop might also work but would be more awkward. I am not 100% sure on how to disable narrator or say behavior on clicks of the top of my head if you're not using screens other than remapping keys.
- Mirrowdothack
- Regular
- Posts: 146
- Joined: Tue Nov 05, 2013 7:37 am
- Completed: The Iron Heart Witch
- Projects: Y;N, Crime•Scene
- Location: Germany
- Contact:
Re: prevent skipping for credits?
First thank you for you fast reply^^
I'm not really sure what you mean so I'm gonna show you how I did it so far:
label credits:
scene credti_bg
show credits01 with dissolve
pause 2.8
hide credits01
show credits02 with dissolve
pause 2.8
...
Do you think there is a way doing it like this?
I'm not really sure what you mean so I'm gonna show you how I did it so far:
label credits:
scene credti_bg
show credits01 with dissolve
pause 2.8
hide credits01
show credits02 with dissolve
pause 2.8
...
Do you think there is a way doing it like this?
-
- Miko-Class Veteran
- Posts: 636
- Joined: Thu May 14, 2009 8:15 pm
- Projects: Castle of Arhannia
- Contact:
Re: prevent skipping for credits?
a quick suggestion:
if your game has any replay value or has multiple endings it's a good idea to only make the credits unskippable the first time the player goes through them. having to sit through them every time can be incredibly annoying
one way to do this is to use $ renpy.pause(pause_time, hard=persistent.seen_credits) for each pause and then set persistent.seen_credits to True at the end of the credits. this would most likely make it so the player has to click through each pause though (or just hit control or tab).
if your game has any replay value or has multiple endings it's a good idea to only make the credits unskippable the first time the player goes through them. having to sit through them every time can be incredibly annoying
one way to do this is to use $ renpy.pause(pause_time, hard=persistent.seen_credits) for each pause and then set persistent.seen_credits to True at the end of the credits. this would most likely make it so the player has to click through each pause though (or just hit control or tab).
- Mirrowdothack
- Regular
- Posts: 146
- Joined: Tue Nov 05, 2013 7:37 am
- Completed: The Iron Heart Witch
- Projects: Y;N, Crime•Scene
- Location: Germany
- Contact:
Re: prevent skipping for credits?
Thank you so much for your reply^^
I tried to use it like this:
which works pretty well
I've included an overlay-button to skip (thank you for taht advise^^) like this:
and:
it works, but sometimes the skipbutton seem to have a delay. I cant push it while an image uses dissolve to show up.
Do you think there might be a chance to change this?
I tried to use it like this:
Code: Select all
show credits1 with dissolve
$ renpy.pause(2.8, hard=True)
I've included an overlay-button to skip (thank you for taht advise^^) like this:
Code: Select all
$ show_skipCredits = True
show credits1 with dissolve
$ renpy.pause(2.8, hard=True)
Code: Select all
def skipCredits_overlay():
if show_skipCredits:
ui.textbutton("Skip Credits", style=style.button['inventoryButton'], clicked=ui.jumps("skipCredits"))
config.overlay_functions.append(skipCredits_overlay)
Do you think there might be a chance to change this?
Who is online
Users browsing this forum: Ocelot