Hello,
I've implemented a small notice message system and I'd like to block the game progression in she script while all notice message aren't read.
When all message are read, the unread variable is set to False (this part works).
The problem is that I'm in nvl_mode and I don't want to add dialog until unread is False, because that would fill screen with these dialogs.
$ renpy.pause() is hiding all the screen so it's not possible to read notices.
I was not able to call a screen to block progress (while leaving right part of screen available to read notices)
[Solved] Disable game progression until variable is set
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.
[Solved] Disable game progression until variable is set
Last edited by Keul on Wed Apr 02, 2014 4:39 pm, edited 1 time in total.
-
- Eileen-Class Veteran
- Posts: 1258
- Joined: Fri Sep 21, 2007 7:13 am
- Projects: a battle engine
- Contact:
Re: Disable game progression until variable is set
Does renpy.interact() work as an alternative to pause? I haven't used it myself.
In terms of calling a screen to block progress, try fiddling with the screen's zorder. If you throw up a screen modal and lower in zorder to the screens necessary to read notices, it should block all input those screens don't use.
In terms of calling a screen to block progress, try fiddling with the screen's zorder. If you throw up a screen modal and lower in zorder to the screens necessary to read notices, it should block all input those screens don't use.
Re: Disable game progression until variable is set
renpy.interact() doesn't exist.
ui.interact() exist but it show an empty screen like renpy.pause()
And how can I add a screen when in a python function? seems that there's no renpy.show_screen("screenname")
ui.interact() exist but it show an empty screen like renpy.pause()
And how can I add a screen when in a python function? seems that there's no renpy.show_screen("screenname")
Re: Disable game progression until variable is set
AddKeul wrote:ui.interact() exist but it show an empty screen like renpy.pause()
Code: Select all
window show
Try something like
Code: Select all
define e = Character('Eileen', color="#c8ffc8", kind=nvl)
define narrator = Character(None, kind=nvl)
transform my_transf:
on show:
alpha 0.0
linear 0.5 alpha 1.0
on hide:
linear 0.5 alpha 0.0
screen notice_scr:
timer 1.5 action [Hide("notice_scr"), Return("smth")]
frame:
align (0.5, 0.5)
xmaximum 200 xminimum 200
ymaximum 30 yminimum 30
text "message seen"
at my_transf
on "show" action SetVariable("unread", False)
screen button_scr:
textbutton "Notice" action If(renpy.get_screen("notice_scr"), None, Show("notice_scr")) xalign 1.0 yalign 0.05
# The game starts here.
label start:
$ unread = False
window show
show screen button_scr
e "You've created a new Ren'Py game."
$ renpy.show_screen("notice_scr")
e "???"
$ unread = True
"*and now you won\'t be able to advance through the text until you check the notice*{nw}"
$ ui.interact()
e "Once you add a story, pictures, and music, you can release it to the world!"
return
Re: Disable game progression until variable is set
Thank you.
I haven't used the same code but with the "window show" and "Return("smthing")" it works
I haven't used the same code but with the "window show" and "Return("smthing")" it works
Who is online
Users browsing this forum: Ahrefs [Bot], Majestic-12 [Bot]