P2: A ship-specific HUD with "$Load Retail Configuration: YES" loses most of its retail gauges
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 76/100
Línea de trabajo
Lee load_missing_retail_gauges y compara el bucle del HUD predeterminado con el bucle de clases de nave. El issue identifica como causa el ciclo de vida y el comportamiento de restablecimiento de la flag; verifica cómo comprueba cada bucle la lista de gauges de la nave. Se considerará terminado cuando un HUD de nave con un gauge personalizado reciba todos los gauges estándar que no define, también para las clases de nave posteriores.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Problem
A mod can give one ship class its own HUD and have the game fill in the rest of the standard gauges with $Load Retail Configuration: YES. When that HUD defines even one gauge itself, most of the standard gauges never get added: in my test the player kept only the radar and the message box, and lost the reticle, target box, weapons, energy, escort list and the rest.
In the ship-class half of load_missing_retail_gauges, retail_gauge_loaded is set to true as soon as one built-in gauge is found in the ship's own list, and is never set back to false for the next built-in gauge (the default-HUD loop above it does reset it). So every built-in gauge after the first match is treated as already loaded and skipped. By reading the code (not run): the flag also isn't reset between ship classes, so later ship classes with their own HUD should lose their fill-in entirely once any earlier one matched.
Steps to reproduce
- Current master (I used 8afa31842, Debug build), MediaVPs 5.0.2.
- Make a mod with a
data/tables/zz-hdg.tbmcontaining:#Gauge Config $Ships: ("GTF Myrmidon") $Load Retail Configuration: YES $Base: (1024, 768) $Gauges: +Messages: $End Gauges #End - Start SM1-01 (the player flies a GTF Myrmidon) and compare the HUD with a run without the mod.
What I got: without the mod, the full retail HUD. With it, only the radar and the message box.
Expected vs. actual behavior
Expected: the ship's own gauges plus every standard gauge it didn't define.
Actual: the standard gauges after the first one the ship defines are missing, for that ship and for every later ship class with its own HUD.
Proposed fixes
- Set
retail_gauge_loaded = false;at the top of the per-gauge loop in the ship-class half, as the default-HUD loop already does. - Declare the flag inside that loop instead of once for the whole function, so it can't carry over between gauges or ship classes.
- Replace the inner search with
std::any_ofover the ship's gauge list, which removes the flag altogether.
- Lenguaje dominante
- C++
- Estrellas
- 488
- Forks
- 184
- Merge medio
- 1 d 19 h
- PR fusionados (30 d)
- 33
Preparar el entorno
Aún no hemos revisado los archivos de configuración de este proyecto. Empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de scp-fs2open/fs2open.github.com
-
bug HUD LLM-suggested
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
scp-fs2open/fs2open.github.com#7953 ·
Los mantenedores suelen responder en 1 día
-
bug controls LLM-suggested
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
scp-fs2open/fs2open.github.com#7946 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 Medio día Aptitud para principiantes 66/100
scp-fs2open/fs2open.github.com#7932 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
scp-fs2open/fs2open.github.com#7924 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 83/100
scp-fs2open/fs2open.github.com#7918 ·
Los mantenedores suelen responder en 1 día
Todos los issues de scp-fs2open/fs2open.github.com
Issues similares
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
Los mantenedores suelen responder en 1 día
-
enhancement Ready for final check
Dificultad 2/5 1-3 horas Aptitud para principiantes 79/100
mpogue2/SquareDesk#1818 · 1 comentario ·
-
launch-client --save-creds creates creds/<account>/ with mode 755, not 700Posiblemente ocupada @metis-sprock la tomó hoy. Abiertobacklog bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
EchoTools/nevr-runtime#1471 ·
Los mantenedores suelen responder en 1 día
-
docs: Page not found?Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 66/100
Los mantenedores suelen responder en 2 días
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
iamankushpandit/Gume#231 ·
Los mantenedores suelen responder en 1 día