Fixed switch label with "default" case

This commit is contained in:
smallmodel 2023-08-19 00:57:29 +02:00
parent f16b992a97
commit b9f3ee867b
No known key found for this signature in database
GPG key ID: A96F163ED4891440

View file

@ -1901,7 +1901,7 @@ bool ScriptVM::Switch(StateScript *stateScript, ScriptVariable& var)
pos = stateScript->FindLabel(var.stringValue());
if (!pos) {
pos = stateScript->FindLabel("");
pos = stateScript->FindLabel(STRING_DEFAULT);
if (!pos) {
return false;