07th-mod / 07th-mod/umineko-question
Text speed is reset at start of each chapter in normal mode/base game (Question & Answer)
- Langage dominant
- C#
- Étoiles
- 98
- Forks
- 10
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
A user reported that the text speed is reset at start of each chapter. I think this affects both question and answer arcs of our mod, and also the base game too. Possibly, ADV mode may reset the text speed even more often.
I dug into it, and found the following:
- The `setwindow` command is called at the start of each chapter (it is called from `eye1`, the eyecatch function which separates chapters).
- The `setwindow` command contains a 'Default text speed' argument. In all our scripts this is set to a fixed value of `20` which is the 'default' text speed. So whenever `setwindow` is encountered in the script, the text speed resets to `20`.
- The `setwindow3` command works similarly
- The text speed when you press 1,2, and 3 come from `defaultspeed 40,20,0` (which corresponds to the 1,2 and 3 keys)
We should be able to replacing the fixed value of `20` in setwindow with a saved variable, to ensure the speed is kept. However, there is the issue of actually setting the variable/conflict with the existing shortcuts.
I haven't looked into how the '1/2/3' speed select shortcuts work - whether they're implemented at the engine level or at the script level. If it was at the script level, it would be easy to make this work with our new variable (or even add a mod-menu way to adjust the speed with more granularity). But if it's at the engine level, then there may be some conflict in the text speeds (especially since there doesn't appear to be a way to read the current text speed), and we would have to tell users not to use the `1/2/3` keys to set the text speed.
edit: I'm pretty sure it's in-engine, both from looking at the script and this quote from the reference: "Although (P)ONScripter does not provide a menubar, you can select among the textspeeds using keystrokes: '1' for slow, '2' for medium, '3' for fast, and '0' to toggle between all three."
----
Note that the `!sd` function does not change the default text speed, rather it sets the 'current speed' to the 'default speed'. Likewise the `!s` function does not overwrite the 'default speed', it just changes the 'current speed'. So both `!sd` and `!s` don't seem to affect this issue, unless there is a `!s` without a matching `!sd` to reset the speed (there are lots of redundant !sd in the script, so this is probably not an issue).
Note: Please note that in ADV mode, some of the `setwindow` commands have been replaced with `adv_default_text_speed_restore_window` which then calls `setwindow` - it was necessary to implement the ADV mode textbox)
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Piste de recherche
Examinez la commande `setwindow` dans les fichiers de script, en particulier là où elle est appelée depuis `eye1` (la fonction eyecatch). L'argument de vitesse de texte est codé en dur à 20. Étudiez comment les raccourcis de vitesse de texte du moteur (1,2,3) interagissent avec les variables du script. Vérifiez s'il existe une variable sauvegardée pour la vitesse de texte qui peut remplacer la valeur fixe. Les tests impliquent d'exécuter le jeu et de vérifier que la vitesse du texte persiste entre les chapitres.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- csharp
- Domaine
- game-dev
- Type d'issue
- Bug
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 45/100