How to stop click-anywhere advance...
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.
How to stop click-anywhere advance...
I am not having luck finding where the mouse-click stuff is located.
I do not want the text to advance when they click anywhere, only within the text window. (Honestly that is driving me crazy). Also, at some point, I want to hijack the mouse-wheel for interaction. (Which also requires mouse-click/scroll stuff.)
What would I alter, to achieve this function?
P.S. Yes, I know I seem needy at the moment. The more I learn, the more I can help-out others. The more of this structure I learn, the better the chances of making a true GUI for my story creation. Not that I don't like notepad or the other editor, but it is too primitive and lacks the information needed to identify problems and provide resolutions. It also lets you make all sorts of invalid stuff, located in all the wrong places. Sorry, I am just use to dev-environments too much I guess. (Sad, I still use Visual-Basic 6. xD)
I do not want the text to advance when they click anywhere, only within the text window. (Honestly that is driving me crazy). Also, at some point, I want to hijack the mouse-wheel for interaction. (Which also requires mouse-click/scroll stuff.)
What would I alter, to achieve this function?
P.S. Yes, I know I seem needy at the moment. The more I learn, the more I can help-out others. The more of this structure I learn, the better the chances of making a true GUI for my story creation. Not that I don't like notepad or the other editor, but it is too primitive and lacks the information needed to identify problems and provide resolutions. It also lets you make all sorts of invalid stuff, located in all the wrong places. Sorry, I am just use to dev-environments too much I guess. (Sad, I still use Visual-Basic 6. xD)
-
- Regular
- Posts: 71
- Joined: Sun Jun 08, 2014 1:45 pm
- Contact:
Re: How to stop click-anywhere advance...
I can't figure this out either! I'm having a very similar problem. All I want to do is disable the say window when a different screen is being shown so that the story doesn't keep moving while I have other things displayed. Seems like it should be a really simple solution but there isn't anything on this anywhere.
In addition to stopping click-anywhere advance, is there a way to stop all advancing?
In addition to stopping click-anywhere advance, is there a way to stop all advancing?
- PyTom
- Ren'Py Creator
- Posts: 16096
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: How to stop click-anywhere advance...
The fullscreen click is pretty deep inside Ren'Py, in the saybehavior code, which is called by the say code.
To override it, you pretty much would need to re-implement the Character class. Realize that the code:
is equivalent to:
So if you have your own class, you can override the default behavior. This would be a lot of work, however.
To override it, you pretty much would need to re-implement the Character class. Realize that the code:
Code: Select all
e "Hello, World"
Code: Select all
e("Hello, World")
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
Software > Drama • https://www.patreon.com/renpytom
Re: How to stop click-anywhere advance...
Then I would like to ask this as a "suggestion/feature"...
Isolated clicking-advancement options... (Limited to the text-area optionally, not the whole window, or none so it is forced to SPACE or ENTER advancement only, as a fallback.)
and...
Mouse-input commands... (Obviously defaulting to click-advance, and mouse-scroll-history, and menu.)
However, at specific scenes, or globally, having some other non-core functions available or to over-ride them.
Isolated clicking-advancement options... (Limited to the text-area optionally, not the whole window, or none so it is forced to SPACE or ENTER advancement only, as a fallback.)
and...
Mouse-input commands... (Obviously defaulting to click-advance, and mouse-scroll-history, and menu.)
However, at specific scenes, or globally, having some other non-core functions available or to over-ride them.
Re: How to stop click-anywhere advance...
Is there possibly a way to simulate this, doing something like this...
Force it to not advance at all... (clicking)... {Like when the menu items show, it stops advancing.} A cheap way to do this, in HTML is by placing a blank-gif over the whole page, which essentially captures the click-event.
Then create an overlay or a special "condition", when the text-area, or another displayed component is on the screen.
Eg, as if there were a menu-interruption between every line of text, but the menu is not actually displayed. However, clicking in the "special area"... (text) or (object on screen), triggers a hidden selection, which is actually like a menu-advance (or Jump).
Not sure if I explained that right... But, I can live with "click-anywhere", up until those special designated moments, where I do not want it to advance, until the selected item for advancement is directly clicked. This would apply to clicking on objects, for collection, in a scene... also for the possibility of simulated movement without selecting "right" "left" "forward"... etc... or the use of keystrokes as input.
Force it to not advance at all... (clicking)... {Like when the menu items show, it stops advancing.} A cheap way to do this, in HTML is by placing a blank-gif over the whole page, which essentially captures the click-event.
Then create an overlay or a special "condition", when the text-area, or another displayed component is on the screen.
Eg, as if there were a menu-interruption between every line of text, but the menu is not actually displayed. However, clicking in the "special area"... (text) or (object on screen), triggers a hidden selection, which is actually like a menu-advance (or Jump).
Not sure if I explained that right... But, I can live with "click-anywhere", up until those special designated moments, where I do not want it to advance, until the selected item for advancement is directly clicked. This would apply to clicking on objects, for collection, in a scene... also for the possibility of simulated movement without selecting "right" "left" "forward"... etc... or the use of keystrokes as input.
Re: How to stop click-anywhere advance...
Found the sub-linked portion... (That post leads to this post.)Alex wrote:Check this thread - http://lemmasoft.renai.us/forums/viewto ... =8&t=21870
http://lemmasoft.renai.us/forums/viewtopic.php?p=124280
Neat trick... I was thinking something like that would be needed.
The concept... (As I understand it.)
1: Stop advancement by forcing a never-ending loop "animation" object.
2: Continue advancement by selecting that object.
Excerpt from that forum-post...
I assume a more advanced version would also select "advancement" as a trigger if the say-window was clicked, or if the mouse-position was within a certain area, when clicked...Click to Continue icon
A fun feature is to show an icon to the player when they need to click in order to advance the story. To add this to your boxes, you need to add it to the characters you want to use it, like show_two_window.
Just link to the image's call name in quotes. If you want to animate it, build the animation first, and then link to the animations call name. Also, you can have the CTC indicator embedded into the text, placed right after the last word on the screen, or you can place it in a fixed location on the screen. Here is an example of an animated CTC icon that is placed in the corner of the screen (fixed):
You can use the new ATL language to make CTC animations, too. Just plug in the name in the quotes. Make sure to put position properties into the image if you want it to be fixed on the screen somewhere.Code: Select all
image ctc_animation = Animation("ctc01.png", 0.2, "ctc02.png", 0.2, xpos=0.99, ypos=0.99, xanchor=1.0, yanchor=1.0) $ a = Character('Name', ctc="ctc_animation", ctc_position="fixed")
Re: How to stop click-anywhere advance...
Please read Alex's post in that thread. The concept is to block dismiss keybind and add a button that advances the game... It's a good/valid.JD_Mortal wrote:The concept... (As I understand it.)Alex wrote:Check this thread - http://lemmasoft.renai.us/forums/viewto ... =8&t=21870
1: Stop advancement by forcing a never-ending loop "animation" object.
2: Continue advancement by selecting that object.
What is preventing you from putting modal on say screen and placing an invisible button over the the say screen that restarts an interaction? It's two lines of mind-numbingly simple code that should get the job done perfectly. I guess blocking dismiss is a lot wiser if you have some other elements on the screen (I never tried doing that).JD_Mortal wrote:I do not want the text to advance when they click anywhere, only within the text window.
Bound to:JD_Mortal wrote:Also, at some point, I want to hijack the mouse-wheel for interaction. (Which also requires mouse-click/scroll stuff.)
Code: Select all
"mousedown_4"
"mousedown_5"
Re: How to stop click-anywhere advance...
What is stopping me, is...xela wrote:JD_Mortal wrote:What is preventing you from putting modal on say screen and placing an invisible button over the the say screen that restarts an interaction? It's two lines of mind-numbingly simple code that should get the job done perfectly. I guess blocking dismiss is a lot wiser if you have some other elements on the screen (I never tried doing that).
What the hell is a modal?
(Took me a while to grasp that Tuples are just Arrays, semantics...)
RANT:
Arrays can be Tuples, however usually only scientists generally use the term Tuples. Kind-of defeats the purpose of simplification, if it requires programming and extensive "new" explanation, to re-describe something that is already commonly known as something-else.
Modal's are spun Rayon fibers... Am I knitting now? (Just kidding, "Window"... Just say a window... xD)My problem is not "how to continue advancement"... my problem is "how do I stop advancement, so I can later continue it". (That is what was killing me... any click, of any kind, advances the scene, or jumps into a menu, does a roll-back. They are neat features to have, but I don't want them and there is no way to turn them off, that I can find. Well, you can set roll-back to 0, but then you can't have roll-back function at all.)
Not sure how to use that "bound to:" stuff you mentioned... Is this programming in python, or part of the game script?
Re: How to stop click-anywhere advance...
Ok, This is what I got... from this page...
[Customizing the Keymap]
also: [External Resource, pygame.key]
This code added to the "options.rpy" file, after all the bottom.
* Take note that [dismiss] is [advance/continue], and activates on MouseUp. (Poor wording, that should be a separate thing.)
* Also note that [game_menu] and [hide_windows] is also a MouseUp event.
That covers the major issues I had. xD
Now I just have to figure-out how to invoke a ["dismiss"] event when they click the text... Though, I am trying to save the mouse from click-hell. (I have already gone through three mice due to this. It breaks the contacts in the switch and wears them out prematurely, causing double-clicks ever time you click it once... or triple-clicks!)
In the end, I decided that I like the "Hide windows" option. Didn't even know that was a function of RenPy!
[Customizing the Keymap]
also: [External Resource, pygame.key]
This code added to the "options.rpy" file, after all the bottom.
Code: Select all
config.keymap["dismiss"].remove("mouseup_1")
#config.keymap["hide_windows"].remove("mouseup_2")
config.keymap["game_menu"].remove("mouseup_3")
config.keymap["rollback"].remove("mousedown_4")
config.keymap["rollforward"].remove("mousedown_5")
* Also note that [game_menu] and [hide_windows] is also a MouseUp event.
That covers the major issues I had. xD
Now I just have to figure-out how to invoke a ["dismiss"] event when they click the text... Though, I am trying to save the mouse from click-hell. (I have already gone through three mice due to this. It breaks the contacts in the switch and wears them out prematurely, causing double-clicks ever time you click it once... or triple-clicks!)
In the end, I decided that I like the "Hide windows" option. Didn't even know that was a function of RenPy!
Re: How to stop click-anywhere advance...
One thing at a time:
Dismiss (what continues the advancement is bound to a number of actions on input devices so you can interact with the game). None will ensure that nothing can advance the game by default.
to it, that will prevent user interaction with other screens (will prevent advancement for mouse clicks at the very least (not sure about other input devices)).
so adding am invisible button to the say screen that restarts an interaction should do the trick:
This code is not tested...
PS: You posted while I was typing this...
http://www.renpy.org/doc/html/screens.h ... age-syntaxJD_Mortal wrote:What the hell is a modal?
JD_Mortal wrote:My problem is not "how to continue advancement"... my problem is "how do I stop advancement, so I can later continue it".
Add to options.rpy file (or any file with init python in it). This is a direct quote from Alex's post from the link he gave you...JD_Mortal wrote:Not sure how to use that "bound to:" stuff you mentioned... Is this programming in python, or part of the game script?
Code: Select all
config.keymap["dismiss"] = None
Back to modal, I suggested this as an alternative since blocking dismiss is very likely to block advancing images/animations/transitions and etc as well. If you can find say screen in screens.rpy and add:JD_Mortal wrote:What the hell is a modal?
Code: Select all
modal True
You wanted to continue when clicking somewhere on the say screen...JD_Mortal wrote:so I can later continue it"
so adding am invisible button to the say screen that restarts an interaction should do the trick:
Code: Select all
button:
background Null()
xysize(#whatever the window size is)
align(#to window position)
action renpy.curry(renpy.restart_interaction)
PS: You posted while I was typing this...
Re: How to stop click-anywhere advance...
(The modal thing was sarcasm... about it being Rayon. But the rest wasn't known to me.)
Yea, the part about blocking "dismiss"... (Again, that shouldn't be a "catch-all" action... each thing should have its own action. Nothing I can do about that, it is a programming choice.)
However, I do not care if it blocks "dismissing" with the mouse, of other things. "I want control of the input". If something should be "dismissable", then I will optionally set it to be dismissable... Here, everything it dismissable, which brings me to the issue originally stated. (About stopping that invasive "mouse-kills everything happening". It is only the mouse-actions which I have opted to remove, SPACE and RETURN and whatever, all still function for advancement or other functions. Keyboards were made for millions of clicks per button/key, mice are only made for about 10,000 clicks per switch/button. However, my desire to remove that undesirable operation has less to do with mouse click-death and more to do with "having control".)
Looking at trying the window thing now... (That was a little more advanced for me, at this early stage in "learning". I am on a crash-course, which is chaotic due to having to run all over to find things that should all be localized. Some being outdated and just not functioning, or without mention of where they should be used. Once you know, it is great... but before you know, you are stuck guessing where these specific things have to go, and that does not bode well with this setup.)
Takes only a village to raise a child...
Takes a whole damn nation to raise an adult!
Side note to the programmers writing the documentation...
- Saying "Characters" might seem natural for a writing program, when referring to "Story Characters" AKA: "People" or "Subjects"... However, I keep finding reference to "Characters", used to describe "Text Characters", AKA: "ASCII" or "Letters" or "Letters and Symbols". This causes some confusion when talking and attempting to describe things that alter the "Characters" or the "Characters"... (Some functions are for Alpha-numeric/symbols and some are intended for altering the people/subjects.) Makes it hard to tell which one it is talking about, as there is not much in the context, or a sample for many of the descriptions.
Re: How to stop click-anywhere advance...
Well, you have all the tools now, input can be controlled 100% (almost, I recon some exceptions can be found if one looks hard enough ), just takes a bit of work for little rewardJD_Mortal wrote:However, I do not care if it blocks "dismissing" with the mouse, of other things. "I want control of the input". If something should be "dismissable", then I will optionally set it to be dismissable...
Re: How to stop click-anywhere advance...
Corrected... Yea, I noticed that.xela wrote:Well, you have all the tools now, input can be controlled 100% (almost, I recon some exceptions can be found if one looks hard enough ), just takes abit(lot) of work for little reward
Think I may just go back to HTML5, CSS and Javascript at this point. Learning a whole other language (Python), in addition to learning the language variation of that language (The RenPy code)... and its quirks, is just becoming too much of a hassle. In the end, this is costing me money, not making me money.
Spending too much time on things that should be simple and clear, only to have them sort-of work, is not digesting well. Seems that this engine is just not advancing fast enough with the change of time. Like it is stuck in the past, and being patched with new things on top of old things, without the same logical integration as what the original idea/desire was, for the engine.
I'll have to revisit in a few years, see if things changed for the better. (Not that they are bad, just not... well... tuned. Reminds me of IMVU five years ago. I think RenPy just needs some fresh eyes, instead they seem to be blindfolding people.)
Re: How to stop click-anywhere advance...
Matter of opinion I suppose, people coming from different background often have trouble getting in sync with Ren'Py because it often tries to "enforce" (for lack of a better word) some functionality on the users. It gets better once you get used to it but HTML5 + JS is also a very powerful combination, good luck.
PS: I disagree on Ren'Py "being stuck" btw. It seems to be advancing quite nicely.
Who is online
Users browsing this forum: Google [Bot], IrisColt