Fix #9174: Don't update text effect if it has been reset. (#9183)

This commit is contained in:
PeterN 2021-05-03 15:12:47 +01:00 committed by Charles Pigott
parent b9ea4f07e4
commit 05aed133c7
1 changed files with 1 additions and 0 deletions

View File

@ -79,6 +79,7 @@ void UpdateTextEffect(TextEffectID te_id, StringID msg)
void UpdateAllTextEffectVirtCoords()
{
for (auto &te : _text_effects) {
if (te.string_id == INVALID_STRING_ID) continue;
SetDParam(0, te.params_1);
SetDParam(1, te.params_2);
te.UpdatePosition(te.center, te.top, te.string_id, te.string_id - 1);