Closed TheRealFame closed 4 months ago
Hello, I would need more explanation of what the issue is.
Hello, I would need more explanation of what the issue is.
Input.set_mouse_mode(Input.MOUSE_MODE_VISIBLE), In CSharp. Is never called to or set back to focused after the player selects a choice. Which isn't a good design unless you want choices to only be selected by key inputs.
This plugin does not change the mouse mode in general. If you try the samples in this repo, you'll see it is possible to select options with either the mouse or controller/keyboard inputs. The mouse can also be used after selecting an option with the keyboard or controller. So, I don't understand what is preventing you from using the mouse.
If you have other code in your game that is controlling the mouse mode before your dialogue starts, you could either make a custom dialogue view in C# that sets the mouse mode to your desired state, or add a GDScript or C# script that sets the mouse mode under the conditions you want. I don't think it would necessarily be desirable for all games that this plugin would change the mouse mode automatically after an option is selected.
This plugin does not change the mouse mode in general. If you try the samples in this repo, you'll see it is possible to select options with either the mouse or controller/keyboard inputs. The mouse can also be used after selecting an option with the keyboard or controller. So, I don't understand what is preventing you from using the mouse.
That is true. YarnSpinner cannot make the mouse captured or visible, That is why i am suggesting the change. Unless specified to yarn-spinner this new code to help deal with how the cursor should be handled, If not, The issue that is currently present. Yarn spinner being unable to have any choices selected. Remains in effect for all 3d game's using the cursor. If i go on it would be repeating, But it's still the same core concept of,
"This plugin has. To assume the mouse is not captured, Or it does not allow the user to continue in a choice based scene, Because the player has the option to control their keyboard, Entirelyyyy off and disabled."
I would also go as far as to say this is an accessibility thing, If choosing an option was available with keyboard inputs, YarnSpinner. Since it doesn't have anything in it's code, Itself. Cannot make sure the cursor can. Select a choice! Or atleast listen if the developer asks to have the cursor visible/enabled through an @export variable.
(This should respond to the question as detailed as possible, And just for the fun of it, I will summarize it as small as i can.)
If you have other code in your game that is controlling the mouse mode before your dialogue starts, you could either make a custom dialogue view in C# that sets the mouse mode to your desired state, or add a GDScript or C# script that sets the mouse mode under the conditions you want. I don't think it would necessarily be desirable for all games that this plugin would change the mouse mode automatically after an option is selected.
Even as so. That doesn't take away the plugin Should. Be providing the option. (Option, This kind of change does not have to be persistent. As long as it's a choice by the dev to do this assuming.)
It sounds like you're taking some action in your game that is changing the mouse mode before the dialogue starts. I don't think that this plugin should be responsible for undoing that. It doesn't seem like a good candidate for adding an option to the line view to me personally (to keep the complexity of the options down), since you have the alternatives listed in my previous message
It sounds like you're taking some action in your game that is changing the mouse mode before the dialogue starts. I don't think that this plugin should be responsible for undoing that. It doesn't seem like a good candidate for adding an option to the line view to me personally (to keep the complexity of the options down), since you have the alternatives listed in my previous message
These redditors mention how to do it with godot mono, While it may not be the most professional example of how to show implementation of the needed feature, It may be helpful during the downtime of me trying to submit the pull request to add it.
https://www.reddit.com/r/godot/comments/16igmcs/godot_41_c_setting_the_mouse_mode_code/
I don't feel it's appropriate for this plugin to set the mouse mode for all users. It's something that you can do in your own custom view or another script in your game.
I don't feel it's appropriate for this plugin to set the mouse mode for all users. It's something that you can do in your own custom view or another script in your game.
I very much feel like the plugin should have an option to undo mouse mode settings automatically. For games that require capturing the mouse, Etc, All games I've played. So I'll definitely be trying to make this an @export and pull request it.
You're certainly free to modify your own copy of the scripts, or (what would be a simpler solution), add another script that sets the mouse mode at the right moment, but based on my understanding of this issue, you are changing the configuration of your game, and then expecting this plugin to undo that change. Sorry, but I don't support adding this and will not accept a PR that makes this change.
At the moment, YarnSpinner doesn't do as said in the title. In Godot, (Most 3d games.) We need/Have to capture the cursor. Meaning that when we show a dialoguebox with choices, We can't allow the player to use their mouse again to select anything. Atleast unless that's coded in.
But the problem there is.
This will be seen as a universal issue for many, And since YarnSpinner uses the opposite programming language of godot (CSharp) Most people have no clue how to setup the functionally of making the cursor visible again.