Fix incorrect formatting

Gets rid of this warning:

  error: adding 'int' to a string does not append to the string [-Werror,-Wstring-plus-int]
This commit is contained in:
Martin Natano
2022-05-31 07:35:17 -07:00
parent 228920e7dc
commit 699ef6fdbe
2 changed files with 3 additions and 4 deletions
+2 -3
View File
@@ -183,9 +183,8 @@ void MenuTimer::SetText( float fSeconds )
LuaHelpers::Push( L, fSeconds );
// call function with 1 argument and 1 result
RString Error= "Error running Text" + (i+1);
Error+= "FormatFunction: ";
LuaHelpers::RunScriptOnStack(L, Error, 1, 1, true);
RString errorMessage = ssprintf("Error running Text%dFormatFunction: ", i+1);
LuaHelpers::RunScriptOnStack(L, errorMessage, 1, 1, true);
RString sText;
LuaHelpers::Pop( L, sText );