mirror of
https://github.com/blupi-games/planetblupi
synced 2024-12-30 10:15:36 +01:00
Prevent bad values with the language to restore
This commit is contained in:
parent
05a8c4469a
commit
a17a7e1dda
@ -4585,7 +4585,11 @@ CEvent::ReadInfo ()
|
||||
m_pSound->SetMidiVolume (info.midiVolume);
|
||||
|
||||
if ((info.majRev == 1 && info.minRev >= 1) || info.majRev >= 2)
|
||||
{
|
||||
if (info.language >= static_cast<int> (Language::end))
|
||||
info.language = 0;
|
||||
this->SetLanguage (static_cast<Language> (info.language));
|
||||
}
|
||||
|
||||
fclose (file);
|
||||
return true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user