Changes fast text option to skip text, and makes text speed adjustable via a slider (#173)
* Adds fast text option Changes previous "fast text" option to "skip text", and adds a new "fast text" option, which makes text appear 5 times faster. * Fixes magic numbers * Changes text speed to a slider (unfinished) Got most of the code working, but only works upon reloading the game, unsure of how to fix this. * Makes text speed adjustable via a slider * Cleans up changes to z_message_PAL.c
This commit is contained in:
@@ -49,8 +49,11 @@ namespace Game {
|
||||
Settings.debug.n64mode = stob(Conf[ConfSection]["n64_mode"]);
|
||||
|
||||
// Enhancements
|
||||
Settings.enhancements.fast_text = stob(Conf[EnhancementSection]["fast_text"]);
|
||||
CVar_SetS32("gFastText", Settings.enhancements.fast_text);
|
||||
Settings.enhancements.skip_text = stob(Conf[EnhancementSection]["skip_text"]);
|
||||
CVar_SetS32("gSkipText", Settings.enhancements.skip_text);
|
||||
|
||||
Settings.enhancements.text_speed = Ship::stoi(Conf[EnhancementSection]["text_speed"]);
|
||||
CVar_SetS32("gTextSpeed", Settings.enhancements.text_speed);
|
||||
|
||||
Settings.enhancements.disable_lod = stob(Conf[EnhancementSection]["disable_lod"]);
|
||||
CVar_SetS32("gDisableLOD", Settings.enhancements.disable_lod);
|
||||
@@ -154,7 +157,8 @@ namespace Game {
|
||||
Conf[AudioSection]["fanfare"] = std::to_string(Settings.audio.fanfare);
|
||||
|
||||
// Enhancements
|
||||
Conf[EnhancementSection]["fast_text"] = std::to_string(Settings.enhancements.fast_text);
|
||||
Conf[EnhancementSection]["skip_text"] = std::to_string(Settings.enhancements.skip_text);
|
||||
Conf[EnhancementSection]["text_speed"] = std::to_string(Settings.enhancements.text_speed);
|
||||
Conf[EnhancementSection]["disable_lod"] = std::to_string(Settings.enhancements.disable_lod);
|
||||
Conf[EnhancementSection]["animated_pause_menu"] = std::to_string(Settings.enhancements.animated_pause_menu);
|
||||
Conf[EnhancementSection]["dynamic_wallet_icon"] = std::to_string(Settings.enhancements.dynamic_wallet_icon);
|
||||
|
||||
@@ -20,7 +20,8 @@ struct SoHConfigType {
|
||||
|
||||
// Enhancements
|
||||
struct {
|
||||
bool fast_text = false;
|
||||
int text_speed = 1;
|
||||
bool skip_text = false;
|
||||
bool disable_lod = false;
|
||||
bool animated_pause_menu = false;
|
||||
bool dynamic_wallet_icon = false;
|
||||
|
||||
@@ -395,8 +395,14 @@ namespace SohImGui {
|
||||
ImGui::Text("Gameplay");
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Checkbox("Fast Text", &Game::Settings.enhancements.fast_text)) {
|
||||
CVar_SetS32("gFastText", Game::Settings.enhancements.fast_text);
|
||||
ImGui::Text("Text Speed", Game::Settings.enhancements.text_speed);
|
||||
if (ImGui::SliderInt("##TEXTSPEED", &Game::Settings.enhancements.text_speed, 1, 5)) {
|
||||
CVar_SetS32("gTextSpeed", Game::Settings.enhancements.text_speed);
|
||||
needs_save = true;
|
||||
}
|
||||
|
||||
if (ImGui::Checkbox("Skip Text", &Game::Settings.enhancements.skip_text)) {
|
||||
CVar_SetS32("gSkipText", Game::Settings.enhancements.skip_text);
|
||||
needs_save = true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user