Warcraft III resources & community, 2003–2006 · archived

Errors/Info

3 posts
#1

Errors/Info

does anyone know if it is possible to refer (with vexorians sim-error function) to an error-strings that is allready 'ingame' , that versions of diffrent languages would always have a correct error ?
#2
From blizzard.j:

    // Display "player was victorious" or "player has left the game" message
    if (leftGame) then
        set formatString = GetLocalizedString( "PLAYER_LEFT_GAME" )
    else
        set formatString = GetLocalizedString( "PLAYER_VICTORIOUS" )
    endif

It looks like GetLocalizedString returns the value of a string defined in one of the .txt in the .mpq file.
You should be able to find the name of your error message in one of the .txt files and use that.
It would probably be something like this:

local string error = GetLocalizedString( "ERROR_GOLD" )
#3
i found the source (they are in the game-interface options in the worldeditor, as well in the units \commandstring.txt in the .mpq file) but the fuction returns the source as a string not the value.