Advertisement

Translate Error/Exception Message

Started by March 04, 2014 03:35 PM
3 comments, last by Kurage 10 years, 8 months ago

I'm making a game for non-English speakers(including me).
AngelScript is a very nice script engine, but its compilation error and exception messages we receive from the callback is only in English.
And if the release version crashed by bugs they'll also get them in English(from the AngelScript Library), that is not easy to understand for the players.

The way to replace(or translate) them is only to rewrite the source codes?
Or are there some alternatives?

Might I suggest to rethink if displaying some specific error messages from the script engine is really that good of an idea? If you are really just making a game, and not a game engine, in case something fails, the average user won't really care about and probably even be mystified even more by some cryptic error message. "Error: Script compilation failed, game data is probably corrupt" would be a way better feedback IMHO, be it english or not, because in case the user cannot do anything against it, it doesn't matter if he knows the exact technicals or not. You can save the english crashlog anyway for them to send to you, e.g.

Just some food for thought while you are waiting for the techniqual answer to your question, unless of course you plan on making a game engine/game editor or want to allow modding via scripts, in which case my argument is invalid anyways.

Advertisement

You're quite right.
I will show the average players a simple message such as "Error:start up failed." and allow them to send a crash report.

But, as you said, I will allow them adding an extra stage via AngelScript.

All the text messages that the AngelScript core engine can generate are found in the as_texts.h file. You'll not have to rewrite the code in any way, only translate the text messages in this file.

The add-ons unfortunately doesn't have such a centralized location for all the texts, so if you use those you'll need to go through the code and translate whatever messages there are when exceptions are raised or they write to the message stream.

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

Okay, I will look and translate the texts in as_texts.h file, and I will add some codes to select the texts' language by defining a preprocessor word.
Then I will try to translate the texts used in add-ons.

Thanks a lot!

This topic is closed to new replies.

Advertisement